ACPI: fix sonypi ACPI driver registration to unregister on failure
Remove the assumption that acpi_bus_register_driver() returns the number of devices claimed. Returning the count is unreliable because devices may be hot-plugged in the future (admittedly not applicable for this driver). This also fixes a bug: if sonypi_acpi_driver was registered but found no devices, sonypi_exit() did not unregister it. Signed-off-by:Bjorn Helgaas <bjorn.helgaas@hp.com> Signed-off-by:
Andrew Morton <akpm@osdl.org> Signed-off-by:
Len Brown <len.brown@intel.com>
Loading
Please register or sign in to comment