[PATCH 0/4] ASoC: Intel: Mark BE DAIs as nonatomic for hsw and

Cezary Rojewski cezary.rojewski at intel.com
Mon Jun 27 17:41:07 CEST 2022


On 2022-06-27 4:45 PM, Pierre-Louis Bossart wrote:
> On 6/25/22 03:29, Cezary Rojewski wrote:

>> Hmm.. that's a good feedback. Isn't ASoC's FE<->BE treated as a single
>> PCM substream in sound/core/pcm_native.c though? If so, does it even
>> make sense for card's BE DAI to be atomic, if it's FE counterpart is
>> nonatomic already? Especially if it is specifying platform and cpu_dai
>> that matches Intel's components which we know communicate using IPCs.
> 
> I guess it depends on the cpu_dai implementation. Not all
> implementations implement a delay in the .trigger callback and/or rely
> on IPCs.
> 
>> Warning is one thing, but will you be also getting rid of the
>> if-statement in soc-pcm.c that actually forces nonatomic=1 on BE when FE
>> is already declared as such? If the if-statement stays, I believe the
>> declaring BE DAIs 'correctly' in the way to go.
> 
> I meant just removing the dev_warn() only.
> 
> See https://github.com/thesofproject/linux/pull/3723

So the framework is still fixing the flag for the driver. Ideally we 
would like to have all the drivers assign correct values to ->nonatomic 
flag themselves.

Now when I think about it, the message seems useful - at least as 
dev_dbg(). It _guides_ driver developer to the desired approach: setting 
the ->nonatomic flag for BE to '1' if the corresponding FE is already 
configured as such.

I've provided similar answer in the linked thread.


Regards,
Czarek


More information about the Alsa-devel mailing list