diff options
author | Len Brown | 2006-06-16 03:28:57 +0200 |
---|---|---|
committer | Len Brown | 2006-06-16 03:28:57 +0200 |
commit | 69cd291c6bbc6647fe3783257c5a2e076e808f71 (patch) | |
tree | 6f65a2d7d29228129cef09343c485aad64e3a3f1 /drivers/char/sonypi.c | |
parent | Pull bugzilla-5452 into release branch (diff) | |
parent | ACPI: acpi_bus_unregister_driver() returns void (diff) | |
download | kernel-qcow2-linux-69cd291c6bbc6647fe3783257c5a2e076e808f71.tar.gz kernel-qcow2-linux-69cd291c6bbc6647fe3783257c5a2e076e808f71.tar.xz kernel-qcow2-linux-69cd291c6bbc6647fe3783257c5a2e076e808f71.zip |
Pull acpi_bus_register_driver into release branch
Conflicts:
drivers/acpi/asus_acpi.c
drivers/acpi/scan.c
Diffstat (limited to 'drivers/char/sonypi.c')
-rw-r--r-- | drivers/char/sonypi.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/char/sonypi.c b/drivers/char/sonypi.c index a90f5d97df35..43dfd8689dce 100644 --- a/drivers/char/sonypi.c +++ b/drivers/char/sonypi.c @@ -512,7 +512,7 @@ static struct sonypi_device { #ifdef CONFIG_ACPI static struct acpi_device *sonypi_acpi_device; -static int acpi_enabled; +static int acpi_driver_registered; #endif static int sonypi_ec_write(u8 addr, u8 value) @@ -869,7 +869,7 @@ found: sonypi_report_input_event(event); #ifdef CONFIG_ACPI - if (acpi_enabled) + if (sonypi_acpi_device) acpi_bus_generate_event(sonypi_acpi_device, 1, event); #endif @@ -1551,8 +1551,8 @@ static int __init sonypi_init(void) goto err_free_device; #ifdef CONFIG_ACPI - if (acpi_bus_register_driver(&sonypi_acpi_driver) > 0) - acpi_enabled = 1; + if (acpi_bus_register_driver(&sonypi_acpi_driver) >= 0) + acpi_driver_registered = 1; #endif return 0; @@ -1567,7 +1567,7 @@ static int __init sonypi_init(void) static void __exit sonypi_exit(void) { #ifdef CONFIG_ACPI - if (acpi_enabled) + if (acpi_driver_registered) acpi_bus_unregister_driver(&sonypi_acpi_driver); #endif platform_device_unregister(sonypi_platform_device); |