diff options
author | Mike Isely <devnull@localhost> | 2006-01-14 22:09:52 +0000 |
---|---|---|
committer | Mike Isely <devnull@localhost> | 2006-01-14 22:09:52 +0000 |
commit | 53e2a0e11ea790e0466ae6358e2f293584155611 (patch) | |
tree | 12b2535d1e23088e324f98e9bf7f59f8b380caf1 /v4l_experimental | |
parent | 1fe396338f08245ff63b2435a4e70cf176f14347 (diff) | |
download | mediapointer-dvb-s2-53e2a0e11ea790e0466ae6358e2f293584155611.tar.gz mediapointer-dvb-s2-53e2a0e11ea790e0466ae6358e2f293584155611.tar.bz2 |
Change global "debug" to "pvrusb2_debug"
Note - I think this is the only actual global variable in the entire
driver right now. (Other stuff is either static or held through a
context pointer).
From: Mike Isely <isely@pobox.com>
Signed-off-by: Mike Isely <isely@pobox.com>
Diffstat (limited to 'v4l_experimental')
-rw-r--r-- | v4l_experimental/pvrusb2/pvrusb2-debug.h | 6 | ||||
-rw-r--r-- | v4l_experimental/pvrusb2/pvrusb2-i2c-core.c | 6 | ||||
-rw-r--r-- | v4l_experimental/pvrusb2/pvrusb2-main.c | 9 | ||||
-rw-r--r-- | v4l_experimental/pvrusb2/pvrusb2-v4l2.c | 8 |
4 files changed, 15 insertions, 14 deletions
diff --git a/v4l_experimental/pvrusb2/pvrusb2-debug.h b/v4l_experimental/pvrusb2/pvrusb2-debug.h index b0616e6f4..70a143736 100644 --- a/v4l_experimental/pvrusb2/pvrusb2-debug.h +++ b/v4l_experimental/pvrusb2/pvrusb2-debug.h @@ -1,5 +1,5 @@ /* - * $Id: pvrusb2-debug.h,v 1.4 2006/01/09 06:54:46 mcisely Exp $ + * $Id: pvrusb2-debug.h,v 1.5 2006/01/14 22:09:52 mcisely Exp $ * * Copyright (C) 2005 Mike Isely <isely@pobox.com> * @@ -20,9 +20,9 @@ #ifndef __PVRUSB2_DEBUG_H #define __PVRUSB2_DEBUG_H -extern int debug; +extern int pvrusb2_debug; -#define pvr2_trace(msk, fmt, arg...) do {if(msk & debug) printk(KERN_INFO "pvrusb2 " fmt "\n", ##arg); } while (0) +#define pvr2_trace(msk, fmt, arg...) do {if(msk & pvrusb2_debug) printk(KERN_INFO "pvrusb2 " fmt "\n", ##arg); } while (0) /* These are listed in *rough* order of decreasing usefulness and increasing noise level. */ diff --git a/v4l_experimental/pvrusb2/pvrusb2-i2c-core.c b/v4l_experimental/pvrusb2/pvrusb2-i2c-core.c index 8f562fab7..869e40519 100644 --- a/v4l_experimental/pvrusb2/pvrusb2-i2c-core.c +++ b/v4l_experimental/pvrusb2/pvrusb2-i2c-core.c @@ -1,6 +1,6 @@ /* * - * $Id: pvrusb2-i2c-core.c,v 1.2 2006/01/03 05:48:29 mcisely Exp $ + * $Id: pvrusb2-i2c-core.c,v 1.3 2006/01/14 22:09:52 mcisely Exp $ * * Copyright (C) 2005 Mike Isely <isely@pobox.com> * @@ -254,7 +254,7 @@ static int pvr2_i2c_xfer(struct i2c_adapter *i2c_adap, } done: - if (debug & PVR2_TRACE_I2C_TRAF) { + if (pvrusb2_debug & PVR2_TRACE_I2C_TRAF) { unsigned int idx; for (idx = 0; idx < num; idx++) { printk(KERN_INFO @@ -307,7 +307,7 @@ static int pvr2_i2c_core_singleton(struct i2c_client *cp, int pvr2_i2c_client_cmd(struct pvr2_i2c_client *cp,unsigned int cmd,void *arg) { - if (debug & PVR2_TRACE_I2C_CMD) { + if (pvrusb2_debug & PVR2_TRACE_I2C_CMD) { char buf[100]; unsigned int cnt; cnt = pvr2_i2c_client_describe(cp,PVR2_I2C_DETAIL_DEBUG, diff --git a/v4l_experimental/pvrusb2/pvrusb2-main.c b/v4l_experimental/pvrusb2/pvrusb2-main.c index 0c856207b..6e026a1c6 100644 --- a/v4l_experimental/pvrusb2/pvrusb2-main.c +++ b/v4l_experimental/pvrusb2/pvrusb2-main.c @@ -1,6 +1,6 @@ /* * - * $Id: pvrusb2-main.c,v 1.5 2006/01/14 19:09:50 mcisely Exp $ + * $Id: pvrusb2-main.c,v 1.6 2006/01/14 22:09:52 mcisely Exp $ * * Copyright (C) 2005 Mike Isely <isely@pobox.com> * Copyright (C) 2004 Aurelien Alleaume <slts@free.fr> @@ -55,9 +55,9 @@ PVR2_TRACE_DEBUGIFC | \ 0) -int debug = DEFAULT_DEBUG_MASK; +int pvrusb2_debug = DEFAULT_DEBUG_MASK; -module_param(debug,int,S_IRUGO|S_IWUSR); +module_param_named(debug,pvrusb2_debug,int,S_IRUGO|S_IWUSR); MODULE_PARM_DESC(debug, "Debug trace mask"); static struct pvr2_sysfs_class *class_ptr = 0; @@ -145,7 +145,8 @@ static int __init pvr_init(void) if (ret == 0) info(DRIVER_DESC " : " DRIVER_VERSION); - if (debug) info("Debug mask is %d (0x%x)",debug,debug); + if (pvrusb2_debug) info("Debug mask is %d (0x%x)", + pvrusb2_debug,pvrusb2_debug); return ret; } diff --git a/v4l_experimental/pvrusb2/pvrusb2-v4l2.c b/v4l_experimental/pvrusb2/pvrusb2-v4l2.c index d963d99ba..be5c84ae0 100644 --- a/v4l_experimental/pvrusb2/pvrusb2-v4l2.c +++ b/v4l_experimental/pvrusb2/pvrusb2-v4l2.c @@ -1,6 +1,6 @@ /* * - * $Id: pvrusb2-v4l2.c,v 1.6 2006/01/14 21:11:17 mcisely Exp $ + * $Id: pvrusb2-v4l2.c,v 1.7 2006/01/14 22:09:52 mcisely Exp $ * * Copyright (C) 2005 Mike Isely <isely@pobox.com> * Copyright (C) 2004 Aurelien Alleaume <slts@free.fr> @@ -351,7 +351,7 @@ static int pvr2_v4l2_do_ioctl(struct inode *inode, struct file *file, struct pvr2_hdw *hdw = fh->channel.mc_head->hdw; int ret = -EINVAL; - if (debug & PVR2_TRACE_V4LIOCTL) { + if (pvrusb2_debug & PVR2_TRACE_V4LIOCTL) { v4l_print_ioctl(pvr2_hdw_get_driver_name(hdw),cmd); } @@ -848,11 +848,11 @@ static int pvr2_v4l2_do_ioctl(struct inode *inode, struct file *file, pvr2_hdw_commit_ctl(hdw); if (ret < 0) { - if (debug & PVR2_TRACE_V4LIOCTL) { + if (pvrusb2_debug & PVR2_TRACE_V4LIOCTL) { pvr2_trace(PVR2_TRACE_ERROR_LEGS, "pvr2_v4l2_do_ioctl failure, ret=%d",ret); } else { - if (debug & PVR2_TRACE_ERROR_LEGS) { + if (pvrusb2_debug & PVR2_TRACE_ERROR_LEGS) { pvr2_trace(PVR2_TRACE_ERROR_LEGS, "pvr2_v4l2_do_ioctl failure, ret=%d" " command was:",ret); |