From: Akinobu Mita <akinobu.mita@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Subject: [PATCH] lightning: return proper return code
Date: Sun, 29 Oct 2006 03:42:02 +0900 [thread overview]
Message-ID: <20061028184202.GC9973@localhost> (raw)
This patch makes module init return proper value instead of -1 (-EPERM).
Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
drivers/input/gameport/lightning.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
Index: work-fault-inject/drivers/input/gameport/lightning.c
===================================================================
--- work-fault-inject.orig/drivers/input/gameport/lightning.c
+++ work-fault-inject/drivers/input/gameport/lightning.c
@@ -309,7 +309,7 @@ static int __init l4_init(void)
int i, cards = 0;
if (!request_region(L4_PORT, 1, "lightning"))
- return -1;
+ return -EBUSY;
for (i = 0; i < 2; i++)
if (l4_add_card(i) == 0)
@@ -319,7 +319,7 @@ static int __init l4_init(void)
if (!cards) {
release_region(L4_PORT, 1);
- return -1;
+ return -ENODEV;
}
return 0;
reply other threads:[~2006-10-28 18:41 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20061028184202.GC9973@localhost \
--to=akinobu.mita@gmail.com \
--cc=dmitry.torokhov@gmail.com \
--cc=linux-kernel@vger.kernel.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