From: Lars-Peter Clausen <lars@metafoo.de>
To: Mark Brown <broonie@kernel.org>, "Pan, Harry" <harry.pan@intel.com>
Cc: "lgirdwood@gmail.com" <lgirdwood@gmail.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"gs0622@gmail.com" <gs0622@gmail.com>,
"alsa-devel@alsa-project.org" <alsa-devel@alsa-project.org>,
"tiwai@suse.com" <tiwai@suse.com>,
"perex@perex.cz" <perex@perex.cz>
Subject: Re: [PATCH] ASoC: dapm: Do not traverse widget hooks to snd-soc-dummy
Date: Thu, 17 Mar 2016 13:37:16 +0100 [thread overview]
Message-ID: <56EAA4FC.5090408@metafoo.de> (raw)
In-Reply-To: <20160317112514.GE2566@sirena.org.uk>
[-- Attachment #1: Type: text/plain, Size: 1349 bytes --]
On 03/17/2016 12:25 PM, Mark Brown wrote:
> On Thu, Mar 17, 2016 at 10:38:36AM +0000, Pan, Harry wrote:
>
>> Allow me to explain more detail that I saw during debug; since the
>> commit 6e78108bda78 (ASoC: core: Don't probe the component which is
>> dummy), an exception has been made that dummy component won't be probed,
>> thus the 'card' passed into soc_probe_component() would not be assigned
>> to this component. In the other hand, the component struct is initially
>> created in snd_soc_register_platform() by kzalloc() of platform struct,
>> its 'card' pointer is remaining an NULL pointer even the widget node
>> being read.
>
>> Perhaps another option is to refine soc_probe_component(), which I have
>> not dive in.
>
> Another approach might be to create a separate dummy component for each
> card rather than trying to reuse the same one for all of them (which was
> what the commit you mention was doing) - that way we don't need to worry
> about it getting added to multiple cards which was the original problem
> that was being looked at here.
I'd say as a quick fix for stable check that card is not NULL in
dapm_widget_show_component(). And as a longterm fix get rid of dapm_widget
file. Nobody should hopefully use it anymore with debugfs being available as
the far better alternative.
- Lars
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
next prev parent reply other threads:[~2016-03-17 12:37 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-16 11:17 [PATCH] ASoC: dapm: Do not traverse widget hooks to snd-soc-dummy Harry Pan
2016-03-17 9:54 ` Mark Brown
2016-03-17 10:38 ` Pan, Harry
2016-03-17 11:25 ` Mark Brown
2016-03-17 12:37 ` Lars-Peter Clausen [this message]
2016-03-17 13:04 ` Pan, Harry
2016-03-17 15:42 ` Mark Brown
2016-03-18 5:17 ` [alsa-devel] " Vinod Koul
-- strict thread matches above, loose matches on Subject: below --
2016-03-16 10:43 Harry Pan
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=56EAA4FC.5090408@metafoo.de \
--to=lars@metafoo.de \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=gs0622@gmail.com \
--cc=harry.pan@intel.com \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=perex@perex.cz \
--cc=tiwai@suse.com \
/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