summaryrefslogtreecommitdiffstats
path: root/drivers/acpi/acpica/dbdisply.c
diff options
context:
space:
mode:
authorLv Zheng <lv.zheng@intel.com>2015-12-29 14:02:00 +0800
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2016-01-01 03:47:37 +0100
commitf31a99cefd05f798eee8b592e22175ff3fe1876b (patch)
tree6256bae4642ea41ae3f82fc55fc6db8ffa9c2e8e /drivers/acpi/acpica/dbdisply.c
parent7b73806485ada16059ecc1851793dbe865181c53 (diff)
downloadlinux-f31a99cefd05f798eee8b592e22175ff3fe1876b.tar.bz2
ACPICA: Events: Deploys acpi_ev_find_region_handler()
ACPICA commit b916a0a0ae9e81db1a85523c63ec6aa32d5c70c8 There are code fragments that can be substituted by acpi_ev_find_region_handler(). This patch cleans up these code fragments. Lv Zheng. Link: https://github.com/acpica/acpica/commit/b916a0a0 Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi/acpica/dbdisply.c')
-rw-r--r--drivers/acpi/acpica/dbdisply.c30
1 files changed, 14 insertions, 16 deletions
diff --git a/drivers/acpi/acpica/dbdisply.c b/drivers/acpi/acpica/dbdisply.c
index 390a7ca1c170..a66b4ae443c9 100644
--- a/drivers/acpi/acpica/dbdisply.c
+++ b/drivers/acpi/acpica/dbdisply.c
@@ -48,6 +48,7 @@
#include "acnamesp.h"
#include "acparser.h"
#include "acinterp.h"
+#include "acevents.h"
#include "acdebug.h"
#define _COMPONENT ACPI_CA_DEBUGGER
@@ -949,28 +950,25 @@ void acpi_db_display_handlers(void)
if (obj_desc) {
for (i = 0; i < ACPI_ARRAY_LENGTH(acpi_gbl_space_id_list); i++) {
space_id = acpi_gbl_space_id_list[i];
- handler_obj = obj_desc->device.handler;
acpi_os_printf(ACPI_PREDEFINED_PREFIX,
acpi_ut_get_region_name((u8)space_id),
space_id);
- while (handler_obj) {
- if (acpi_gbl_space_id_list[i] ==
- handler_obj->address_space.space_id) {
- acpi_os_printf
- (ACPI_HANDLER_PRESENT_STRING,
- (handler_obj->address_space.
- handler_flags &
- ACPI_ADDR_HANDLER_DEFAULT_INSTALLED)
- ? "Default" : "User",
- handler_obj->address_space.
- handler);
-
- goto found_handler;
- }
+ handler_obj =
+ acpi_ev_find_region_handler(space_id,
+ obj_desc->device.
+ handler);
+ if (handler_obj) {
+ acpi_os_printf(ACPI_HANDLER_PRESENT_STRING,
+ (handler_obj->address_space.
+ handler_flags &
+ ACPI_ADDR_HANDLER_DEFAULT_INSTALLED)
+ ? "Default" : "User",
+ handler_obj->address_space.
+ handler);
- handler_obj = handler_obj->address_space.next;
+ goto found_handler;
}
/* There is no handler for this space_id */