Mohan Kumar 834b540cf9 ASoC: tegra-alt: fix admaif mono/stereo conv
The admaif cif conversion from mono to stereo and vise-versa config
will take effect only when client/xbar channels are 1/2 or 2/1. If
this condition doesn't satisfy, the configured bit-field for mono_conv
and stereo_conv in cif ctrl register will not take effect.

Considering this the current code needs to be fixed.

- For Playback path:
 The Client and Audio channels won't be different as the data flows
from external memory to ahub. So override channel control have no say
on this path, for client_channel=1 and if "mono to stereo conv" control
was set then override audio_channel=2 for stereo conversion.

- For Capture path:
  The Client channel will be based on params_channels() and the xbar
channels can be different from client channel as it comes from other
ahub modules which can output different channel number compared to
client, So the "ADMAIFx Channel" wil be used for capture path to feed
proper xbar channel available. During stereo to mono conversion i.e
when audio_channel=2 and client_channel=1, the configuration in the
bitfield mono_conv will take effect.

Bug 200500656

Change-Id: Ie61aed848eb35715414a7d8f0e00eae9066b32d3
Signed-off-by: Mohan Kumar <mkumard@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/2080175
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
2022-09-10 23:43:40 -07:00
2022-09-07 12:27:01 -07:00
Description
No description provided
34 MiB