diff options
author | Akinobu Mita <akinobu.mita@gmail.com> | 2006-10-30 16:08:04 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2006-12-01 17:36:58 -0500 |
commit | 0a9dee2739fd4385e83c3316e3f3bee641796638 (patch) | |
tree | 0939f843f1881745ded480b4fa1ae9dec72350cc /drivers/pci/hotplug | |
parent | 467c442f092e22acf86a3b4ad4863d097d7257da (diff) |
acpiphp: fix missing acpiphp_glue_exit()
acpiphp_glue_exit() needs to be called to unwind when no slots found.
(It fixes data corruption when reloading acpiphp driver with no such devices)
Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/pci/hotplug')
-rw-r--r-- | drivers/pci/hotplug/acpiphp_core.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/pci/hotplug/acpiphp_core.c b/drivers/pci/hotplug/acpiphp_core.c index c57d9d5ce84e..c8b690741149 100644 --- a/drivers/pci/hotplug/acpiphp_core.c +++ b/drivers/pci/hotplug/acpiphp_core.c | |||
@@ -303,8 +303,10 @@ static int __init init_acpi(void) | |||
303 | /* read initial number of slots */ | 303 | /* read initial number of slots */ |
304 | if (!retval) { | 304 | if (!retval) { |
305 | num_slots = acpiphp_get_num_slots(); | 305 | num_slots = acpiphp_get_num_slots(); |
306 | if (num_slots == 0) | 306 | if (num_slots == 0) { |
307 | acpiphp_glue_exit(); | ||
307 | retval = -ENODEV; | 308 | retval = -ENODEV; |
309 | } | ||
308 | } | 310 | } |
309 | 311 | ||
310 | return retval; | 312 | return retval; |