From: Kristen Accardi * Change acpiphp to use the new return values that were modified on dock v3. Signed-off-by: Kristen Carlson Accardi Signed-off-by: Andrew Morton --- drivers/pci/hotplug/acpiphp.h | 1 + drivers/pci/hotplug/acpiphp_glue.c | 14 ++++++-------- 2 files changed, 7 insertions(+), 8 deletions(-) diff -puN drivers/pci/hotplug/acpiphp_glue.c~acpiphp-use-new-dock-driver-v2 drivers/pci/hotplug/acpiphp_glue.c --- devel/drivers/pci/hotplug/acpiphp_glue.c~acpiphp-use-new-dock-driver-v2 2006-04-28 23:59:00.000000000 -0700 +++ devel-akpm/drivers/pci/hotplug/acpiphp_glue.c 2006-04-28 23:59:00.000000000 -0700 @@ -59,8 +59,6 @@ static LIST_HEAD(bridge_list); static void handle_hotplug_event_bridge (acpi_handle, u32, void *); static void acpiphp_sanitize_bus(struct pci_bus *bus); static void acpiphp_set_hpp_values(acpi_handle handle, struct pci_bus *bus); -static void handle_hotplug_event_func(acpi_handle handle, u32 type, - void *context); /* @@ -275,16 +273,17 @@ register_slot(acpi_handle handle, u32 lv * to call it after it calls _DCK */ newfunc->flags &= ~FUNC_HAS_EJ0; - status = register_hotplug_dock_device(handle, handle_hotplug_event_func, - newfunc); - if (ACPI_FAILURE(status)) + if (register_hotplug_dock_device(handle, + handle_hotplug_event_func, newfunc)) dbg("failed to register dock device\n"); + /* we need to be notified when dock events happen * outside of the hotplug operation, since we may * need to do fixups before we can hotplug. */ newfunc->nb.notifier_call = post_dock_fixups; - register_dock_notifier(&newfunc->nb); + if (register_dock_notifier(&newfunc->nb)) + dbg("failed to register a dock notifier"); } /* install notify handler */ @@ -1388,8 +1387,7 @@ static void handle_hotplug_event_bridge( * handles ACPI event notification on slots * */ -static void handle_hotplug_event_func(acpi_handle handle, u32 type, - void *context) +void handle_hotplug_event_func(acpi_handle handle, u32 type, void *context) { struct acpiphp_func *func; char objname[64]; diff -puN drivers/pci/hotplug/acpiphp.h~acpiphp-use-new-dock-driver-v2 drivers/pci/hotplug/acpiphp.h --- devel/drivers/pci/hotplug/acpiphp.h~acpiphp-use-new-dock-driver-v2 2006-04-28 23:59:00.000000000 -0700 +++ devel-akpm/drivers/pci/hotplug/acpiphp.h 2006-04-28 23:59:00.000000000 -0700 @@ -198,6 +198,7 @@ extern int acpiphp_glue_init (void); extern void acpiphp_glue_exit (void); extern int acpiphp_get_num_slots (void); typedef int (*acpiphp_callback)(struct acpiphp_slot *slot, void *data); +void handle_hotplug_event_func(acpi_handle, u32, void*); extern int acpiphp_enable_slot (struct acpiphp_slot *slot); extern int acpiphp_disable_slot (struct acpiphp_slot *slot); _