ChangeSet 1.2231.1.201, 2005/03/28 20:12:13-08:00, [EMAIL PROTECTED]

        [PATCH] dvb: ves1x93: invert_pwm fix
        
        fix unhandled invert_pwm option (needed on dbox2 hardware)
        submitted by Carsten Juttner
        
        Signed-off-by: Johannes Stezenbach <[EMAIL PROTECTED]>
        Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
        Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]>



 ves1x93.c |   12 +++++++++---
 1 files changed, 9 insertions(+), 3 deletions(-)


diff -Nru a/drivers/media/dvb/frontends/ves1x93.c 
b/drivers/media/dvb/frontends/ves1x93.c
--- a/drivers/media/dvb/frontends/ves1x93.c     2005-03-28 21:51:08 -08:00
+++ b/drivers/media/dvb/frontends/ves1x93.c     2005-03-28 21:51:08 -08:00
@@ -175,7 +175,7 @@
 {
        u32 BDR;
        u32 ratio;
-       u8  ADCONF, FCONF, FNR;
+       u8  ADCONF, FCONF, FNR, AGCR;
        u32 BDRI;
        u32 tmp;
        u32 FIN;
@@ -243,10 +243,16 @@
        ves1x93_writereg (state, 0x20, ADCONF);
        ves1x93_writereg (state, 0x21, FCONF);
 
+       AGCR = state->init_1x93_tab[0x05];
+       if (state->config->invert_pwm)
+               AGCR |= 0x20;
+
        if (srate < 6000000)
-               ves1x93_writereg (state, 0x05, state->init_1x93_tab[0x05] | 
0x80);
+               AGCR |= 0x80;
        else
-               ves1x93_writereg (state, 0x05, state->init_1x93_tab[0x05] & 
0x7f);
+               AGCR &= ~0x80;
+
+       ves1x93_writereg (state, 0x05, AGCR);
 
        /* ves1993 hates this, will lose lock */
        if (state->demod_type != DEMOD_VES1993)
-
To unsubscribe from this list: send the line "unsubscribe bk-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to