Re: [PATCH] parport_pc MODULE_PARM fix
From: Jonathan McDowell
Date: Mon Dec 06 2004 - 13:26:34 EST
On Mon, Dec 06, 2004 at 09:44:03AM -0800, Randy.Dunlap wrote:
> Jonathan McDowell wrote:
> > ps2, epp, ecp or ecpepp)");
> >-MODULE_PARM(init_mode, "s");
> >+module_param_string(init_mode, init_mode, 7, 0);
> > #endif
> I think that it should be:
>
> module_param(init_mode, charp, 0);
>
> and leave 'init_mode' as a char *, not a char array.
>
> Can you test that change and resubmit the patch (if it works :) ?
Even better; that does the trick too. Extremely trivial patch below.
Signed-Off-By: Jonathan McDowell <noodles@xxxxxxxx>
-----
--- drivers/parport/parport_pc.c.orig 2004-12-06 17:44:08.000000000 +0000
+++ drivers/parport/parport_pc.c 2004-12-06 18:18:43.000000000 +0000
@@ -3157,7 +3157,7 @@
#ifdef CONFIG_PCI
static int __init parport_init_mode_setup(char *str)
{
- printk(KERN_DEBUG "parport_pc.c: Specified parameter parport_init_mode=%s\n", str);
+ DPRINTK(KERN_DEBUG "parport_pc.c: Specified parameter parport_init_mode=%s\n", str);
if (!strcmp (str, "spp"))
parport_init_mode=1;
@@ -3193,7 +3193,7 @@
#endif
#ifdef CONFIG_PCI
MODULE_PARM_DESC(init_mode, "Initialise mode for VIA VT8231 port (spp, ps2, epp, ecp or ecpepp)");
-MODULE_PARM(init_mode, "s");
+module_param(init_mode, charp, 0);
#endif
static int __init parse_parport_params(void)
-----
J.
--
/-\ | 101 things you can't have too much
|@/ Debian GNU/Linux Developer | of : 19 - A Good Thing.
\- |
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/