diff options
author | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2020-05-07 19:37:23 +0300 |
---|---|---|
committer | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2020-05-07 19:39:32 +0300 |
commit | e257dd340f2723be1a28d41e1a66d589ec3d914c (patch) | |
tree | 5efc1841848ae6321347a04aa7ac350cd8e57d32 /drivers/platform/x86 | |
parent | 2225dba20529fb71f0a7716b47b6123d521f103b (diff) | |
download | linux-e257dd340f2723be1a28d41e1a66d589ec3d914c.tar.xz |
platform/x86: eeepc-laptop: Drop duplicate check for led_classdev_unregister()
led_classdev_unregister() already has the very same check, so,
drop a duplicate in the driver.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Diffstat (limited to 'drivers/platform/x86')
-rw-r--r-- | drivers/platform/x86/eeepc-laptop.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/platform/x86/eeepc-laptop.c b/drivers/platform/x86/eeepc-laptop.c index 776868d5e458..ba08c9235f76 100644 --- a/drivers/platform/x86/eeepc-laptop.c +++ b/drivers/platform/x86/eeepc-laptop.c @@ -541,13 +541,11 @@ static int eeepc_led_init(struct eeepc_laptop *eeepc) static void eeepc_led_exit(struct eeepc_laptop *eeepc) { - if (!IS_ERR_OR_NULL(eeepc->tpd_led.dev)) - led_classdev_unregister(&eeepc->tpd_led); + led_classdev_unregister(&eeepc->tpd_led); if (eeepc->led_workqueue) destroy_workqueue(eeepc->led_workqueue); } - /* * PCI hotplug (for wlan rfkill) */ |