diff options
-rw-r--r-- | drivers/acpi/acpica/psopinfo.c | 49 |
1 files changed, 47 insertions, 2 deletions
diff --git a/drivers/acpi/acpica/psopinfo.c b/drivers/acpi/acpica/psopinfo.c index 9ba5301e5751..d7bba3c7ce56 100644 --- a/drivers/acpi/acpica/psopinfo.c +++ b/drivers/acpi/acpica/psopinfo.c | |||
@@ -71,6 +71,8 @@ static const u8 acpi_gbl_argument_count[] = | |||
71 | 71 | ||
72 | const struct acpi_opcode_info *acpi_ps_get_opcode_info(u16 opcode) | 72 | const struct acpi_opcode_info *acpi_ps_get_opcode_info(u16 opcode) |
73 | { | 73 | { |
74 | const char *opcode_name = "Unknown AML opcode"; | ||
75 | |||
74 | ACPI_FUNCTION_NAME(ps_get_opcode_info); | 76 | ACPI_FUNCTION_NAME(ps_get_opcode_info); |
75 | 77 | ||
76 | /* | 78 | /* |
@@ -92,11 +94,54 @@ const struct acpi_opcode_info *acpi_ps_get_opcode_info(u16 opcode) | |||
92 | return (&acpi_gbl_aml_op_info | 94 | return (&acpi_gbl_aml_op_info |
93 | [acpi_gbl_long_op_index[(u8)opcode]]); | 95 | [acpi_gbl_long_op_index[(u8)opcode]]); |
94 | } | 96 | } |
97 | #ifdef ACPI_ASL_COMPILER | ||
98 | #include "asldefine.h" | ||
99 | |||
100 | switch (opcode) { | ||
101 | case AML_RAW_DATA_BYTE: | ||
102 | opcode_name = "-Raw Data Byte-"; | ||
103 | break; | ||
104 | |||
105 | case AML_RAW_DATA_WORD: | ||
106 | opcode_name = "-Raw Data Word-"; | ||
107 | break; | ||
108 | |||
109 | case AML_RAW_DATA_DWORD: | ||
110 | opcode_name = "-Raw Data Dword-"; | ||
111 | break; | ||
112 | |||
113 | case AML_RAW_DATA_QWORD: | ||
114 | opcode_name = "-Raw Data Qword-"; | ||
115 | break; | ||
116 | |||
117 | case AML_RAW_DATA_BUFFER: | ||
118 | opcode_name = "-Raw Data Buffer-"; | ||
119 | break; | ||
120 | |||
121 | case AML_RAW_DATA_CHAIN: | ||
122 | opcode_name = "-Raw Data Buffer Chain-"; | ||
123 | break; | ||
124 | |||
125 | case AML_PACKAGE_LENGTH: | ||
126 | opcode_name = "-Package Length-"; | ||
127 | break; | ||
128 | |||
129 | case AML_UNASSIGNED_OPCODE: | ||
130 | opcode_name = "-Unassigned Opcode-"; | ||
131 | break; | ||
132 | |||
133 | case AML_DEFAULT_ARG_OP: | ||
134 | opcode_name = "-Default Arg-"; | ||
135 | break; | ||
136 | |||
137 | default: | ||
138 | break; | ||
139 | } | ||
140 | #endif | ||
95 | 141 | ||
96 | /* Unknown AML opcode */ | 142 | /* Unknown AML opcode */ |
97 | 143 | ||
98 | ACPI_DEBUG_PRINT((ACPI_DB_EXEC, | 144 | ACPI_DEBUG_PRINT((ACPI_DB_EXEC, "%s [%4.4X]\n", opcode_name, opcode)); |
99 | "Unknown AML opcode [%4.4X]\n", opcode)); | ||
100 | 145 | ||
101 | return (&acpi_gbl_aml_op_info[_UNK]); | 146 | return (&acpi_gbl_aml_op_info[_UNK]); |
102 | } | 147 | } |