linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] floppy: change MODULE_PARM to module_param in drivers/block/floppy.c
@ 2004-10-30 13:42 james4765
  2004-10-30 16:20 ` [KJ] " Randy.Dunlap
  0 siblings, 1 reply; 4+ messages in thread
From: james4765 @ 2004-10-30 13:42 UTC (permalink / raw)
  To: kernel-janitors, linux-kernel; +Cc: james4765

Replace MODULE_PARM with module_param in drivers/block/floppy.c.  Compile tested.

Signed-off-by: James Nelson <james4765@gmail.com>

diff -urN --exclude='*~' linux-2.6.9-original/drivers/block/floppy.c linux-2.6.9/drivers/block/floppy.c
--- linux-2.6.9-original/drivers/block/floppy.c	2004-10-18 17:53:22.000000000 -0400
+++ linux-2.6.9/drivers/block/floppy.c	2004-10-30 09:16:04.856720081 -0400
@@ -180,6 +180,7 @@
 #include <linux/devfs_fs_kernel.h>
 #include <linux/device.h>
 #include <linux/buffer_head.h>	/* for invalidate_buffers() */
+#include <linux/moduleparam.h>
 
 /*
  * PS/2 floppies have much slower step rates than regular floppies.
@@ -4623,9 +4624,9 @@
 	wait_for_completion(&device_release);
 }
 
-MODULE_PARM(floppy, "s");
-MODULE_PARM(FLOPPY_IRQ, "i");
-MODULE_PARM(FLOPPY_DMA, "i");
+module_param(floppy, charp, 0);
+module_param(FLOPPY_IRQ, int, 0);
+module_param(FLOPPY_DMA, int, 0);
 MODULE_AUTHOR("Alain L. Knaff");
 MODULE_SUPPORTED_DEVICE("fd");
 MODULE_LICENSE("GPL");

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [KJ] [PATCH] floppy: change MODULE_PARM to module_param in drivers/block/floppy.c
  2004-10-30 13:42 [PATCH] floppy: change MODULE_PARM to module_param in drivers/block/floppy.c james4765
@ 2004-10-30 16:20 ` Randy.Dunlap
  2004-10-30 18:03   ` Dmitry Torokhov
  0 siblings, 1 reply; 4+ messages in thread
From: Randy.Dunlap @ 2004-10-30 16:20 UTC (permalink / raw)
  To: james4765; +Cc: kernel-janitors, linux-kernel

james4765@verizon.net wrote:
> Replace MODULE_PARM with module_param in drivers/block/floppy.c.  Compile tested.
> 
> Signed-off-by: James Nelson <james4765@gmail.com>
> 
> diff -urN --exclude='*~' linux-2.6.9-original/drivers/block/floppy.c linux-2.6.9/drivers/block/floppy.c
> --- linux-2.6.9-original/drivers/block/floppy.c	2004-10-18 17:53:22.000000000 -0400
> +++ linux-2.6.9/drivers/block/floppy.c	2004-10-30 09:16:04.856720081 -0400
> @@ -180,6 +180,7 @@
>  #include <linux/devfs_fs_kernel.h>
>  #include <linux/device.h>
>  #include <linux/buffer_head.h>	/* for invalidate_buffers() */
> +#include <linux/moduleparam.h>
>  
>  /*
>   * PS/2 floppies have much slower step rates than regular floppies.
> @@ -4623,9 +4624,9 @@
>  	wait_for_completion(&device_release);
>  }
>  
> -MODULE_PARM(floppy, "s");
> -MODULE_PARM(FLOPPY_IRQ, "i");
> -MODULE_PARM(FLOPPY_DMA, "i");
> +module_param(floppy, charp, 0);
> +module_param(FLOPPY_IRQ, int, 0);
> +module_param(FLOPPY_DMA, int, 0);
>  MODULE_AUTHOR("Alain L. Knaff");
>  MODULE_SUPPORTED_DEVICE("fd");
>  MODULE_LICENSE("GPL");

Please check Andrew's 2.6.10-rc1-mm2 for a large MODULE_PARAM
patch, and then convert drivers that are not yet converted...

http://www.kernel.org/pub/linux/kernel/people/akpm/patches/2.6/2.6.10-rc1/2.6.10-rc1-mm2/broken-out/convert-module_parm-to-module_param-family.patch


-- 
~Randy

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [KJ] [PATCH] floppy: change MODULE_PARM to module_param in drivers/block/floppy.c
  2004-10-30 16:20 ` [KJ] " Randy.Dunlap
@ 2004-10-30 18:03   ` Dmitry Torokhov
  2004-10-30 19:10     ` Jim Nelson
  0 siblings, 1 reply; 4+ messages in thread
From: Dmitry Torokhov @ 2004-10-30 18:03 UTC (permalink / raw)
  To: linux-kernel; +Cc: Randy.Dunlap, james4765, kernel-janitors

On Saturday 30 October 2004 11:20 am, Randy.Dunlap wrote:
> james4765@verizon.net wrote:
> > Replace MODULE_PARM with module_param in drivers/block/floppy.c.  Compile tested.
> > 
> > Signed-off-by: James Nelson <james4765@gmail.com>
> > 
> > diff -urN --exclude='*~' linux-2.6.9-original/drivers/block/floppy.c linux-2.6.9/drivers/block/floppy.c
> > --- linux-2.6.9-original/drivers/block/floppy.c	2004-10-18 17:53:22.000000000 -0400
> > +++ linux-2.6.9/drivers/block/floppy.c	2004-10-30 09:16:04.856720081 -0400
> > @@ -180,6 +180,7 @@
> >  #include <linux/devfs_fs_kernel.h>
> >  #include <linux/device.h>
> >  #include <linux/buffer_head.h>	/* for invalidate_buffers() */
> > +#include <linux/moduleparam.h>
> >  
> >  /*
> >   * PS/2 floppies have much slower step rates than regular floppies.
> > @@ -4623,9 +4624,9 @@
> >  	wait_for_completion(&device_release);
> >  }
> >  
> > -MODULE_PARM(floppy, "s");
> > -MODULE_PARM(FLOPPY_IRQ, "i");
> > -MODULE_PARM(FLOPPY_DMA, "i");
> > +module_param(floppy, charp, 0);
> > +module_param(FLOPPY_IRQ, int, 0);
> > +module_param(FLOPPY_DMA, int, 0);
> >  MODULE_AUTHOR("Alain L. Knaff");
> >  MODULE_SUPPORTED_DEVICE("fd");
> >  MODULE_LICENSE("GPL");
> 
> Please check Andrew's 2.6.10-rc1-mm2 for a large MODULE_PARAM
> patch, and then convert drivers that are not yet converted...
> 
> http://www.kernel.org/pub/linux/kernel/people/akpm/patches/2.6/2.6.10-rc1/2.6.10-rc1-mm2/broken-out/convert-module_parm-to-module_param-family.patch
> 

Actually it would be nice if drivers were converted "intelligently"
instead of basic find-and-replace - I really find parameter names
like floppy.floppy= or floppy.floppy_dma= ugly.

-- 
Dmitry

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [KJ] [PATCH] floppy: change MODULE_PARM to module_param in drivers/block/floppy.c
  2004-10-30 18:03   ` Dmitry Torokhov
@ 2004-10-30 19:10     ` Jim Nelson
  0 siblings, 0 replies; 4+ messages in thread
From: Jim Nelson @ 2004-10-30 19:10 UTC (permalink / raw)
  To: Dmitry Torokhov; +Cc: linux-kernel, Randy.Dunlap, kernel-janitors

Dmitry Torokhov wrote:
> On Saturday 30 October 2004 11:20 am, Randy.Dunlap wrote:
> 
>>james4765@verizon.net wrote:
>>
>>>Replace MODULE_PARM with module_param in drivers/block/floppy.c.  Compile tested.
>>>
>>>Signed-off-by: James Nelson <james4765@gmail.com>
>>>
>>>diff -urN --exclude='*~' linux-2.6.9-original/drivers/block/floppy.c linux-2.6.9/drivers/block/floppy.c
>>>--- linux-2.6.9-original/drivers/block/floppy.c	2004-10-18 17:53:22.000000000 -0400
>>>+++ linux-2.6.9/drivers/block/floppy.c	2004-10-30 09:16:04.856720081 -0400
>>>@@ -180,6 +180,7 @@
>>> #include <linux/devfs_fs_kernel.h>
>>> #include <linux/device.h>
>>> #include <linux/buffer_head.h>	/* for invalidate_buffers() */
>>>+#include <linux/moduleparam.h>
>>> 
>>> /*
>>>  * PS/2 floppies have much slower step rates than regular floppies.
>>>@@ -4623,9 +4624,9 @@
>>> 	wait_for_completion(&device_release);
>>> }
>>> 
>>>-MODULE_PARM(floppy, "s");
>>>-MODULE_PARM(FLOPPY_IRQ, "i");
>>>-MODULE_PARM(FLOPPY_DMA, "i");
>>>+module_param(floppy, charp, 0);
>>>+module_param(FLOPPY_IRQ, int, 0);
>>>+module_param(FLOPPY_DMA, int, 0);
>>> MODULE_AUTHOR("Alain L. Knaff");
>>> MODULE_SUPPORTED_DEVICE("fd");
>>> MODULE_LICENSE("GPL");
>>
>>Please check Andrew's 2.6.10-rc1-mm2 for a large MODULE_PARAM
>>patch, and then convert drivers that are not yet converted...
>>
>>http://www.kernel.org/pub/linux/kernel/people/akpm/patches/2.6/2.6.10-rc1/2.6.10-rc1-mm2/broken-out/convert-module_parm-to-module_param-family.patch
>>

Sorry - that was a quickie w/o checking to see if someone else had already done 
it.  See below.

> 
> 
> Actually it would be nice if drivers were converted "intelligently"
> instead of basic find-and-replace - I really find parameter names
> like floppy.floppy= or floppy.floppy_dma= ugly.
> 
Hmm.  I can tak a look at that a little bit later - just got done with a *huge* 
cleanup of floppy.c - just gotta do the diffs and send them.

Jim

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2004-10-30 19:11 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-10-30 13:42 [PATCH] floppy: change MODULE_PARM to module_param in drivers/block/floppy.c james4765
2004-10-30 16:20 ` [KJ] " Randy.Dunlap
2004-10-30 18:03   ` Dmitry Torokhov
2004-10-30 19:10     ` Jim Nelson

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).