diff options
-rw-r--r-- | linux/drivers/media/video/cx25840/cx25840-core.c | 61 | ||||
-rw-r--r-- | linux/drivers/media/video/em28xx/em28xx-core.c | 6 | ||||
-rw-r--r-- | linux/drivers/media/video/em28xx/em28xx-i2c.c | 2 | ||||
-rw-r--r-- | linux/drivers/media/video/em28xx/em28xx-video.c | 2 | ||||
-rw-r--r-- | linux/drivers/media/video/em28xx/em28xx.h | 8 | ||||
-rw-r--r-- | linux/drivers/media/video/saa7134/saa7134-alsa.c | 4 | ||||
-rw-r--r-- | v4l/ChangeLog | 26 |
7 files changed, 79 insertions, 30 deletions
diff --git a/linux/drivers/media/video/cx25840/cx25840-core.c b/linux/drivers/media/video/cx25840/cx25840-core.c index cfa9cca9f..df97316cf 100644 --- a/linux/drivers/media/video/cx25840/cx25840-core.c +++ b/linux/drivers/media/video/cx25840/cx25840-core.c @@ -344,25 +344,48 @@ static int set_input(struct i2c_client *client, enum cx25840_input input) static int set_v4lstd(struct i2c_client *client, v4l2_std_id std) { - u8 fmt; - - switch (std) { - /* zero is autodetect */ - case 0: fmt = 0x0; break; - /* default ntsc to ntsc-m */ - case V4L2_STD_NTSC: - case V4L2_STD_NTSC_M: fmt = 0x1; break; - case V4L2_STD_NTSC_M_JP: fmt = 0x2; break; - case V4L2_STD_NTSC_443: fmt = 0x3; break; - case V4L2_STD_PAL: fmt = 0x4; break; - case V4L2_STD_PAL_M: fmt = 0x5; break; - case V4L2_STD_PAL_N: fmt = 0x6; break; - case V4L2_STD_PAL_Nc: fmt = 0x7; break; - case V4L2_STD_PAL_60: fmt = 0x8; break; - case V4L2_STD_SECAM: fmt = 0xc; break; - default: - return -ERANGE; - } + u8 fmt=0; /* zero is autodetect */ + + do { + /* First tests should be against specific std */ + if (std & V4L2_STD_NTSC_M_JP) { + fmt=0x2; + break; + } + if (std & V4L2_STD_NTSC_M_443) { + fmt=0x3; + break; + } + if (std & V4L2_STD_PAL_M) { + fmt=0x5; + break; + } + if (std & V4L2_STD_PAL_N) { + fmt=0x6; + break; + } + if (std & V4L2_STD_PAL_Nc) { + fmt=0x7; + break; + } + if (std & V4L2_STD_PAL_60) { + fmt=0x8; + break; + } + /* Then, test against generic ones */ + if (std & V4L2_STD_NTSC) { + fmt=0x1; + break; + } + if (std & V4L2_STD_PAL) { + fmt=0x4; + break; + } + if (std & V4L2_STD_SECAM) { + fmt=0xc; + break; + } + } while (0); cx25840_and_or(client, 0x400, ~0xf, fmt); cx25840_vbi_setup(client); diff --git a/linux/drivers/media/video/em28xx/em28xx-core.c b/linux/drivers/media/video/em28xx/em28xx-core.c index e2e6426eb..ffd173e7c 100644 --- a/linux/drivers/media/video/em28xx/em28xx-core.c +++ b/linux/drivers/media/video/em28xx/em28xx-core.c @@ -39,7 +39,7 @@ MODULE_PARM_DESC(core_debug,"enable debug messages [core]"); #define em28xx_coredbg(fmt, arg...) do {\ if (core_debug) \ printk(KERN_INFO "%s %s :"fmt, \ - dev->name, __FUNCTION__, ##arg); } while (0) + dev->name, __FUNCTION__ , ##arg); } while (0) static unsigned int reg_debug = 0; module_param(reg_debug,int,0644); @@ -48,7 +48,7 @@ MODULE_PARM_DESC(reg_debug,"enable debug messages [URB reg]"); #define em28xx_regdbg(fmt, arg...) do {\ if (reg_debug) \ printk(KERN_INFO "%s %s :"fmt, \ - dev->name, __FUNCTION__, ##arg); } while (0) + dev->name, __FUNCTION__ , ##arg); } while (0) static unsigned int isoc_debug = 0; module_param(isoc_debug,int,0644); @@ -57,7 +57,7 @@ MODULE_PARM_DESC(isoc_debug,"enable debug messages [isoc transfers]"); #define em28xx_isocdbg(fmt, arg...) do {\ if (isoc_debug) \ printk(KERN_INFO "%s %s :"fmt, \ - dev->name, __FUNCTION__, ##arg); } while (0) + dev->name, __FUNCTION__ , ##arg); } while (0) static int alt = EM28XX_PINOUT; module_param(alt, int, 0644); diff --git a/linux/drivers/media/video/em28xx/em28xx-i2c.c b/linux/drivers/media/video/em28xx/em28xx-i2c.c index 29e21ad18..7f5603054 100644 --- a/linux/drivers/media/video/em28xx/em28xx-i2c.c +++ b/linux/drivers/media/video/em28xx/em28xx-i2c.c @@ -44,7 +44,7 @@ MODULE_PARM_DESC(i2c_debug, "enable debug messages [i2c]"); printk(fmt, ##args); } while (0) #define dprintk2(lvl,fmt, args...) if (i2c_debug>=lvl) do{ \ printk(KERN_DEBUG "%s at %s: " fmt, \ - dev->name, __FUNCTION__, ##args); } while (0) + dev->name, __FUNCTION__ , ##args); } while (0) /* * em2800_i2c_send_max4() diff --git a/linux/drivers/media/video/em28xx/em28xx-video.c b/linux/drivers/media/video/em28xx/em28xx-video.c index 3194f64c0..a1c85ce03 100644 --- a/linux/drivers/media/video/em28xx/em28xx-video.c +++ b/linux/drivers/media/video/em28xx/em28xx-video.c @@ -50,7 +50,7 @@ #define em28xx_videodbg(fmt, arg...) do {\ if (video_debug) \ printk(KERN_INFO "%s %s :"fmt, \ - dev->name, __FUNCTION__, ##arg); } while (0) + dev->name, __FUNCTION__ , ##arg); } while (0) MODULE_AUTHOR(DRIVER_AUTHOR); MODULE_DESCRIPTION(DRIVER_DESC); diff --git a/linux/drivers/media/video/em28xx/em28xx.h b/linux/drivers/media/video/em28xx/em28xx.h index d6bbfb11f..ef332d3e6 100644 --- a/linux/drivers/media/video/em28xx/em28xx.h +++ b/linux/drivers/media/video/em28xx/em28xx.h @@ -393,18 +393,18 @@ extern const unsigned int em28xx_bcount; /* printk macros */ #define em28xx_err(fmt, arg...) do {\ - printk(KERN_ERR fmt, ##arg); } while (0) + printk(KERN_ERR fmt , ##arg); } while (0) #define em28xx_errdev(fmt, arg...) do {\ printk(KERN_ERR "%s: "fmt,\ - dev->name, ##arg); } while (0) + dev->name , ##arg); } while (0) #define em28xx_info(fmt, arg...) do {\ printk(KERN_INFO "%s: "fmt,\ - dev->name, ##arg); } while (0) + dev->name , ##arg); } while (0) #define em28xx_warn(fmt, arg...) do {\ printk(KERN_WARNING "%s: "fmt,\ - dev->name, ##arg); } while (0) + dev->name , ##arg); } while (0) inline static int em28xx_audio_source(struct em28xx *dev, int input) { diff --git a/linux/drivers/media/video/saa7134/saa7134-alsa.c b/linux/drivers/media/video/saa7134/saa7134-alsa.c index 701746930..b24e5de75 100644 --- a/linux/drivers/media/video/saa7134/saa7134-alsa.c +++ b/linux/drivers/media/video/saa7134/saa7134-alsa.c @@ -1,7 +1,7 @@ /* * SAA713x ALSA support for V4L * - * $Id: saa7134-alsa.c,v 1.28 2005/11/20 15:50:31 mchehab Exp $ + * $Id: saa7134-alsa.c,v 1.29 2005/12/17 21:39:18 mchehab Exp $ * * Caveats: * - Volume doesn't work (it's always at max) @@ -68,7 +68,7 @@ module_param_array(index, int, NULL, 0444); MODULE_PARM_DESC(index, "Index value for SAA7134 capture interface(s)."); #define dprintk(fmt, arg...) if (debug) \ - printk(KERN_DEBUG "%s/alsa: " fmt, dev->name, ## arg) + printk(KERN_DEBUG "%s/alsa: " fmt, dev->name , ##arg) diff --git a/v4l/ChangeLog b/v4l/ChangeLog index b47111ab6..4b2eed21d 100644 --- a/v4l/ChangeLog +++ b/v4l/ChangeLog @@ -1,3 +1,29 @@ +2005-12-17 21:27 mchehab + + * linux/drivers/media/video/cx25840/cx25840-core.c: (set_v4lstd): + - Fix compilation failure with gcc 2.95.3. + - Corrected a bug at video std check + + Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br> + +2005-12-17 21:27 mchehab + + * linux/drivers/media/video/em28xx/em28xx-core.c: + * linux/drivers/media/video/em28xx/em28xx-i2c.c: + * linux/drivers/media/video/em28xx/em28xx-video.c: + * linux/drivers/media/video/em28xx/em28xx.h: + * linux/drivers/media/video/saa7134/saa7134-alsa.c: + - Fix compilation failure with gcc 2.95.3. + + Signed-off-by: Jean Delvare <khali@linux-fr.org> + Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br> + +2005-12-17 21:16 mchehab + + * linux/drivers/media/video/cx25840/cx25840-core.c: (set_v4lstd): + + Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br> + 2005-12-17 20:25 mkrufky * v4l/Makefile: |