diff options
author | Trent Piepho <xyzzy@speakeasy.org> | 2009-01-28 19:32:59 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-03-30 11:42:47 -0400 |
commit | 430390e67b39ccf56d98286f5e5a72d903c9cf87 (patch) | |
tree | 197f886bbc3927857d4d10daa3f61fbb720b57f1 /drivers/media/video/bt8xx | |
parent | 13afaefc0392d377d23ce5b7e1f4f3944a00e1f1 (diff) |
V4L/DVB (10566): bttv: clean up mux code for IDS Eagle
This card apparently uses an external mux and the Bt878's mux should always
be set to MUX2. The values for the external mux control bits were stored
in the muxsel field. This meant that when changing inputs the driver would
switch the Bt878's mux to whatever value the external mux was supposed to
be set to, then eagle_muxsel() would switch it back to MUX2 and program the
external mux. This creates an unnecessary switch of the Bt878's mux.
So change muxsel to be 2 for each input. The external mux bits are just
"input&3" so they don't really need to be stored anywhere. This also
eliminates the last non-standard use of the muxsel data.
Cc: M G Berberich <berberic@fmi.uni-passau.de>
Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/bt8xx')
-rw-r--r-- | drivers/media/video/bt8xx/bttv-cards.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/media/video/bt8xx/bttv-cards.c b/drivers/media/video/bt8xx/bttv-cards.c index df4d7752eb77..fc2b796b25fc 100644 --- a/drivers/media/video/bt8xx/bttv-cards.c +++ b/drivers/media/video/bt8xx/bttv-cards.c | |||
@@ -1799,7 +1799,7 @@ struct tvcard bttv_tvcards[] = { | |||
1799 | .tuner_addr = ADDR_UNSET, | 1799 | .tuner_addr = ADDR_UNSET, |
1800 | .svhs = NO_SVHS, | 1800 | .svhs = NO_SVHS, |
1801 | .gpiomask = 0, | 1801 | .gpiomask = 0, |
1802 | .muxsel = { 0, 1, 2, 3 }, | 1802 | .muxsel = { 2, 2, 2, 2 }, |
1803 | .muxsel_hook = eagle_muxsel, | 1803 | .muxsel_hook = eagle_muxsel, |
1804 | .no_msp34xx = 1, | 1804 | .no_msp34xx = 1, |
1805 | .no_tda9875 = 1, | 1805 | .no_tda9875 = 1, |
@@ -3109,8 +3109,7 @@ static void init_ids_eagle(struct bttv *btv) | |||
3109 | * has its own multiplexer */ | 3109 | * has its own multiplexer */ |
3110 | static void eagle_muxsel(struct bttv *btv, unsigned int input) | 3110 | static void eagle_muxsel(struct bttv *btv, unsigned int input) |
3111 | { | 3111 | { |
3112 | btaor((2)<<5, ~(3<<5), BT848_IFORM); | 3112 | gpio_bits(3, input & 3); |
3113 | gpio_bits(3,bttv_tvcards[btv->c.type].muxsel[input&7]); | ||
3114 | 3113 | ||
3115 | /* composite */ | 3114 | /* composite */ |
3116 | /* set chroma ADC to sleep */ | 3115 | /* set chroma ADC to sleep */ |