mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Dmitry Torokhov <dtor_core@ameritech.net>
To: Vojtech Pavlik <vojtech@suse.cz>
Cc: Andrew Morton <akpm@osdl.org>, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 4/7] atkbd option parsing
Date: Sat, 3 Jan 2004 04:01:34 -0500	[thread overview]
Message-ID: <200401030401.35798.dtor_core@ameritech.net> (raw)
In-Reply-To: <200401030400.55755.dtor_core@ameritech.net>

===================================================================


ChangeSet@1.1574, 2004-01-03 02:45:27-05:00, dtor_core@ameritech.net
  Input: converted atkbd to the new style of option parsing.
         If compiled as a module new option names are:
         set, softrepeat, reset.
         If built into the kernel options must be prepended
         with "atkbd." prefix, like "atkbd.softrepeat"


 Documentation/kernel-parameters.txt |    7 +++---
 drivers/input/keyboard/atkbd.c      |   40 ++++++++----------------------------
 2 files changed, 13 insertions(+), 34 deletions(-)


===================================================================



diff -Nru a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt
--- a/Documentation/kernel-parameters.txt	Sat Jan  3 03:09:00 2004
+++ b/Documentation/kernel-parameters.txt	Sat Jan  3 03:09:00 2004
@@ -153,10 +153,11 @@
 
 	atascsi=	[HW,SCSI] Atari SCSI
 
-	atkbd_set=	[HW] Select keyboard code set
+	atkbd.set=	[HW] Select keyboard code set
 			Format: <int>
-
-	atkbd_reset	[HW] Reset keyboard during initialization
+	atkbd.softrepeat=
+			[HW] Use software keyboard repeat
+	atkbd.reset=	[HW] Reset keyboard during initialization
 
 	autotest	[IA64]
 
diff -Nru a/drivers/input/keyboard/atkbd.c b/drivers/input/keyboard/atkbd.c
--- a/drivers/input/keyboard/atkbd.c	Sat Jan  3 03:09:00 2004
+++ b/drivers/input/keyboard/atkbd.c	Sat Jan  3 03:09:00 2004
@@ -19,6 +19,7 @@
 
 #include <linux/delay.h>
 #include <linux/module.h>
+#include <linux/moduleparam.h>
 #include <linux/slab.h>
 #include <linux/interrupt.h>
 #include <linux/init.h>
@@ -29,18 +30,23 @@
 
 MODULE_AUTHOR("Vojtech Pavlik <vojtech@suse.cz>");
 MODULE_DESCRIPTION("AT and PS/2 keyboard driver");
-MODULE_PARM(atkbd_set, "1i");
-MODULE_PARM(atkbd_reset, "1i");
-MODULE_PARM(atkbd_softrepeat, "1i");
 MODULE_LICENSE("GPL");
 
 static int atkbd_set = 2;
+module_param_named(set, atkbd_set, int, 0);
+MODULE_PARM_DESC(set, "Select keyboard code set (2 = default, 3, 4)");
+
 #if defined(__i386__) || defined (__x86_64__)
 static int atkbd_reset;
 #else
 static int atkbd_reset = 1;
 #endif
+module_param_named(reset, atkbd_reset, bool, 0);
+MODULE_PARM_DESC(reset, "Reset keyboard during initialization");
+
 static int atkbd_softrepeat;
+module_param_named(softrepeat, atkbd_softrepeat, bool, 0);
+MODULE_PARM_DESC(softrepeat, "Use software keyboard repeat");
 
 /*
  * Scancode to keycode tables. These are just the default setting, and
@@ -759,34 +765,6 @@
 	.disconnect =	atkbd_disconnect,
 	.cleanup =	atkbd_cleanup,
 };
-
-#ifndef MODULE
-static int __init atkbd_setup_set(char *str)
-{
-        int ints[4];
-        str = get_options(str, ARRAY_SIZE(ints), ints);
-        if (ints[0] > 0) atkbd_set = ints[1];
-        return 1;
-}
-static int __init atkbd_setup_reset(char *str)
-{
-        int ints[4];
-        str = get_options(str, ARRAY_SIZE(ints), ints);
-        if (ints[0] > 0) atkbd_reset = ints[1];
-        return 1;
-}
-static int __init atkbd_setup_softrepeat(char *str)
-{
-        int ints[4];
-        str = get_options(str, ARRAY_SIZE(ints), ints);
-        if (ints[0] > 0) atkbd_softrepeat = ints[1];
-        return 1;
-}
-
-__setup("atkbd_set=", atkbd_setup_set);
-__setup("atkbd_reset", atkbd_setup_reset);
-__setup("atkbd_softrepeat=", atkbd_setup_softrepeat);
-#endif
 
 int __init atkbd_init(void)
 {

  reply	other threads:[~2004-01-03  9:07 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-03  8:50 New set of input patches Dmitry Torokhov
2004-01-03  8:56 ` [PATCH 1/7] i8042 suspend Dmitry Torokhov
2004-01-03  8:57   ` [PATCH 2/7] i8042 option parsing Dmitry Torokhov
2004-01-03  9:00     ` [PATCH 3/7] psmouse " Dmitry Torokhov
2004-01-03  9:01       ` Dmitry Torokhov [this message]
2004-01-03  9:02         ` [PATCH 5/7] missing module licenses Dmitry Torokhov
2004-01-03  9:03           ` [PATCH 6/7] Kconfig Synaptics help Dmitry Torokhov
2004-01-03  9:03             ` [PATCH 7/7] SiS AUX port Dmitry Torokhov
2004-03-29 15:39             ` Dmitry Torokhov
2004-03-29 15:39           ` [PATCH 6/7] Kconfig Synaptics help Dmitry Torokhov
2004-03-29 15:39         ` [PATCH 5/7] missing module licenses Dmitry Torokhov
2004-01-03 10:07       ` [PATCH 3/7] psmouse option parsing Vojtech Pavlik
2004-01-03 17:29         ` Dmitry Torokhov
2004-01-03 17:38           ` Vojtech Pavlik
2004-03-29 15:40           ` Vojtech Pavlik
2004-03-29 15:40         ` Dmitry Torokhov
2004-03-29 15:39       ` Vojtech Pavlik
2004-03-29 15:39       ` [PATCH 4/7] atkbd " Dmitry Torokhov
2004-03-29 15:39     ` [PATCH 3/7] psmouse " Dmitry Torokhov
2004-01-03 10:03   ` [PATCH 1/7] i8042 suspend Vojtech Pavlik
2004-01-03 16:50     ` Dmitry Torokhov
2004-03-29 15:40     ` Dmitry Torokhov
2004-01-18 19:23   ` Russell King
2004-01-18 22:42     ` Dmitry Torokhov
2004-03-29 15:39   ` [PATCH 2/7] i8042 option parsing Dmitry Torokhov
2004-03-29 15:39   ` [PATCH 1/7] i8042 suspend Vojtech Pavlik
2004-01-03 10:10 ` New set of input patches Vojtech Pavlik
2004-01-05  5:59 ` Dmitry Torokhov
2004-01-05  6:01   ` [PATCH 1/3] Fix compile error in 98busmouse.c module Dmitry Torokhov
2004-01-05  6:02     ` [PATCH 2/3] Convert mouse drivers to use module_param Dmitry Torokhov
2004-01-05  6:03       ` [PATCH 3/3] Convert tsdev " Dmitry Torokhov
2004-03-29 15:44       ` Dmitry Torokhov
2004-03-29 15:44     ` [PATCH 2/3] Convert mouse drivers " Dmitry Torokhov
2004-01-05  8:36   ` New set of input patches Vojtech Pavlik
2004-03-29 15:44   ` [PATCH 1/3] Fix compile error in 98busmouse.c module Dmitry Torokhov
2004-03-29 15:44   ` New set of input patches Vojtech Pavlik
2004-03-29 15:39 ` [PATCH 1/7] i8042 suspend Dmitry Torokhov
2004-03-29 15:39 ` New set of input patches Vojtech Pavlik
2004-03-29 15:44 ` Dmitry Torokhov

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=200401030401.35798.dtor_core@ameritech.net \
    --to=dtor_core@ameritech.net \
    --cc=akpm@osdl.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=vojtech@suse.cz \
    /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

Powered by JetHome