]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
acpi: rename aslc_id, aslc_revision
authorHeinrich Schuchardt <heinrich.schuchardt@canonical.com>
Sun, 21 Jan 2024 11:52:48 +0000 (12:52 +0100)
committerHeinrich Schuchardt <heinrich.schuchardt@canonical.com>
Wed, 27 Mar 2024 08:15:39 +0000 (09:15 +0100)
The fields Creator ID and Creator Revision contain information about the
tool that created an ACPI table. This may be the ASL compiler for some
tables but it is not for others. Naming these fields aslc_id and
aslc_revision is misleading.

It is usual to see diverse values of Creator ID. On a laptop I saw these:
'AMD ', 'INTL, 'MSFT', 'PTEC'. Obviously not all relate to the Intel
ASL compiler.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
arch/x86/lib/acpi_nhlt.c
arch/x86/lib/acpi_table.c
cmd/acpi.c
include/acpi/acpi_table.h
lib/acpi/acpi_table.c
lib/acpi/ssdt.c
test/dm/acpi.c

index 6c8cd83e12d3509dbfc68a84b4a1cd74101fd7cb..08e13fdea67f41fffe59ab2d769adfa7e26188fd 100644 (file)
@@ -409,7 +409,7 @@ int nhlt_serialise_oem_overrides(struct acpi_ctx *ctx, struct nhlt *nhlt,
                memcpy(header->oem_table_id, oem_table_id, oem_table_id_len);
        }
        header->oem_revision = oem_revision;
-       memcpy(header->aslc_id, ASLC_ID, 4);
+       memcpy(header->creator_id, ASLC_ID, 4);
 
        cur.buf = (void *)(header + 1);
        cur.start = (void *)header;
index 5ecd3d4b651a5d7de8f3376bbc5439b5b5969ca4..a5683132b014564ea502e959fbc6a4ba71ecdc55 100644 (file)
@@ -253,7 +253,7 @@ static int acpi_write_tpm2(struct acpi_ctx *ctx,
 
        /* Fill out header fields. */
        acpi_fill_header(header, "TPM2");
-       memcpy(header->aslc_id, ASLC_ID, 4);
+       memcpy(header->creator_id, ASLC_ID, 4);
 
        header->length = sizeof(struct acpi_tpm2);
        header->revision = acpi_get_table_revision(ACPITAB_TPM2);
@@ -479,7 +479,7 @@ static int acpi_create_hpet(struct acpi_hpet *hpet)
        /* Fill out header fields. */
        acpi_fill_header(header, "HPET");
 
-       header->aslc_revision = ASL_REVISION;
+       header->creator_revision = ASL_REVISION;
        header->length = sizeof(struct acpi_hpet);
        header->revision = acpi_get_table_revision(ACPITAB_HPET);
 
@@ -569,8 +569,8 @@ void acpi_fadt_common(struct acpi_fadt *fadt, struct acpi_facs *facs,
        header->revision = 4;
        memcpy(header->oem_id, OEM_ID, 6);
        memcpy(header->oem_table_id, OEM_TABLE_ID, 8);
-       memcpy(header->aslc_id, ASLC_ID, 4);
-       header->aslc_revision = 1;
+       memcpy(header->creator_id, ASLC_ID, 4);
+       header->creator_revision = 1;
 
        fadt->x_firmware_ctrl = map_to_sysmem(facs);
        fadt->x_dsdt = map_to_sysmem(dsdt);
index 65caaa5c98e49068499786ac805d302e3b95e2c0..928e5dc525e6400788e70c409e123bd8386dd572 100644 (file)
@@ -32,7 +32,7 @@ static void dump_hdr(struct acpi_table_header *hdr)
        if (has_hdr) {
                printf("  v%02d %.6s %.8s %x %.4s %x\n", hdr->revision,
                       hdr->oem_id, hdr->oem_table_id, hdr->oem_revision,
-                      hdr->aslc_id, hdr->aslc_revision);
+                      hdr->creator_id, hdr->creator_revision);
        } else {
                printf("\n");
        }
index e67562ef654c79f7e6deb75b86a177739cbed5bf..8256af6d29e5f620918bfa5ffc4c5b2e1d76ac50 100644 (file)
@@ -57,8 +57,8 @@ struct __packed acpi_table_header {
        char oem_id[6];         /* OEM identification */
        char oem_table_id[8];   /* OEM table identification */
        u32 oem_revision;       /* OEM revision number */
-       char aslc_id[4];        /* ASL compiler vendor ID */
-       u32 aslc_revision;      /* ASL compiler revision number */
+       char creator_id[4];     /* ASL compiler vendor ID */
+       u32 creator_revision;   /* ASL compiler revision number */
 };
 
 struct acpi_gen_regaddr {
@@ -831,7 +831,7 @@ void acpi_create_dbg2(struct acpi_dbg2_header *dbg2,
 /**
  * acpi_fill_header() - Set up a new table header
  *
- * This sets all fields except length, revision, checksum and aslc_revision
+ * This sets all fields except length, revision, checksum and creator_revision
  *
  * @header: ACPI header to update
  * @signature: Table signature to use (4 characters)
index 39dd53ec402b9fd892644c9e8c1150d735d1d0c3..c16ead6a6ec0800b51d4e03f7449bce9faf7fd74 100644 (file)
@@ -116,7 +116,7 @@ void acpi_fill_header(struct acpi_table_header *header, char *signature)
        memcpy(header->oem_id, OEM_ID, 6);
        memcpy(header->oem_table_id, OEM_TABLE_ID, 8);
        header->oem_revision = OEM_REVISION;
-       memcpy(header->aslc_id, ASLC_ID, 4);
+       memcpy(header->creator_id, ASLC_ID, 4);
 }
 
 void acpi_align(struct acpi_ctx *ctx)
@@ -219,7 +219,7 @@ void acpi_create_dbg2(struct acpi_dbg2_header *dbg2,
 
        header->revision = acpi_get_table_revision(ACPITAB_DBG2);
        acpi_fill_header(header, "DBG2");
-       header->aslc_revision = ASL_REVISION;
+       header->creator_revision = ASL_REVISION;
 
        /* One debug device defined */
        dbg2->devices_offset = sizeof(struct acpi_dbg2_header);
index b0a96f846e39e6642e84a4d3584c54fab97a4dc8..e032e266b3cf25800f36996db9f16eba827c88e7 100644 (file)
@@ -23,7 +23,7 @@ int acpi_write_ssdt(struct acpi_ctx *ctx, const struct acpi_writer *entry)
 
        acpi_fill_header(ssdt, "SSDT");
        ssdt->revision = acpi_get_table_revision(ACPITAB_SSDT);
-       ssdt->aslc_revision = 1;
+       ssdt->creator_revision = 1;
        ssdt->length = sizeof(struct acpi_table_header);
 
        acpi_inc(ctx, sizeof(struct acpi_table_header));
index c53ebcdb1c10ce8978ecb1717deaf9b3ccffd25f..f14b3962f8457494081e3c3ca643262a11742cb6 100644 (file)
@@ -237,7 +237,7 @@ static int dm_test_acpi_fill_header(struct unit_test_state *uts)
        hdr.length = 0x11;
        hdr.revision = 0x22;
        hdr.checksum = 0x33;
-       hdr.aslc_revision = 0x44;
+       hdr.creator_revision = 0x44;
        acpi_fill_header(&hdr, "ABCD");
 
        ut_asserteq_mem("ABCD", hdr.signature, sizeof(hdr.signature));
@@ -248,8 +248,8 @@ static int dm_test_acpi_fill_header(struct unit_test_state *uts)
        ut_asserteq_mem(OEM_TABLE_ID, hdr.oem_table_id,
                        sizeof(hdr.oem_table_id));
        ut_asserteq(OEM_REVISION, hdr.oem_revision);
-       ut_asserteq_mem(ASLC_ID, hdr.aslc_id, sizeof(hdr.aslc_id));
-       ut_asserteq(0x44, hdr.aslc_revision);
+       ut_asserteq_mem(ASLC_ID, hdr.creator_id, sizeof(hdr.creator_id));
+       ut_asserteq(0x44, hdr.creator_revision);
 
        return 0;
 }