mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
ACPICA: Rename nameseg length macro/define for clarity
ACPICA commit 24870bd9e73d71e2a1ff0a1e94519f8f8409e57d
ACPI_NAME_SIZE changed to ACPI_NAMESEG_SIZE
This clarifies that this is the length of an individual
nameseg, not the length of a generic namestring/namepath.
Improves understanding of the code.
Link: 24870bd9
Signed-off-by: Bob Moore <[email protected]>
Signed-off-by: Erik Schmauss <[email protected]>
Signed-off-by: Rafael J. Wysocki <[email protected]>
This commit is contained in:
parent
5599fb6935
commit
3278675567
24 changed files with 61 additions and 61 deletions
|
|
@ -66,14 +66,14 @@
|
|||
******************************************************************************/
|
||||
|
||||
struct acpi_table_header {
|
||||
char signature[ACPI_NAME_SIZE]; /* ASCII table signature */
|
||||
char signature[ACPI_NAMESEG_SIZE]; /* ASCII table signature */
|
||||
u32 length; /* Length of table in bytes, including this header */
|
||||
u8 revision; /* ACPI Specification minor version number */
|
||||
u8 checksum; /* To make sum of entire table == 0 */
|
||||
char oem_id[ACPI_OEM_ID_SIZE]; /* ASCII OEM identification */
|
||||
char oem_table_id[ACPI_OEM_TABLE_ID_SIZE]; /* ASCII OEM table identification */
|
||||
u32 oem_revision; /* OEM revision number */
|
||||
char asl_compiler_id[ACPI_NAME_SIZE]; /* ASCII ASL compiler vendor ID */
|
||||
char asl_compiler_id[ACPI_NAMESEG_SIZE]; /* ASCII ASL compiler vendor ID */
|
||||
u32 asl_compiler_revision; /* ASL compiler version */
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -375,7 +375,7 @@ typedef u64 acpi_physical_address;
|
|||
|
||||
/* Names within the namespace are 4 bytes long */
|
||||
|
||||
#define ACPI_NAME_SIZE 4
|
||||
#define ACPI_NAMESEG_SIZE 4 /* Fixed by ACPI spec */
|
||||
#define ACPI_PATH_SEGMENT_LENGTH 5 /* 4 chars for name + 1 char for separator */
|
||||
#define ACPI_PATH_SEPARATOR '.'
|
||||
|
||||
|
|
@ -518,8 +518,8 @@ typedef u64 acpi_integer;
|
|||
#define ACPI_COMPARE_NAMESEG(a,b) (*ACPI_CAST_PTR (u32, (a)) == *ACPI_CAST_PTR (u32, (b)))
|
||||
#define ACPI_COPY_NAMESEG(dest,src) (*ACPI_CAST_PTR (u32, (dest)) = *ACPI_CAST_PTR (u32, (src)))
|
||||
#else
|
||||
#define ACPI_COMPARE_NAMESEG(a,b) (!strncmp (ACPI_CAST_PTR (char, (a)), ACPI_CAST_PTR (char, (b)), ACPI_NAME_SIZE))
|
||||
#define ACPI_COPY_NAMESEG(dest,src) (strncpy (ACPI_CAST_PTR (char, (dest)), ACPI_CAST_PTR (char, (src)), ACPI_NAME_SIZE))
|
||||
#define ACPI_COMPARE_NAMESEG(a,b) (!strncmp (ACPI_CAST_PTR (char, (a)), ACPI_CAST_PTR (char, (b)), ACPI_NAMESEG_SIZE))
|
||||
#define ACPI_COPY_NAMESEG(dest,src) (strncpy (ACPI_CAST_PTR (char, (dest)), ACPI_CAST_PTR (char, (src)), ACPI_NAMESEG_SIZE))
|
||||
#endif
|
||||
|
||||
/* Support for the special RSDP signature (8 characters) */
|
||||
|
|
@ -529,7 +529,7 @@ typedef u64 acpi_integer;
|
|||
|
||||
/* Support for OEMx signature (x can be any character) */
|
||||
#define ACPI_IS_OEM_SIG(a) (!strncmp (ACPI_CAST_PTR (char, (a)), ACPI_OEM_NAME, 3) &&\
|
||||
strnlen (a, ACPI_NAME_SIZE) == ACPI_NAME_SIZE)
|
||||
strnlen (a, ACPI_NAMESEG_SIZE) == ACPI_NAMESEG_SIZE)
|
||||
|
||||
/*
|
||||
* Algorithm to obtain access bit width.
|
||||
|
|
|
|||
Loading…
Reference in a new issue