diff options
author | Hans Verkuil <devnull@localhost> | 2006-01-11 21:01:01 +0000 |
---|---|---|
committer | Hans Verkuil <devnull@localhost> | 2006-01-11 21:01:01 +0000 |
commit | 9985093e2b4f19b1d13d5004346f22540c92cc5d (patch) | |
tree | 12183d0a027579a81106fbfd7f1a7f92bd7451fd /linux/drivers/media/video/tuner-core.c | |
parent | 069637ed9609cb009c57d2bf1039e69812b2304b (diff) | |
download | mediapointer-dvb-s2-9985093e2b4f19b1d13d5004346f22540c92cc5d.tar.gz mediapointer-dvb-s2-9985093e2b4f19b1d13d5004346f22540c92cc5d.tar.bz2 |
Fixes some bad global variables
- debug global var is already used inside kernel, so renamed
debug to tuner_debug for the tuner module
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Diffstat (limited to 'linux/drivers/media/video/tuner-core.c')
-rw-r--r-- | linux/drivers/media/video/tuner-core.c | 29 |
1 files changed, 17 insertions, 12 deletions
diff --git a/linux/drivers/media/video/tuner-core.c b/linux/drivers/media/video/tuner-core.c index 0e4e7752a..5b9cb9b7e 100644 --- a/linux/drivers/media/video/tuner-core.c +++ b/linux/drivers/media/video/tuner-core.c @@ -1,5 +1,5 @@ /* - * $Id: tuner-core.c,v 1.97 2006/01/11 19:28:02 mchehab Exp $ + * $Id: tuner-core.c,v 1.98 2006/01/11 21:01:01 hverkuil Exp $ * * i2c tv tuner chip device driver * core core, i.e. kernel interfaces, registering and so on @@ -49,8 +49,8 @@ static unsigned int no_autodetect = 0; static unsigned int show_i2c = 0; /* insmod options used at runtime => read/write */ -static unsigned int tuner_debug = 0; -int debug = 0; +static unsigned int tuner_debug_old = 0; +int tuner_debug = 0; static unsigned int tv_range[2] = { 44, 958 }; static unsigned int radio_range[2] = { 65, 108 }; @@ -59,12 +59,6 @@ static char pal[] = "--"; static char secam[] = "--"; static char ntsc[] = "-"; -module_param(addr, int, 0444); -module_param(no_autodetect, int, 0444); -module_param(show_i2c, int, 0444); -/* Note: tuner_debug is deprecated and will be removed in 2.6.17 */ -module_param(tuner_debug, int, 0444); -module_param(debug, int, 0644); #if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0) MODULE_PARM(pal,"s"); @@ -72,7 +66,18 @@ MODULE_PARM(secam,"s"); MODULE_PARM(ntsc,"s"); MODULE_PARM(tv_range,"2i"); MODULE_PARM(radio_range,"2i"); +MODULE_PARM(no_autodetect, "i"); +MODULE_PARM(tuner_debug, "i"); +MODULE_PARM(tuner_debug_old, "i"); +MODULE_PARM(addr, "i"); +MODULE_PARM(show_i2c, "i"); #else +module_param(addr, int, 0444); +module_param(no_autodetect, int, 0444); +module_param(show_i2c, int, 0444); +/* Note: tuner_debug is deprecated and will be removed in 2.6.17 */ +module_param_named(tuner_debug,tuner_debug_old, int, 0444); +module_param_named(debug,tuner_debug, int, 0644); module_param_string(pal, pal, sizeof(pal), 0644); module_param_string(secam, secam, sizeof(secam), 0644); module_param_string(ntsc, ntsc, sizeof(ntsc), 0644); @@ -455,8 +460,8 @@ static int tuner_attach(struct i2c_adapter *adap, int addr, t->radio_if2 = 10700 * 1000; /* 10.7MHz - FM radio */ t->audmode = V4L2_TUNER_MODE_STEREO; t->mode_mask = T_UNINITIALIZED; - if (tuner_debug) { - debug = tuner_debug; + if (tuner_debug_old) { + tuner_debug = tuner_debug_old; printk(KERN_ERR "tuner: tuner_debug is deprecated and will be removed in 2.6.17.\n"); printk(KERN_ERR "tuner: use the debug option instead.\n"); } @@ -598,7 +603,7 @@ static int tuner_command(struct i2c_client *client, unsigned int cmd, void *arg) { struct tuner *t = i2c_get_clientdata(client); - if (debug>1) + if (tuner_debug>1) v4l_i2c_print_ioctl(&(t->i2c),cmd); switch (cmd) { |