aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/dvb/frontends/s5h1409.c
diff options
context:
space:
mode:
authorDevin Heitmueller <dheitmueller@kernellabs.com>2009-10-27 22:33:21 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-12-05 15:41:22 -0500
commitaf5c8e1523edf792f57ec938aef9423783af25e1 (patch)
tree7201a2e68340906dc2dc0dbe963332fbeac5eaf0 /drivers/media/dvb/frontends/s5h1409.c
parentf57b17c3956f2e1e70f63dd2ed8088b582f3915e (diff)
V4L/DVB (13329): s5h1409: provide HVR-1600 specific optimizations
Perform some optimization of the register configuration based on a trace of the HVR-1600 Windows i2c traffic (and consultation with Steven Toth). Note that some of these values may be able to be moved into the common driver, but I am holding off on that until they can be tested with other boards. This work was sponsored by ONELAN Limited. Cc: Steven Toth <stoth@kernellabs.com> Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/dvb/frontends/s5h1409.c')
-rw-r--r--drivers/media/dvb/frontends/s5h1409.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/drivers/media/dvb/frontends/s5h1409.c b/drivers/media/dvb/frontends/s5h1409.c
index fb3011518427..85fba581c5ab 100644
--- a/drivers/media/dvb/frontends/s5h1409.c
+++ b/drivers/media/dvb/frontends/s5h1409.c
@@ -614,6 +614,21 @@ static int s5h1409_init(struct dvb_frontend *fe)
614 /* The datasheet says that after initialisation, VSB is default */ 614 /* The datasheet says that after initialisation, VSB is default */
615 state->current_modulation = VSB_8; 615 state->current_modulation = VSB_8;
616 616
617 /* Optimize for the HVR-1600 if appropriate. Note that some of these
618 may get folded into the generic case after testing with other
619 devices */
620 if (state->config->hvr1600_opt == S5H1409_HVR1600_OPTIMIZE) {
621 /* VSB AGC REF */
622 s5h1409_writereg(state, 0x09, 0x0050);
623
624 /* Unknown but Windows driver does it... */
625 s5h1409_writereg(state, 0x21, 0x0001);
626 s5h1409_writereg(state, 0x50, 0x030e);
627
628 /* QAM AGC REF */
629 s5h1409_writereg(state, 0x82, 0x0800);
630 }
631
617 if (state->config->output_mode == S5H1409_SERIAL_OUTPUT) 632 if (state->config->output_mode == S5H1409_SERIAL_OUTPUT)
618 s5h1409_writereg(state, 0xab, 633 s5h1409_writereg(state, 0xab,
619 s5h1409_readreg(state, 0xab) | 0x100); /* Serial */ 634 s5h1409_readreg(state, 0xab) | 0x100); /* Serial */