diff options
author | Hans Verkuil <hverkuil@xs4all.nl> | 2007-10-30 04:50:03 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2008-01-25 16:01:50 -0500 |
commit | e2a1774d9c8b866db65853fd1a17e5f472dd5cf2 (patch) | |
tree | b1269a546476bb6102b0b14c577b31ba5367df19 /drivers/media/video/ivtv/ivtv-routing.c | |
parent | 05e997197e459a03df577ba49c34c1820957ee4a (diff) |
V4L/DVB (6488): ivtv: add ASUS Falcon2 support
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/ivtv/ivtv-routing.c')
-rw-r--r-- | drivers/media/video/ivtv/ivtv-routing.c | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/drivers/media/video/ivtv/ivtv-routing.c b/drivers/media/video/ivtv/ivtv-routing.c index 398bd33033ed..05564919b57f 100644 --- a/drivers/media/video/ivtv/ivtv-routing.c +++ b/drivers/media/video/ivtv/ivtv-routing.c | |||
@@ -25,6 +25,7 @@ | |||
25 | #include "ivtv-routing.h" | 25 | #include "ivtv-routing.h" |
26 | 26 | ||
27 | #include <media/msp3400.h> | 27 | #include <media/msp3400.h> |
28 | #include <media/m52790.h> | ||
28 | #include <media/upd64031a.h> | 29 | #include <media/upd64031a.h> |
29 | #include <media/upd64083.h> | 30 | #include <media/upd64083.h> |
30 | 31 | ||
@@ -32,28 +33,26 @@ | |||
32 | settings. */ | 33 | settings. */ |
33 | void ivtv_audio_set_io(struct ivtv *itv) | 34 | void ivtv_audio_set_io(struct ivtv *itv) |
34 | { | 35 | { |
36 | const struct ivtv_card_audio_input *in; | ||
35 | struct v4l2_routing route; | 37 | struct v4l2_routing route; |
36 | u32 audio_input; | ||
37 | int mux_input; | ||
38 | 38 | ||
39 | /* Determine which input to use */ | 39 | /* Determine which input to use */ |
40 | if (test_bit(IVTV_F_I_RADIO_USER, &itv->i_flags)) { | 40 | if (test_bit(IVTV_F_I_RADIO_USER, &itv->i_flags)) |
41 | audio_input = itv->card->radio_input.audio_input; | 41 | in = &itv->card->radio_input; |
42 | mux_input = itv->card->radio_input.muxer_input; | 42 | else |
43 | } else { | 43 | in = &itv->card->audio_inputs[itv->audio_input]; |
44 | audio_input = itv->card->audio_inputs[itv->audio_input].audio_input; | ||
45 | mux_input = itv->card->audio_inputs[itv->audio_input].muxer_input; | ||
46 | } | ||
47 | 44 | ||
48 | /* handle muxer chips */ | 45 | /* handle muxer chips */ |
49 | route.input = mux_input; | 46 | route.input = in->muxer_input; |
50 | route.output = 0; | 47 | route.output = 0; |
48 | if (itv->card->hw_muxer & IVTV_HW_M52790) | ||
49 | route.output = M52790_OUT_STEREO; | ||
51 | ivtv_i2c_hw(itv, itv->card->hw_muxer, VIDIOC_INT_S_AUDIO_ROUTING, &route); | 50 | ivtv_i2c_hw(itv, itv->card->hw_muxer, VIDIOC_INT_S_AUDIO_ROUTING, &route); |
52 | 51 | ||
53 | route.input = audio_input; | 52 | route.input = in->audio_input; |
54 | if (itv->card->hw_audio & IVTV_HW_MSP34XX) { | 53 | route.output = 0; |
54 | if (itv->card->hw_audio & IVTV_HW_MSP34XX) | ||
55 | route.output = MSP_OUTPUT(MSP_SC_IN_DSP_SCART1); | 55 | route.output = MSP_OUTPUT(MSP_SC_IN_DSP_SCART1); |
56 | } | ||
57 | ivtv_i2c_hw(itv, itv->card->hw_audio, VIDIOC_INT_S_AUDIO_ROUTING, &route); | 56 | ivtv_i2c_hw(itv, itv->card->hw_audio, VIDIOC_INT_S_AUDIO_ROUTING, &route); |
58 | } | 57 | } |
59 | 58 | ||