From: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
To: Willy Tarreau <willy@meta-x.org>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org,
Sudip Mukherjee <sudipm.mukherjee@gmail.com>
Subject: [PATCH] staging: panel: remove duplicate code
Date: Tue, 7 Apr 2015 13:55:01 +0530 [thread overview]
Message-ID: <1428395101-20098-1-git-send-email-sudipm.mukherjee@gmail.com> (raw)
both the misc_deregister(), parport_release() and
parport_unregister_device() is there in the module_exit function also.
detach is called from parport_unregister_driver() and by the time
detach executes misc_deregister(), parport_release() and
parport_unregister_device() has already executed marking
keypad_initialized and lcd.initialized as false. so this part of the
code will never execute.
Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
---
drivers/staging/panel/panel.c | 14 --------------
1 file changed, 14 deletions(-)
diff --git a/drivers/staging/panel/panel.c b/drivers/staging/panel/panel.c
index ea54fb4..1d8ed8b 100644
--- a/drivers/staging/panel/panel.c
+++ b/drivers/staging/panel/panel.c
@@ -2252,20 +2252,6 @@ static void panel_detach(struct parport *port)
}
unregister_reboot_notifier(&panel_notifier);
-
- if (keypad.enabled && keypad_initialized) {
- misc_deregister(&keypad_dev);
- keypad_initialized = 0;
- }
-
- if (lcd.enabled && lcd.initialized) {
- misc_deregister(&lcd_dev);
- lcd.initialized = false;
- }
-
- parport_release(pprt);
- parport_unregister_device(pprt);
- pprt = NULL;
}
static struct parport_driver panel_driver = {
--
1.8.1.2
next reply other threads:[~2015-04-07 8:25 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-07 8:25 Sudip Mukherjee [this message]
2015-04-07 8:49 ` [PATCH] staging: panel: remove duplicate code Dan Carpenter
2015-04-07 9:25 ` Sudip Mukherjee
2015-04-07 9:44 ` Greg Kroah-Hartman
2015-04-07 9:56 ` Sudip Mukherjee
2015-04-07 10:12 ` Greg Kroah-Hartman
2015-04-07 14:14 ` Willy Tarreau
2015-04-07 14:21 ` Sudip Mukherjee
2015-04-07 14:33 ` Willy Tarreau
2015-04-07 14:41 ` Sudip Mukherjee
2015-04-07 9:45 ` Dan Carpenter
2015-04-07 10:36 ` Sudip Mukherjee
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1428395101-20098-1-git-send-email-sudipm.mukherjee@gmail.com \
--to=sudipm.mukherjee@gmail.com \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=willy@meta-x.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).