[Linux-parport] Re: [PATCH] parport_pc MODULE_PARM fix
Jonathan McDowell
noodles at earth.li
Mon Dec 6 13:24:38 EST 2004
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 at earth.li>
-----
--- 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.
\- |
More information about the Linux-parport
mailing list