Commit 3f77b439 authored by Geert Uytterhoeven's avatar Geert Uytterhoeven Committed by Greg Kroah-Hartman

misc: panel: Remove always-true check from panel_detach()

panel_detach() already verified that pptr is a valid pointer.
Signed-off-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 9db3cf1c
...@@ -2266,7 +2266,6 @@ static void panel_detach(struct parport *port) ...@@ -2266,7 +2266,6 @@ static void panel_detach(struct parport *port)
if (scan_timer.function) if (scan_timer.function)
del_timer_sync(&scan_timer); del_timer_sync(&scan_timer);
if (pprt) {
if (keypad.enabled) { if (keypad.enabled) {
misc_deregister(&keypad_dev); misc_deregister(&keypad_dev);
keypad_initialized = 0; keypad_initialized = 0;
...@@ -2283,7 +2282,6 @@ static void panel_detach(struct parport *port) ...@@ -2283,7 +2282,6 @@ static void panel_detach(struct parport *port)
parport_unregister_device(pprt); parport_unregister_device(pprt);
pprt = NULL; pprt = NULL;
unregister_reboot_notifier(&panel_notifier); unregister_reboot_notifier(&panel_notifier);
}
} }
static struct parport_driver panel_driver = { static struct parport_driver panel_driver = {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment