[alsa-devel] [PATCH v3] sound/soc/lapis: add platform driver for ML7213

Tomoya MORINAGA tomoya.rohm at gmail.com
Thu Mar 8 03:06:47 CET 2012


On Wed, Mar 7, 2012 at 8:46 PM, Mark Brown
<broonie at opensource.wolfsonmicro.com> wrote:
>> >> if these platform devices aren't used, device detection doesn't work correctly.
>> >> So, I added these.
>> > You've not actually mentioned the problem you were seeing...
>> I saw mapping problem between machine driver and platform driver.
>> e.g.  cpu_dai_name "ml7213ioh"
> You've still not explained the problem you're seeing but this sounds
> like something that should work.  Please address the

* Faced problem if there are no platform settings.
machine driver's hw_params is not called
platform_driver's functions(snd_pcm_ops, snd_soc_platform_driver) are
not called.

As a result, the following message is not showed . (by soc_pcm.c)
printk(KERN_INFO "asoc: %s <-> %s mapping ok\n", codec_dai->name,
         cpu_dai->name);

>> > Apart from anything else you've got the interrupt requested as
>> > IRQF_SHARED so the interrupt could get called at any time.  It's also
>> > not clear that you've got the hardware in a known good state.
>> Do you mean request_irq should move to somewhere, like open() or
>> hw_params() or ... ?
> You need to do enough hardware and software initialisation prior to
> requesting the interrupt to ensure that if an interrupt does happen it
> won't cause any ill effects.  Checks in the interrupt handler to make
> sure things like the ALSA layer stuff have been set up can also be used
> to make the interrupt handler safer.

I can understand your concern.
Let me clarify your think.
You think that interrupt handler must check whether ALSA initialization has
already finished or not before interrupt process executes.
Right?

thanks.
-- 
ROHM Co., Ltd.
tomoya


More information about the Alsa-devel mailing list