diff options
author | Mike Isely <isely@pobox.com> | 2006-12-27 20:26:55 -0600 |
---|---|---|
committer | Mike Isely <isely@pobox.com> | 2006-12-27 20:26:55 -0600 |
commit | 99f9ef930137ebd1f212ab52256394694fecfcdc (patch) | |
tree | c44e9b3b14665a58a2fa3d6e2c2ceb9413dd8abc /linux/drivers/media/video/pvrusb2/pvrusb2-wm8775.c | |
parent | c8dd4616f6359cd0f98ea853b654ad4c5eec971b (diff) | |
download | mediapointer-dvb-s2-99f9ef930137ebd1f212ab52256394694fecfcdc.tar.gz mediapointer-dvb-s2-99f9ef930137ebd1f212ab52256394694fecfcdc.tar.bz2 |
pvrusb2: Enable radio mode for 24xxx devices
From: Mike Isely <isely@pobox.com>
These changes implement correct audio routing for radio mode on a
24xxx device.
Signed-off-by: Mike Isely <isely@pobox.com>
Diffstat (limited to 'linux/drivers/media/video/pvrusb2/pvrusb2-wm8775.c')
-rw-r--r-- | linux/drivers/media/video/pvrusb2/pvrusb2-wm8775.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/linux/drivers/media/video/pvrusb2/pvrusb2-wm8775.c b/linux/drivers/media/video/pvrusb2/pvrusb2-wm8775.c index 2413e5198..ce08dee9b 100644 --- a/linux/drivers/media/video/pvrusb2/pvrusb2-wm8775.c +++ b/linux/drivers/media/video/pvrusb2/pvrusb2-wm8775.c @@ -50,15 +50,21 @@ static void set_input(struct pvr2_v4l_wm8775 *ctxt) { struct v4l2_routing route; struct pvr2_hdw *hdw = ctxt->hdw; - int msk = 0; memset(&route,0,sizeof(route)); - pvr2_trace(PVR2_TRACE_CHIPS,"i2c wm8775 set_input(val=%d msk=0x%x)", - hdw->input_val,msk); + switch(hdw->input_val) { + case PVR2_CVAL_INPUT_RADIO: + route.input = 1; + break; + default: + /* All other cases just use the second input */ + route.input = 2; + break; + } + pvr2_trace(PVR2_TRACE_CHIPS,"i2c wm8775 set_input(val=%d route=0x%x)", + hdw->input_val,route.input); - // Always point to input #1 no matter what - route.input = 2; pvr2_i2c_client_cmd(ctxt->client,VIDIOC_INT_S_AUDIO_ROUTING,&route); } |