Re: Oops in tda10023

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

 



Antti Palosaari schrieb:
> Anyhow, I see there is two ways to fix that (only Oops from TDA10023, 
> not issue why it actually fails):
> 1) remove state->frontend.dvb->num from tda10023_writereg()
> 2) remove wakeup if in standby from tda10023_attach()

I wouldn't prefer #1, because it is very useful to know the adapter number, if one card 
sucks and it exist another one. Usually, it isn't necessary to wakeup the tda10023 for 
reading the id. A third option is the following patch:

diff -r 398b07fdfe79 linux/drivers/media/dvb/frontends/tda10023.c
--- a/linux/drivers/media/dvb/frontends/tda10023.c      Wed May 28 17:55:13 2008 -0300
+++ b/linux/drivers/media/dvb/frontends/tda10023.c      Fri May 30 23:02:55 2008 +0200
@@ -90,7 +90,7 @@ static int tda10023_writereg (struct tda
         if (ret != 1)
                 printk("DVB: TDA10023(%d): %s, writereg error "
                         "(reg == 0x%02x, val == 0x%02x, ret == %i)\n",
-                       state->frontend.dvb->num, __func__, reg, data, ret);
+                       state->frontend.dvb ? state->frontend.dvb->num : '?', __func__, 
reg, data, ret);

         return (ret != 1) ? -EREMOTEIO : 0;
  }
@@ -481,7 +481,7 @@ struct dvb_frontend *tda10023_attach(con
         struct tda10023_state* state = NULL;

         /* allocate memory for the internal state */
-       state = kmalloc(sizeof(struct tda10023_state), GFP_KERNEL);
+       state = kzalloc(sizeof(struct tda10023_state), GFP_KERNEL);
         if (state == NULL) goto error;

         /* setup the state */

-Hartmut

_______________________________________________
linux-dvb mailing list
linux-dvb@xxxxxxxxxxx
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb

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

  Powered by Linux