summaryrefslogtreecommitdiffstats
path: root/drivers/acpi/acpica/dbinput.c
diff options
context:
space:
mode:
authorBob Moore <robert.moore@intel.com>2018-08-10 23:42:59 +0200
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2018-08-14 23:49:13 +0200
commitfb2ef998af44fb94214f3cf1c0e85d7a4e642fcb (patch)
treede7e1bc7d60d548c80618e67886b1f9239959a8a /drivers/acpi/acpica/dbinput.c
parentACPICA: AML Parser: skip opcodes that open a scope upon parse failure (diff)
downloadlinux-fb2ef998af44fb94214f3cf1c0e85d7a4e642fcb.tar.xz
linux-fb2ef998af44fb94214f3cf1c0e85d7a4e642fcb.zip
ACPICA: Debugger: Cleanup interface to the AML disassembler
If the disassembler is configured out (such as when the debugger is part of a kernel), these debugger commands are disabled: List Disassemble Further, the Debug (single-step) command is simplified because each line of code cannot be disassembled. Reported-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Erik Schmauss <erik.schmauss@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi/acpica/dbinput.c')
-rw-r--r--drivers/acpi/acpica/dbinput.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/acpi/acpica/dbinput.c b/drivers/acpi/acpica/dbinput.c
index 556ff59bbbfc..3e5f95390f0d 100644
--- a/drivers/acpi/acpica/dbinput.c
+++ b/drivers/acpi/acpica/dbinput.c
@@ -763,7 +763,12 @@ acpi_db_command_dispatch(char *input_buffer,
case CMD_DISASSEMBLE:
case CMD_DISASM:
+#ifdef ACPI_DISASSEMBLER
(void)acpi_db_disassemble_method(acpi_gbl_db_args[1]);
+#else
+ acpi_os_printf
+ ("The AML Disassembler is not configured/present\n");
+#endif
break;
case CMD_DUMP:
@@ -872,7 +877,12 @@ acpi_db_command_dispatch(char *input_buffer,
case CMD_LIST:
+#ifdef ACPI_DISASSEMBLER
acpi_db_disassemble_aml(acpi_gbl_db_args[1], op);
+#else
+ acpi_os_printf
+ ("The AML Disassembler is not configured/present\n");
+#endif
break;
case CMD_LOCKS: