From 9a40faefcf568d4eb54ec2a0b4700907a82cae7c Mon Sep 17 00:00:00 2001 From: Tang Chen Date: Mon, 21 Jan 2013 13:20:49 -0800 Subject: [PATCH] --- yaml --- r: 358415 b: refs/heads/master c: 121b090e7d4063b65f40c267ef0fb34fb278dfdf h: refs/heads/master i: 358413: 491fc65347383dcd5b058185e21ef4f1746ae545 358411: 2fb83f08d8a81f3951821c0888b7cf2a4d81b702 358407: 3cdc9fbdbf97d6361dd5ba5034c394c591458119 358399: 13c6cfdfa75cf1bfd490bdc5a20e4b167ca7ae78 v: v3 --- [refs] | 2 +- trunk/drivers/acpi/pci_root.c | 12 +++++++++--- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/[refs] b/[refs] index b8b6e07b2a1f..5ecea1235700 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 668192b678201d2fff27c6cc76bb003c1ec4a52a +refs/heads/master: 121b090e7d4063b65f40c267ef0fb34fb278dfdf diff --git a/trunk/drivers/acpi/pci_root.c b/trunk/drivers/acpi/pci_root.c index 1389811aa21b..fd59f57d3829 100644 --- a/trunk/drivers/acpi/pci_root.c +++ b/trunk/drivers/acpi/pci_root.c @@ -769,6 +769,7 @@ static void handle_hotplug_event_root(acpi_handle handle, u32 type, static acpi_status __init find_root_bridges(acpi_handle handle, u32 lvl, void *context, void **rv) { + acpi_status status; char objname[64]; struct acpi_buffer buffer = { .length = sizeof(objname), .pointer = objname }; @@ -781,9 +782,14 @@ find_root_bridges(acpi_handle handle, u32 lvl, void *context, void **rv) acpi_get_name(handle, ACPI_FULL_PATHNAME, &buffer); - acpi_install_notify_handler(handle, ACPI_SYSTEM_NOTIFY, - handle_hotplug_event_root, NULL); - printk(KERN_DEBUG "acpi root: %s notify handler installed\n", objname); + status = acpi_install_notify_handler(handle, ACPI_SYSTEM_NOTIFY, + handle_hotplug_event_root, NULL); + if (ACPI_FAILURE(status)) + printk(KERN_DEBUG "acpi root: %s notify handler is not installed, exit status: %u\n", + objname, (unsigned int)status); + else + printk(KERN_DEBUG "acpi root: %s notify handler is installed\n", + objname); return AE_OK; }