diff options
author | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2017-04-19 22:27:31 +0300 |
---|---|---|
committer | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2017-04-28 21:51:25 +0300 |
commit | 0b8dba15e909990e275631fa57255e74bbc766fc (patch) | |
tree | 9fcea3545ca2e87f83a281c021a6756cb130703c /drivers/platform | |
parent | 8d9e29972836b75eb74f533594999500a4c7cc19 (diff) | |
download | op-kernel-dev-0b8dba15e909990e275631fa57255e74bbc766fc.zip op-kernel-dev-0b8dba15e909990e275631fa57255e74bbc766fc.tar.gz |
platform/x86: hp-wireless: reuse module_acpi_driver
There is a macro to register and unregister modules in simple cases,
Let's use it and clean up the driver.
Cc: Alex Hung <alex.hung@canonical.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: Darren Hart (VMware) <dvhart@infradead.org>
Diffstat (limited to 'drivers/platform')
-rw-r--r-- | drivers/platform/x86/hp-wireless.c | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/drivers/platform/x86/hp-wireless.c b/drivers/platform/x86/hp-wireless.c index d860ea0..d6ea5e9 100644 --- a/drivers/platform/x86/hp-wireless.c +++ b/drivers/platform/x86/hp-wireless.c @@ -110,21 +110,4 @@ static struct acpi_driver hpwl_driver = { }, }; -static int __init hpwl_init(void) -{ - int err; - - err = acpi_bus_register_driver(&hpwl_driver); - if (err) - pr_err("Unable to register HP wireless control driver.\n"); - - return err; -} - -static void __exit hpwl_exit(void) -{ - acpi_bus_unregister_driver(&hpwl_driver); -} - -module_init(hpwl_init); -module_exit(hpwl_exit); +module_acpi_driver(hpwl_driver); |