diff options
author | Rusty Russell <rusty@rustcorp.com.au> | 2006-03-25 14:07:05 +0300 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-03-25 19:22:52 +0300 |
commit | 8d3b33f67fdc0fb364a1ef6d8fbbea7c2e4e6c98 (patch) | |
tree | 7fc48e7544ea6a6c6a7cc7685612a38f5edc25ae /drivers/cdrom/sbpcd.c | |
parent | c721bccece2b3abca4f7b0b95108e68b78445cec (diff) | |
download | linux-8d3b33f67fdc0fb364a1ef6d8fbbea7c2e4e6c98.tar.xz |
[PATCH] Remove MODULE_PARM
MODULE_PARM was actually breaking: recent gcc version optimize them out as
unused. It's time to replace the last users, which are generally in the
most unloved drivers anyway.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/cdrom/sbpcd.c')
-rw-r--r-- | drivers/cdrom/sbpcd.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/drivers/cdrom/sbpcd.c b/drivers/cdrom/sbpcd.c index 4760f515f591..05c9e865ecaf 100644 --- a/drivers/cdrom/sbpcd.c +++ b/drivers/cdrom/sbpcd.c @@ -464,8 +464,13 @@ static int sbpcd[] = static __cacheline_aligned DEFINE_SPINLOCK(sbpcd_lock); static struct request_queue *sbpcd_queue; -MODULE_PARM(sbpcd, "2i"); -MODULE_PARM(max_drives, "i"); +/* You can only set the first pair, from old MODULE_PARM code. */ +static int sbpcd_set(const char *val, struct kernel_param *kp) +{ + get_options((char *)val, 2, (int *)sbpcd); + return 0; +} +module_param_call(sbpcd, sbpcd_set, NULL, NULL, 0); #define NUM_PROBE (sizeof(sbpcd) / sizeof(int)) @@ -553,6 +558,7 @@ static unsigned char msgnum; static char msgbuf[80]; static int max_drives = MAX_DRIVES; +module_param(max_drives, int, 0); #ifndef MODULE static unsigned char setup_done; static const char *str_sb_l = "soundblaster"; |