public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
From: e9hack <e9hack@googlemail.com>
To: linux-dvb@linuxtv.org
Subject: Re: [linux-dvb] Oops in tda10023
Date: Fri, 30 May 2008 23:12:23 +0200	[thread overview]
Message-ID: <48406DB7.10109@gmail.com> (raw)
In-Reply-To: <484063E1.9010109@iki.fi>

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@linuxtv.org
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb

  reply	other threads:[~2008-05-30 21:12 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-05-29 16:50 [linux-dvb] Oops in tda10023 Sigmund Augdal
2008-05-29 17:52 ` Antti Palosaari
2008-05-30  9:15   ` Sigmund Augdal
2008-05-30 12:49     ` Antti Palosaari
2008-05-30 13:59   ` e9hack
2008-05-30 14:35     ` Antti Palosaari
2008-05-30 14:52       ` e9hack
2008-05-30 15:25         ` Antti Palosaari
2008-05-30 20:30           ` Antti Palosaari
2008-05-30 21:12             ` e9hack [this message]
2008-05-30 22:24               ` Oliver Endriss

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=48406DB7.10109@gmail.com \
    --to=e9hack@googlemail.com \
    --cc=linux-dvb@linuxtv.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox