diff options
author | Gerd Knorr <devnull@localhost> | 2004-08-26 10:59:39 +0000 |
---|---|---|
committer | Gerd Knorr <devnull@localhost> | 2004-08-26 10:59:39 +0000 |
commit | 84745973eae0afde332edbcc1a977612529b5415 (patch) | |
tree | 0dce8107c5ec9b0f5b479f40267c840927926e85 /linux/drivers/media/video/cx88/cx88-video.c | |
parent | bfe098ac63bdc53956e17b005d94470e65affcc3 (diff) | |
download | mediapointer-dvb-s2-84745973eae0afde332edbcc1a977612529b5415.tar.gz mediapointer-dvb-s2-84745973eae0afde332edbcc1a977612529b5415.tar.bz2 |
- cx88: Dvico FusionHDTV patches by Mac Michaels
Diffstat (limited to 'linux/drivers/media/video/cx88/cx88-video.c')
-rw-r--r-- | linux/drivers/media/video/cx88/cx88-video.c | 40 |
1 files changed, 37 insertions, 3 deletions
diff --git a/linux/drivers/media/video/cx88/cx88-video.c b/linux/drivers/media/video/cx88/cx88-video.c index 31df4ae75..8d2de17a1 100644 --- a/linux/drivers/media/video/cx88/cx88-video.c +++ b/linux/drivers/media/video/cx88/cx88-video.c @@ -1,5 +1,5 @@ /* - * $Id: cx88-video.c,v 1.32 2004/08/25 14:47:53 kraxel Exp $ + * $Id: cx88-video.c,v 1.33 2004/08/26 10:59:39 kraxel Exp $ * * device driver for Conexant 2388x based TV cards * video4linux video interface @@ -1356,6 +1356,7 @@ static int video_do_ioctl(struct inode *inode, struct file *file, [ CX88_VMUX_COMPOSITE4 ] = "Composite4", [ CX88_VMUX_SVIDEO ] = "S-Video", [ CX88_VMUX_TELEVISION ] = "Television", + [ CX88_VMUX_CABLE ] = "Cable TV", [ CX88_VMUX_DVB ] = "DVB", [ CX88_VMUX_DEBUG ] = "for debug only", }; @@ -1371,7 +1372,8 @@ static int video_do_ioctl(struct inode *inode, struct file *file, i->index = n; i->type = V4L2_INPUT_TYPE_CAMERA; strcpy(i->name,iname[INPUT(n)->type]); - if (CX88_VMUX_TELEVISION == INPUT(n)->type) + if ((CX88_VMUX_TELEVISION == INPUT(n)->type) || + (CX88_VMUX_CABLE == INPUT(n)->type)) i->type = V4L2_INPUT_TYPE_TUNER; for (n = 0; n < ARRAY_SIZE(tvnorms); n++) i->std |= tvnorms[n].id; @@ -1396,6 +1398,38 @@ static int video_do_ioctl(struct inode *inode, struct file *file, return 0; } + +#if 0 + /* needs review */ + case VIDIOC_G_AUDIO: + { + struct v4l2_audio *a = arg; + unsigned int n = a->index; + + memset(a,0,sizeof(*a)); + a->index = n; + switch (n) { + case 0: + if ((CX88_VMUX_TELEVISION == INPUT(n)->type) + || (CX88_VMUX_CABLE == INPUT(n)->type)) { + strcpy(a->name,"Television"); + // FIXME figure out if stereo received and set V4L2_AUDCAP_STEREO. + return 0; + } + break; + case 1: + if (CX88_BOARD_DVICO_FUSIONHDTV_3_GOLD == core->board) { + strcpy(a->name,"Line In"); + a->capability = V4L2_AUDCAP_STEREO; + return 0; + } + break; + } + // Audio input not available. + return -EINVAL; + } +#endif + /* --- capture ioctls ---------------------------------------- */ case VIDIOC_ENUM_FMT: { @@ -1642,7 +1676,7 @@ static int radio_do_ioctl(struct inode *inode, struct file *file, { struct video_tuner vt; memset(&vt,0,sizeof(vt)); - cx8800_call_i2c_clients(dev,VIDIOCGTUNER,&vt); + cx88_call_i2c_clients(dev,VIDIOCGTUNER,&vt); t->signal = vt.signal; } #endif |