linux.git
18 months agoASoC: Intel: avs: Drop superfluous stream decoupling
Cezary Rojewski [Fri, 29 Sep 2023 11:24:36 +0000 (13:24 +0200)]
ASoC: Intel: avs: Drop superfluous stream decoupling

HDAudio streams are decoupled on startup() and, decoupling them again on
prepare() is redundant.

Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Link: https://lore.kernel.org/r/20230929112436.787058-7-amadeuszx.slawinski@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: Intel: avs: Disable DSP before loading basefw
Wu Zhou [Fri, 29 Sep 2023 11:24:35 +0000 (13:24 +0200)]
ASoC: Intel: avs: Disable DSP before loading basefw

When audio controller is passed-through to the guest machine in
virtualized environment, the basefw load will fail the next time guest
OS reboots. Disable the DSP main core before loading the base firmware
to sanitize the environment.

Signed-off-by: Wu Zhou <wu.zhou@intel.com>
Signed-off-by: Libin Yang <libin.yang@intel.com>
Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Link: https://lore.kernel.org/r/20230929112436.787058-6-amadeuszx.slawinski@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: Intel: avs: Keep module refcount up when gathering traces
Cezary Rojewski [Fri, 29 Sep 2023 11:24:34 +0000 (13:24 +0200)]
ASoC: Intel: avs: Keep module refcount up when gathering traces

To prevent rmmod and similar behave unexpectedly when invoked on
snd_soc_avs module while the AudioDSP firmware tracing is ongoing,
increase the module refcount until the tracing is stopped.

Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Link: https://lore.kernel.org/r/20230929112436.787058-5-amadeuszx.slawinski@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: Intel: avs: Preallocate memory for module configuration
Amadeusz Sławiński [Fri, 29 Sep 2023 11:24:33 +0000 (13:24 +0200)]
ASoC: Intel: avs: Preallocate memory for module configuration

In order to instantiate modules on the firmware side, the driver sends
payload with module configuration. In some case size of this information
is not known before hand, so driver allocates temporary memory during
module creation and frees it after use. Optimize the flow a bit, by
preallocating maximum buffer. This removes the time spend on allocating
memory, as well as potential OOM errors during module initialization.

Handlers for modules, where configuration data fits on stack, are left
as is.

Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com>
Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Link: https://lore.kernel.org/r/20230929112436.787058-4-amadeuszx.slawinski@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: Intel: avs: Use generic size defines
Amadeusz Sławiński [Fri, 29 Sep 2023 11:24:32 +0000 (13:24 +0200)]
ASoC: Intel: avs: Use generic size defines

Instead of using PAGE_SIZE as base of definitions in headers, use
generic size defines. While x86 platforms use 4096 as page size, there
are platforms which use different page sizes. Two of changed defines are
for memory windows on DSP side, which have fixed size independent of
host side page size. Another one is for CLDMA buffer which also doesn't
need to change with page size.

Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com>
Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Link: https://lore.kernel.org/r/20230929112436.787058-3-amadeuszx.slawinski@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: Intel: avs: Move IPC error messages one level down
Cezary Rojewski [Fri, 29 Sep 2023 11:24:31 +0000 (13:24 +0200)]
ASoC: Intel: avs: Move IPC error messages one level down

Code size can be reduced if avs_dsp_send_xxx_msg()s take responsibility
for dumping logs in case of an IPC message failure. In consequence,
avs_ipc_err() helper is removed.

Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com>
Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Link: https://lore.kernel.org/r/20230929112436.787058-2-amadeuszx.slawinski@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: dt-bindings: Simplify referencing dai-params.yaml
Rob Herring [Thu, 28 Sep 2023 19:41:16 +0000 (14:41 -0500)]
ASoC: dt-bindings: Simplify referencing dai-params.yaml

There's generally no need to use definitions to reference from
individual properties. All the property names are the same, and all the
defined properties are used by all the users.

Signed-off-by: Rob Herring <robh@kernel.org>
Acked-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/20230928194126.1146622-1-robh@kernel.org
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: doc: Update codec to codec examples
Amadeusz Sławiński [Thu, 28 Sep 2023 13:47:06 +0000 (15:47 +0200)]
ASoC: doc: Update codec to codec examples

There are examples in documentation for codec to codec connection.
However they show method before recent series of patches which renamed
the fields. Update documentation accordingly.

Fixes: 7ddc7f91beb2 ("ASoC: soc.h: clarify Codec2Codec params")
Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Link: https://lore.kernel.org/r/20230928134706.662947-1-amadeuszx.slawinski@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: codecs: Add aw87390 amplifier driver
Mark Brown [Thu, 28 Sep 2023 13:22:35 +0000 (15:22 +0200)]
ASoC: codecs: Add aw87390 amplifier driver

Merge series from wangweidong.a@awinic.com:

The awinic aw87390 is a new high efficiency, low noise,
constant large volume, 6th Smart K audio amplifier.

18 months agoASoC: codecs: rtq9128: Add TDM input source select
Mark Brown [Thu, 28 Sep 2023 12:42:32 +0000 (14:42 +0200)]
ASoC: codecs: rtq9128: Add TDM input source select

Merge series from cy_huang@richtek.com:

This patch series create a TDM source select property and use it to
decide which TDM data source is connected.

Following by the below patch disccuion
https://lore.kernel.org/lkml/1695780376-32301-1-git-send-email-cy_huang@richtek.com/#t
It may not be a good choice to add the user controlable mixer control
item. Since it follows the board design, make it as a device property.

18 months agoASoC: codecs: Add aw87390 amplifier driver
Weidong Wang [Thu, 28 Sep 2023 10:57:27 +0000 (18:57 +0800)]
ASoC: codecs: Add aw87390 amplifier driver

Add i2c and amplifier registration for aw87390 and
their associated operation functions.

Signed-off-by: Weidong Wang <wangweidong.a@awinic.com>
Link: https://lore.kernel.org/r/20230928105727.47273-11-wangweidong.a@awinic.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: codecs: Modify the transmission mode of function parameters
Weidong Wang [Thu, 28 Sep 2023 10:57:26 +0000 (18:57 +0800)]
ASoC: codecs: Modify the transmission mode of function parameters

Change the transmission mode of the "aw88261_dev_get_prof_name"
function parameter

Signed-off-by: Weidong Wang <wangweidong.a@awinic.com>
Link: https://lore.kernel.org/r/20230928105727.47273-10-wangweidong.a@awinic.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: codecs: Rename "sync-flag" to "awinic,sync-flag"
Weidong Wang [Thu, 28 Sep 2023 10:57:25 +0000 (18:57 +0800)]
ASoC: codecs: Rename "sync-flag" to "awinic,sync-flag"

Rename "sync-flag" to "awinic,sync-flag", this is to be
consistent with the "awinic,aw88395.yaml" file

Signed-off-by: Weidong Wang <wangweidong.a@awinic.com>
Link: https://lore.kernel.org/r/20230928105727.47273-9-wangweidong.a@awinic.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: codecs: Add code for bin parsing compatible with aw87390
Weidong Wang [Thu, 28 Sep 2023 10:57:24 +0000 (18:57 +0800)]
ASoC: codecs: Add code for bin parsing compatible with aw87390

Add aw87390 compatible code to the aw88395_lib.c file
so that it can parse aw87390's bin file

Signed-off-by: Weidong Wang <wangweidong.a@awinic.com>
Link: https://lore.kernel.org/r/20230928105727.47273-8-wangweidong.a@awinic.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: codecs: Modify i2c driver name
Weidong Wang [Thu, 28 Sep 2023 10:57:23 +0000 (18:57 +0800)]
ASoC: codecs: Modify i2c driver name

Change the name of the i2c driver, this is to
be consistent with the "awinic,aw88395.yaml" file

Signed-off-by: Weidong Wang <wangweidong.a@awinic.com>
Link: https://lore.kernel.org/r/20230928105727.47273-7-wangweidong.a@awinic.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: codecs: Modify the transmission method of parameters
Weidong Wang [Thu, 28 Sep 2023 10:57:22 +0000 (18:57 +0800)]
ASoC: codecs: Modify the transmission method of parameters

Change the transmission mode of the "aw88395_dev_get_prof_name"
function parameter, Instead of using return values for data
transfer, parameters are used

Signed-off-by: Weidong Wang <wangweidong.a@awinic.com>
Link: https://lore.kernel.org/r/20230928105727.47273-6-wangweidong.a@awinic.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: codecs: Rename "sound-channel" to "awinic,audio-channel"
Weidong Wang [Thu, 28 Sep 2023 10:57:21 +0000 (18:57 +0800)]
ASoC: codecs: Rename "sound-channel" to "awinic,audio-channel"

Rename "sound-channel" to "awinic,audio-channel",
this is to be consistent with the "awinic,aw88395.yaml" file

Signed-off-by: Weidong Wang <wangweidong.a@awinic.com>
Link: https://lore.kernel.org/r/20230928105727.47273-5-wangweidong.a@awinic.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: codecs: Remove the "fade-enable property"
Weidong Wang [Thu, 28 Sep 2023 10:57:20 +0000 (18:57 +0800)]
ASoC: codecs: Remove the "fade-enable property"

Remove the "fade-enable" property because the "fade_step" property
already implement this functionality.

Signed-off-by: Weidong Wang <wangweidong.a@awinic.com>
Link: https://lore.kernel.org/r/20230928105727.47273-4-wangweidong.a@awinic.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: dt-bindings: Add schema for "awinic,aw87390"
Weidong Wang [Thu, 28 Sep 2023 10:57:19 +0000 (18:57 +0800)]
ASoC: dt-bindings: Add schema for "awinic,aw87390"

Add a DT schema for describing awinic aw87390 audio amplifiers.
They are controlled using I2C.

Signed-off-by: Weidong Wang <wangweidong.a@awinic.com>
Reviewed-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20230928105727.47273-3-wangweidong.a@awinic.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: dt-bindings: awinic,aw88395: Add properties for multiple PA support
Weidong Wang [Thu, 28 Sep 2023 10:57:18 +0000 (18:57 +0800)]
ASoC: dt-bindings: awinic,aw88395: Add properties for multiple PA support

Add two properties, the "awinic,audio-channel" property and the
"awinic,sync-flag". The "awinic,audio-channel" is used to make
different PA load different configurations, the "awinic,sync-flag"
is used to synchronize the phases of multiple PA. These two properties
will be read by the corresponding driver, allowing multi-PA to
achieve better playback effect.

Signed-off-by: Weidong Wang <wangweidong.a@awinic.com>
Acked-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20230928105727.47273-2-wangweidong.a@awinic.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: cs42l43: Remove useless else
Jiapeng Chong [Thu, 28 Sep 2023 08:52:00 +0000 (16:52 +0800)]
ASoC: cs42l43: Remove useless else

The assignment of the else and if branches is the same, so the else
here is redundant, so we remove it.

./sound/soc/codecs/cs42l43-sdw.c:35:1-3: WARNING: possible condition with no effect (if == else).

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Closes: https://bugzilla.openanolis.cn/show_bug.cgi?id=6712
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Link: https://lore.kernel.org/r/20230928085200.48635-1-jiapeng.chong@linux.alibaba.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: codecs: rtq9128: Add TDM input source select
ChiYuan Huang [Thu, 28 Sep 2023 03:41:08 +0000 (11:41 +0800)]
ASoC: codecs: rtq9128: Add TDM input source select

Pase the property to decide the TDM input source comes from 'DATA1' or
'DATA2 pin.

Signed-off-by: ChiYuan Huang <cy_huang@richtek.com>
Link: https://lore.kernel.org/r/1695872468-24433-3-git-send-email-cy_huang@richtek.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: dt-bindings: rtq9128: Add TDM input source slect property
ChiYuan Huang [Thu, 28 Sep 2023 03:41:07 +0000 (11:41 +0800)]
ASoC: dt-bindings: rtq9128: Add TDM input source slect property

Create a boolean property to select TDM input source coms from 'DATA2'.

Signed-off-by: ChiYuan Huang <cy_huang@richtek.com>
Link: https://lore.kernel.org/r/1695872468-24433-2-git-send-email-cy_huang@richtek.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agosh: boards: Fix Sound Simple-Card struct name
Kuninori Morimoto [Thu, 28 Sep 2023 00:04:16 +0000 (00:04 +0000)]
sh: boards: Fix Sound Simple-Card struct name

"asoc_simple_card_info" was renamed to "simple_util_info" by
commit ad484cc98f2 ("ASoC: remove asoc_xxx() compatible macro").
This patch fixup it For SH7724 boards.

Fixes: ad484cc98f2 ("ASoC: remove asoc_xxx() compatible macro")
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202309280417.rOLRdrdM-lkp@intel.com/
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87ttrfgo3j.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: soc-pcm.c: Make sure DAI parameters cleared if the DAI becomes inactive
Chancel Liu [Wed, 20 Sep 2023 15:36:21 +0000 (23:36 +0800)]
ASoC: soc-pcm.c: Make sure DAI parameters cleared if the DAI becomes inactive

The commit 1da681e52853 ("ASoC: soc-pcm.c: Clear DAIs parameters after
stream_active is updated") tries to make sure DAI parameters can be
cleared properly through moving the cleanup to the place where stream
active status is updated. However, it will cause the cleanup only
happening in soc_pcm_close().

Suppose a case: aplay -Dhw:0 44100.wav 48000.wav. The case calls
soc_pcm_open()->soc_pcm_hw_params()->soc_pcm_hw_free()->
soc_pcm_hw_params()->soc_pcm_hw_free()->soc_pcm_close() in order. The
parameters would be remained in the system even if the playback of
44100.wav is finished.

The case requires us clearing parameters in phase of soc_pcm_hw_free().
However, moving the DAI parameters cleanup back to soc_pcm_hw_free()
has the risk that DAIs parameters never be cleared if there're more
than one stream, see commit 1da681e52853 ("ASoC: soc-pcm.c: Clear DAIs
parameters after stream_active is updated") for more details.

To meet all these requirements, in addition to do DAI parameters
cleanup in soc_pcm_hw_free(), also check it in soc_pcm_close() to make
sure DAI parameters cleared if the DAI becomes inactive.

Fixes: 1da681e52853 ("ASoC: soc-pcm.c: Clear DAIs parameters after stream_active is updated")
Signed-off-by: Chancel Liu <chancel.liu@nxp.com>
Link: https://lore.kernel.org/r/20230920153621.711373-2-chancel.liu@nxp.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: remove asoc_xxx() compatible macro
Kuninori Morimoto [Tue, 26 Sep 2023 06:27:06 +0000 (06:27 +0000)]
ASoC: remove asoc_xxx() compatible macro

No driver is using asoc_xxx() any more.
This patch removes compatible macro for asoc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/878r8tfo06.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: sof: convert not to use asoc_xxx()
Kuninori Morimoto [Tue, 26 Sep 2023 06:25:22 +0000 (06:25 +0000)]
ASoC: sof: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87sf71fo32.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: intel: convert not to use asoc_xxx()
Kuninori Morimoto [Tue, 26 Sep 2023 06:24:24 +0000 (06:24 +0000)]
ASoC: intel: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87zg19fo4o.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: starfive: convert not to use asoc_xxx()
Kuninori Morimoto [Tue, 26 Sep 2023 06:23:51 +0000 (06:23 +0000)]
ASoC: starfive: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/874jjhh2q1.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: mediatek: convert not to use asoc_xxx()
Kuninori Morimoto [Tue, 26 Sep 2023 06:23:35 +0000 (06:23 +0000)]
ASoC: mediatek: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/877codh2qg.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: amd: convert not to use asoc_xxx()
Kuninori Morimoto [Tue, 26 Sep 2023 06:21:00 +0000 (06:21 +0000)]
ASoC: amd: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/875y3xihf7.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: Merge up fixes
Mark Brown [Tue, 26 Sep 2023 14:14:44 +0000 (16:14 +0200)]
ASoC: Merge up fixes

For the benefit of CI.

18 months agoASoC: convert asoc_xxx() to snd_soc_xxx()
Mark Brown [Tue, 26 Sep 2023 13:16:52 +0000 (15:16 +0200)]
ASoC: convert asoc_xxx() to snd_soc_xxx()

Merge series from Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>:

ASoC is using 2 type of prefix (asoc_xxx() vs snd_soc_xxx()), but there
is no particular reason about that [1].
To reduce confusing, standarding these to snd_soc_xxx() is sensible.

This patch adds asoc_xxx() macro to keep compatible for a while.
It will be removed if all drivers were switched to new style.

Link: https://lore.kernel.org/r/87h6td3hus.wl-kuninori.morimoto.gx@renesas.com
18 months agoASoC: fsl-asoc-card: use integer type for fll_id and pll_id
Shengjiu Wang [Wed, 20 Sep 2023 09:43:12 +0000 (17:43 +0800)]
ASoC: fsl-asoc-card: use integer type for fll_id and pll_id

As the pll_id and pll_id can be zero (WM8960_SYSCLK_AUTO)
with the commit 2bbc2df46e67 ("ASoC: wm8960: Make automatic the
default clocking mode")

Then the machine driver will skip to call set_sysclk() and set_pll()
for codec, when the sysclk rate is different with what wm8960 read
at probe, the output sound frequency is wrong.

So change the fll_id and pll_id initial value, still keep machine
driver's behavior same as before.

Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
Link: https://lore.kernel.org/r/1695202992-24864-1-git-send-email-shengjiu.wang@nxp.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: dt-bindings: Add missing (unevaluated|additional)Properties on child node schemas
Rob Herring [Mon, 25 Sep 2023 22:09:28 +0000 (17:09 -0500)]
ASoC: dt-bindings: Add missing (unevaluated|additional)Properties on child node schemas

Just as unevaluatedProperties or additionalProperties are required at
the top level of schemas, they should (and will) also be required for
child node schemas. That ensures only documented properties are
present for any node.

Add unevaluatedProperties or additionalProperties as appropriate.

Signed-off-by: Rob Herring <robh@kernel.org>
Acked-by: Herve Codina <herve.codina@bootlin.com>
Link: https://lore.kernel.org/r/20230925220947.2031536-1-robh@kernel.org
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: sh: dma-sh7760: Use %pad and %zu to format dma_addr_t and size_t
Geert Uytterhoeven [Mon, 25 Sep 2023 12:56:46 +0000 (14:56 +0200)]
ASoC: sh: dma-sh7760: Use %pad and %zu to format dma_addr_t and size_t

sound/soc/sh/dma-sh7760.c: In function ‘camelot_prepare’:
./include/linux/kern_levels.h:5:25: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 2 has type ‘unsigned int’ [-Wformat=]
    5 | #define KERN_SOH        "\001"          /* ASCII Start Of Header */
sound/soc/sh/dma-sh7760.c:198:9: note: in expansion of macro ‘pr_debug’
  198 |         pr_debug("PCM data: addr 0x%08lx len %d\n",
      |         ^~~~~~~~

Fix this by using "%pad" and taking the address to format the DMA
address.  While at it, use "%zu" to format size_t.

Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202309250903.XNAjFuxy-lkp@intel.com/
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/20230925125646.3681807-1-geert+renesas@glider.be
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: audio-iio-aux: Use flex array to simplify code
Christophe JAILLET [Sun, 24 Sep 2023 07:36:01 +0000 (09:36 +0200)]
ASoC: audio-iio-aux: Use flex array to simplify code

"io-channel-names" is expected to have few values, so there is no real
point to allocate audio_iio_aux_chan structure with a dedicate memory
allocation.

Using a flexible array for struct audio_iio_aux->chans avoids the
overhead of an additional, managed, memory allocation.

This also saves an indirection when the array is accessed.

Finally, __counted_by() can be used for run-time bounds checking if
configured and supported by the compiler.

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Link: https://lore.kernel.org/r/1c0090aaf49504eaeaff5e7dd119fd37173290b5.1695540940.git.christophe.jaillet@wanadoo.fr
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: soc-generic-dmaengine-pcm: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:52:23 +0000 (23:52 +0000)]
ASoC: soc-generic-dmaengine-pcm: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87cyyop8so.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: soc-component: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:52:18 +0000 (23:52 +0000)]
ASoC: soc-component: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87edj4p8st.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: soc-compress: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:52:13 +0000 (23:52 +0000)]
ASoC: soc-compress: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87fs3kp8sz.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: soc-topology: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:52:08 +0000 (23:52 +0000)]
ASoC: soc-topology: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87h6o0p8t4.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: soc-utils: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:52:02 +0000 (23:52 +0000)]
ASoC: soc-utils: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87il8gp8ta.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: soc-link: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:51:56 +0000 (23:51 +0000)]
ASoC: soc-link: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87jzswp8tf.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: soc-dapm: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:51:51 +0000 (23:51 +0000)]
ASoC: soc-dapm: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87ledcp8tk.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: soc-core: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:51:46 +0000 (23:51 +0000)]
ASoC: soc-core: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87msxsp8tp.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: soc-pcm: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:51:41 +0000 (23:51 +0000)]
ASoC: soc-pcm: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87o7i8p8tu.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: soc-dai: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:51:25 +0000 (23:51 +0000)]
ASoC: soc-dai: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87pm2op8ua.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: sof: mediatek: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:51:19 +0000 (23:51 +0000)]
ASoC: sof: mediatek: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87r0n4p8uh.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: sof: intel: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:51:14 +0000 (23:51 +0000)]
ASoC: sof: intel: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87sf7kp8um.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: sof: amd: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:51:08 +0000 (23:51 +0000)]
ASoC: sof: amd: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87tts0p8ur.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: codec: cs47lxx: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:50:57 +0000 (23:50 +0000)]
ASoC: codec: cs47lxx: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87wmwwp8v3.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: codec: rt5677: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:50:52 +0000 (23:50 +0000)]
ASoC: codec: rt5677: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87y1hcp8v8.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: codec: wm: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:50:47 +0000 (23:50 +0000)]
ASoC: codec: wm: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87zg1sp8vd.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: intel: avs: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:50:41 +0000 (23:50 +0000)]
ASoC: intel: avs: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/871qf4qnfz.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: soundwire: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:50:29 +0000 (23:50 +0000)]
ASoC: soundwire: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/874jk0qnga.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: uniphier: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:50:24 +0000 (23:50 +0000)]
ASoC: uniphier: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/875y4gqngf.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: starfive: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:50:19 +0000 (23:50 +0000)]
ASoC: starfive: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/877cowqngl.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: rockchip: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:50:13 +0000 (23:50 +0000)]
ASoC: rockchip: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/878r9cqngq.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: loongson: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:50:01 +0000 (23:50 +0000)]
ASoC: loongson: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87bke8qnh3.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: kirkwood: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:49:56 +0000 (23:49 +0000)]
ASoC: kirkwood: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87cyyoqnh8.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: extensa: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:49:51 +0000 (23:49 +0000)]
ASoC: extensa: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87edj4qnhd.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: samsung: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:49:45 +0000 (23:49 +0000)]
ASoC: samsung: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87fs3kqnhi.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: generic: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:49:40 +0000 (23:49 +0000)]
ASoC: generic: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87h6o0qnho.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: cirrus: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:49:34 +0000 (23:49 +0000)]
ASoC: cirrus: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87il8gqnht.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: google: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:49:29 +0000 (23:49 +0000)]
ASoC: google: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87jzswqnhy.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: ux500: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:49:24 +0000 (23:49 +0000)]
ASoC: ux500: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87ledcqni4.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: tegra: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:49:18 +0000 (23:49 +0000)]
ASoC: tegra: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87msxsqni9.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: sunxi: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:49:13 +0000 (23:49 +0000)]
ASoC: sunxi: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87o7i8qnie.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: meson: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:49:08 +0000 (23:49 +0000)]
ASoC: meson: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87pm2oqnik.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: atmel: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:49:01 +0000 (23:49 +0000)]
ASoC: atmel: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87r0n4qniq.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: apple: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:48:52 +0000 (23:48 +0000)]
ASoC: apple: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87sf7kqnj0.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: sprd: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:48:46 +0000 (23:48 +0000)]
ASoC: sprd: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87tts0qnj5.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: qcom: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:48:40 +0000 (23:48 +0000)]
ASoC: qcom: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87v8cgqnjc.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: au1x: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:48:33 +0000 (23:48 +0000)]
ASoC: au1x: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87wmwwqnji.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: stm: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:48:27 +0000 (23:48 +0000)]
ASoC: stm: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87y1hcqnjo.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: pxa: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:48:22 +0000 (23:48 +0000)]
ASoC: pxa: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87zg1sqnjt.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: mxs: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:48:13 +0000 (23:48 +0000)]
ASoC: mxs: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/871qf4s24j.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: img: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:48:07 +0000 (23:48 +0000)]
ASoC: img: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/8734zks24o.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: fsl: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:48:02 +0000 (23:48 +0000)]
ASoC: fsl: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/874jk0s24t.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: dwc: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:47:56 +0000 (23:47 +0000)]
ASoC: dwc: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/875y4gs24z.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: bcm: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:47:51 +0000 (23:47 +0000)]
ASoC: bcm: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/877cows255.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: amd: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:47:45 +0000 (23:47 +0000)]
ASoC: amd: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/878r9cs25b.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: arm: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:47:39 +0000 (23:47 +0000)]
ASoC: arm: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87a5tss25h.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: ti: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:47:29 +0000 (23:47 +0000)]
ASoC: ti: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87bke8s25q.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: sh: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:47:22 +0000 (23:47 +0000)]
ASoC: sh: convert not to use asoc_xxx()

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87cyyos25y.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: simple_card_utils.h: convert not to use asoc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:47:09 +0000 (23:47 +0000)]
ASoC: simple_card_utils.h: convert not to use asoc_xxx()

ASoC is using 2 type of prefix (asoc_xxx() vs snd_soc_xxx()),
but these are unified into snd_soc_xxx().

simple_card / audio_graph drivers are historically using
asoc_xxx() prefix too. simple_card / audio_graph are not
ASoC framework, so let's use simple_card_xxx_() / audio_graph_xxx()
for global function prefix.

This patch has asoc_xxx() as define to keep compatible.
It will be removed if all drivers were switched to new style.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87edj4s26a.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: soc.h: convert asoc_xxx() to snd_soc_xxx()
Kuninori Morimoto [Mon, 11 Sep 2023 23:47:02 +0000 (23:47 +0000)]
ASoC: soc.h: convert asoc_xxx() to snd_soc_xxx()

ASoC is using 2 type of prefix (asoc_xxx() vs snd_soc_xxx()), but there
is no particular reason about that [1].
To reduce confusing, standarding these to snd_soc_xxx() is sensible.

This patch adds asoc_xxx() macro to keep compatible for a while.
It will be removed if all drivers were switched to new style.

Link: https://lore.kernel.org/r/87h6td3hus.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87fs3ks26i.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: fsl_sai: Don't disable bitclock for i.MX8MP
Shengjiu Wang [Tue, 19 Sep 2023 09:42:13 +0000 (17:42 +0800)]
ASoC: fsl_sai: Don't disable bitclock for i.MX8MP

On i.MX8MP, the BCE and TERE bit are binding with mclk
enablement, if BCE and TERE are cleared the MCLK also be
disabled on output pin, that cause the external codec (wm8960)
in wrong state.

Codec (wm8960) is using the mclk to generate PLL clock,
if mclk is disabled before disabling PLL, the codec (wm8960)
won't generate bclk and frameclk when sysclk switch to
MCLK source in next test case.

The test case:
$aplay -r44100 test1.wav (PLL source)
$aplay -r48000 test2.wav (MCLK source)
aplay: pcm_write:2127: write error: Input/output error

Fixes: 269f399dc19f ("ASoC: fsl_sai: Disable bit clock with transmitter")
Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
Link: https://lore.kernel.org/r/1695116533-23287-1-git-send-email-shengjiu.wang@nxp.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agodt-bindings: ASoC: rockchip: Add compatible for RK3128 spdif
Alex Bee [Tue, 29 Aug 2023 17:16:19 +0000 (19:16 +0200)]
dt-bindings: ASoC: rockchip: Add compatible for RK3128 spdif

Add compatible for RK3128's S/PDIF.

Signed-off-by: Alex Bee <knaerzche@gmail.com>
Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20230829171647.187787-4-knaerzche@gmail.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: dt-bindings: tfa9879: Convert to dtschema
Bragatheswaran Manickavel [Thu, 21 Sep 2023 18:33:13 +0000 (00:03 +0530)]
ASoC: dt-bindings: tfa9879: Convert to dtschema

Convert the tfa9879 audio CODEC bindings to DT schema
No error/warning seen when running make dt_binding_check

Signed-off-by: Bragatheswaran Manickavel <bragathemanick0908@gmail.com>
Reviewed-by: Conor Dooley <conor.dooley@microchip.com>
Link: https://lore.kernel.org/r/20230921183313.54112-1-bragathemanick0908@gmail.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: soc-generic-dmaengine-pcm: Fix function name in comment
Miquel Raynal [Fri, 22 Sep 2023 16:15:47 +0000 (18:15 +0200)]
ASoC: soc-generic-dmaengine-pcm: Fix function name in comment

While browsing/grepping in the sound core, I found that
snd_dmaengine_set_config_from_dai_data() did not exist, in favor of
snd_dmaengine_pcm_set_config_from_dai_data(). Fix the typo.

Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/r/20230922161547.594484-1-miquel.raynal@bootlin.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: Add rtq9128 audio amplifier
Mark Brown [Thu, 21 Sep 2023 16:45:30 +0000 (17:45 +0100)]
ASoC: Add rtq9128 audio amplifier

Merge series from cy_huang@richtek.com:

This patch series adds Richtek rtq9128 automotive audio amplifier
support. It can deliver up to 4x75W into 4Ohm speaker from a 25V
supply in automotive applications.

18 months agoASoC: hdac_hda: fix HDA patch loader support
Bard Liao [Thu, 21 Sep 2023 06:43:17 +0000 (14:43 +0800)]
ASoC: hdac_hda: fix HDA patch loader support

The array size is irrelevant with SNDRV_CARDS. dev_index is from
codec address and the available codec number is HDA_MAX_CODECS.
Also, hda_pvt->fw is for a temporary use, no need to add a new extra
field in hdac_hda_priv{}.

Fixes: 842a62a75e70 ("ASoC: hdac_hda: add HDA patch loader support")
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Reviewed-by: Takashi Iwai <tiwai@suse.de>
Link: https://lore.kernel.org/r/20230921064317.2120452-1-yung-chuan.liao@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: codecs: Add Richtek rtq9128 audio amplifier support
ChiYuan Huang [Wed, 20 Sep 2023 03:50:34 +0000 (11:50 +0800)]
ASoC: codecs: Add Richtek rtq9128 audio amplifier support

Add Richtek rtq9128 automotive audio amplifier.

Signed-off-by: ChiYuan Huang <cy_huang@richtek.com>
Link: https://lore.kernel.org/r/1695181834-5809-3-git-send-email-cy_huang@richtek.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: dt-bindings: Add Richtek rtq9128 audio amplifier
ChiYuan Huang [Wed, 20 Sep 2023 03:50:33 +0000 (11:50 +0800)]
ASoC: dt-bindings: Add Richtek rtq9128 audio amplifier

Create richtek,rtq9128.yaml for rtq9128 amplifier.

Signed-off-by: ChiYuan Huang <cy_huang@richtek.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/1695181834-5809-2-git-send-email-cy_huang@richtek.com
Signed-off-by: Mark Brown <broonie@kernel.org>
18 months agoASoC: Intel: soc-acpi: Adding Es83x6 codec entry and
Mark Brown [Tue, 19 Sep 2023 18:30:55 +0000 (19:30 +0100)]
ASoC: Intel: soc-acpi: Adding Es83x6 codec entry and

Merge series from Bard Liao <yung-chuan.liao@linux.intel.com>:

Adding Es83x6 codec entry and HDMI-in capture support in MTL match table.

18 months agoMinor default jack pop performance updates
Mark Brown [Tue, 19 Sep 2023 17:22:20 +0000 (18:22 +0100)]
Minor default jack pop performance updates

Merge series from Charles Keepax <ckeepax@opensource.cirrus.com>:

Some small updates to the driver defaults to ensure a good pop
performance on jack insert and removal.

18 months agoASoC: SOF: ipc4/Intel: Support for firmware exception
Mark Brown [Tue, 19 Sep 2023 17:22:11 +0000 (18:22 +0100)]
ASoC: SOF: ipc4/Intel: Support for firmware exception

Merge series from Peter Ujfalusi <peter.ujfalusi@linux.intel.com>:

When a firmware crashes it creats a panic information into a telemetry
slot.  The panic format is defined by Zephyr, includes stack and
additional information to help to identify the reason for the crash.
Part of the firmware exception handling the firmware also sends an
EXCEPTION_CAUGHT notification.

This series implements the kernel side handling of the exception: print
information into the kernel log export the whole telemetry slot to user
space for tools extract additional information from the panic dump.

18 months agoASoC: SOF: ipc4-control: Support for Switch and Enum
Mark Brown [Tue, 19 Sep 2023 17:11:02 +0000 (18:11 +0100)]
ASoC: SOF: ipc4-control: Support for Switch and Enum

Merge series from Peter Ujfalusi <peter.ujfalusi@linux.intel.com>:

Currently IPC4 has no notion of a switch or enum type of control which
is a generic concept in ALSA.

The generic support for these control types will be as follows:

- large config is used to send the channel-value par array
- param_id of a SWITCH type is 200
- param_id of an ENUM type is 201

Each module need to support a switch or/and enum must handle these
universal param_ids.  The message payload is described by struct
sof_ipc4_control_msg_payload.

18 months agoASoC: intel: Add CS42L43 sdw machine driver support
Mark Brown [Tue, 19 Sep 2023 16:59:40 +0000 (17:59 +0100)]
ASoC: intel: Add CS42L43 sdw machine driver support

Merge series from Bard Liao <yung-chuan.liao@linux.intel.com>:

Add cs42l43 codec support to sof_sdw machine driver.