[linux-dvb] Re: nxt200x: Error reading multireg register

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Kirk Lapray wrote:

> That's what I am thinking.  It looks like those registers are trying 
> to be read before the card has locked onto the signal.  I only get 
> these errors if I tune to channel that doesn't have a digital signal.  
> I wonder if the tuner in the HDTV Wonder is able to lock on faster 
> than the one in the A180.  Since you get these errors when there is 
> not a signal, and it doesn't mean anything is wrong, we should 
> probably ignore it.
>
> After looking over the nxt2002_readreg_multibyte code again it looks 
> like it never even checks for errors.  We might just want to do the 
> same and remove

Can you just send me a patch? (with your sign-off and short 
description)  It's a lot easier for me to see what you're changing that 
way, and also a much better (and safer) way to apply the change to cvs.

Thanks,

-Mike

>
> In nxt200x_readreg_multibyte change it from:
>
>                 case NXT2004:
>                         /* probably not right, but gives correct values */
>                         attr = 0x02;
>                         if (reg & 0x80) {
>                                 attr = attr << 1;
>                                 if (reg & 0x04)
>                                         attr = attr >> 1;
>                         }
>
>                         /* set multi register length */
>                         len2 = (attr << 4) | len;
>                         nxt200x_writebytes(state, 0x34, &len2, 1);
>
>                         /* toggle the multireg bit*/
>                         buf = 0x80;
>                         nxt200x_writebytes(state, 0x21, &buf, 1);
>
>                       /* read status */
>                       nxt200x_readbytes(state, 0x21, &buf, 1);
>
>                       if (buf == 0)
>                       {
>                                 /* read the actual data */
>                                 for(i = 0; i < len; i++) {
>                                         nxt200x_readbytes(state, 0x36 
> + i, &data[i], 1);
>                                 }
>                                 return 0;
>                       }
>                       break;
>                 default:
>                         return -EINVAL;
>                         break;
>         }
>
>       printk(KERN_WARNING "nxt200x: Error reading multireg register 
> 0x%02X BUFFER=0x%02X\n",reg,buf);
>
>       return 0;
>
> To:
>
>                 case NXT2004:
>                         /* probably not right, but gives correct values */
>                         attr = 0x02;
>                         if (reg & 0x80) {
>                                 attr = attr << 1;
>                                 if (reg & 0x04)
>                                         attr = attr >> 1;
>                         }
>
>                         /* set multi register length */
>                         len2 = (attr << 4) | len;
>                         nxt200x_writebytes(state, 0x34, &len2, 1);
>
>                         /* toggle the multireg bit*/
>                         buf = 0x80;
>                         nxt200x_writebytes(state, 0x21, &buf, 1);
>
>                         /* read the actual data */
>                         for(i = 0; i < len; i++) {
>                                 nxt200x_readbytes(state, 0x36 + i, 
> &data[i], 1);
>                         }
>                         return 0;
>                         break;
>                 default:
>                         return -EINVAL;
>                         break;
>         }
>
>
> Kirk
>
> On 10/27/05, *Michael Krufky* <mkrufky@xxxxxxx 
> <mailto:mkrufky@xxxxxxx>> wrote:
>
>     Kirk Lapray wrote:
>
>     > On 10/27/05, *Michael Krufky* <mkrufky@xxxxxxx
>     <mailto:mkrufky@xxxxxxx>
>     > <mailto:mkrufky@xxxxxxx <mailto:mkrufky@xxxxxxx>>> wrote:
>     >
>     >     Although everything is working well, I am still getting
>     these errors
>     >     when I first run azap:
>     >
>     >     nxt200x: NXT2004 Detected
>     >     DVB: registering new adapter (saa7133[0]).
>     >     DVB: registering frontend 0 (Nextwave NXT200X VSB/QAM
>     frontend)...
>     >     nxt2004: Waiting for firmware upload ( dvb-fe-nxt2004.fw)...
>     >     nxt2004: Waiting for firmware upload(2)...
>     >     nxt2004: Firmware upload complete
>     >     nxt200x: Error reading multireg register 0xA6
>     >     nxt200x: Error reading multireg register 0xE6
>     >     nxt200x: Error reading multireg register 0xE6
>     >
>     >     Never more than 3 lines in the log... It is tuning and
>     delivering
>     >     my ts
>     >     stream just fine.
>     >
>     > I know the nxt2002 driver used dprintk instead of printk in the
>     > multireg read and write commands.  We could switch it to dprintk and
>     > then you would only see these errors if you loaded the driver with
>     > debug set.
>
>     Kirk -
>
>     So... I guess that translates to "those errors don't matter."  Would
>     that be the correct assessment?
>
>     I'm not worried about whether I am *seeing* them or not... I was only
>     concerned about whether it was indicating something worth paying
>     attention to.
>
>     -Mike
>
>



[Index of Archives]     [Linux Media]     [Video 4 Linux]     [Asterisk]     [Samba]     [Xorg]     [Xfree86]     [Linux USB]

  Powered by Linux