From: Takashi Iwai <tiwai@suse.de>
To: Alan Stern <stern@rowland.harvard.edu>
Cc: Joe Perches <joe@perches.com>, Jaroslav Kysela <perex@perex.cz>,
<alsa-devel@alsa-project.org>,
Kernel development list <linux-kernel@vger.kernel.org>
Subject: Re: [alsa-devel] Improving or replacing snd_printk()
Date: Fri, 31 May 2013 17:38:40 +0200 [thread overview]
Message-ID: <s5hk3mf17nj.wl%tiwai@suse.de> (raw)
In-Reply-To: <Pine.LNX.4.44L0.1305311131450.1276-100000@iolanthe.rowland.org>
At Fri, 31 May 2013 11:33:44 -0400 (EDT),
Alan Stern wrote:
>
> On Fri, 31 May 2013, Takashi Iwai wrote:
>
> > > struct snd_card contains pointers to two different devices: dev and
> > > card_dev. Some contexts might want to use one of them for log messages
> > > while other contexts might want to use the other.
> >
> > Yes, there are some corner cases, indeed.
> >
> > Also, another expected problem is that neither card->card_dev nor
> > card->dev are set when snd_card_err() is called. Many drivers set the
> > device pointers at the late stage just before the device
> > registration. So, systematic replacements won't work as expected in
> > many cases. (The same is applied for replacement with dev_*(), too.)
>
> Given that the drivers would have to be edited to fix up the snd_printk
> calls, the device pointer assignments can be moved to an earlier stage
> at the same time. But doing this would require understanding how the
> driver works to some extent; it couldn't be done blindly.
Yep, that's what I meant as "systematic replacements".
Takashi
next prev parent reply other threads:[~2013-05-31 15:38 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-29 19:27 Alan Stern
2013-05-29 19:51 ` Joe Perches
2013-05-30 18:14 ` Alan Stern
2013-05-30 18:49 ` [alsa-devel] " Jaroslav Kysela
2013-05-30 19:43 ` Alan Stern
2013-05-30 20:30 ` Joe Perches
2013-05-31 6:37 ` Takashi Iwai
2013-05-31 7:06 ` Joe Perches
2013-05-31 7:23 ` Takashi Iwai
2013-05-31 7:30 ` Joe Perches
2013-05-31 7:35 ` Takashi Iwai
2013-05-31 7:38 ` Joe Perches
2013-05-31 7:58 ` Takashi Iwai
2013-05-31 14:24 ` Alan Stern
2013-05-31 14:34 ` Takashi Iwai
2013-05-31 15:33 ` Alan Stern
2013-05-31 15:38 ` Takashi Iwai [this message]
2013-05-31 17:06 ` Joe Perches
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=s5hk3mf17nj.wl%tiwai@suse.de \
--to=tiwai@suse.de \
--cc=alsa-devel@alsa-project.org \
--cc=joe@perches.com \
--cc=linux-kernel@vger.kernel.org \
--cc=perex@perex.cz \
--cc=stern@rowland.harvard.edu \
/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
all inboxes | Powered by JetHome®