Use helper function for_each_child_of_node_scoped()Merge series from Ai Chao <aichao@kylinos.cn>:This patch series introduces wrapper functions for_each_child_of_node_scoped().The for_each_chil
Use helper function for_each_child_of_node_scoped()Merge series from Ai Chao <aichao@kylinos.cn>:This patch series introduces wrapper functions for_each_child_of_node_scoped().The for_each_child_of_node_scoped() helper provides a scope-based clean-upfunctionality to put the device_node automatically, and as such, there isno need to call of_node_put() directly.
show more ...
ASoC: renesas: msiof: Convert to <linux/spi/sh_msiof.h>Convert the MSIOF I2S driver to reuse the MSIOF register and registerbit definitions in the header file shared by the MSIOF SPI driver.Sign
ASoC: renesas: msiof: Convert to <linux/spi/sh_msiof.h>Convert the MSIOF I2S driver to reuse the MSIOF register and registerbit definitions in the header file shared by the MSIOF SPI driver.Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>Tested-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Link: https://patch.msgid.link/754ed54057e54effd06143e71d6cd305c3334eca.1747401908.git.geert+renesas@glider.beSigned-off-by: Mark Brown <broonie@kernel.org>
ASoC: renesas: Use helper function for_each_child_of_node_scoped()The for_each_child_of_node_scoped() helper provides a scope-basedclean-up functionality to put the device_node automatically, and
ASoC: renesas: Use helper function for_each_child_of_node_scoped()The for_each_child_of_node_scoped() helper provides a scope-basedclean-up functionality to put the device_node automatically, andas such, there is no need to call of_node_put() directly.Acked-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Signed-off-by: Ai Chao <aichao@kylinos.cn>Link: https://patch.msgid.link/20250603055109.3154061-3-aichao@kylinos.cnSigned-off-by: Mark Brown <broonie@kernel.org>
ASoC: add Renesas MSIOF sound driverMerge series from Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>:Renesas MSIOF can work as both SPI and I2S.Current Linux supports MSIOF-SPI. This patch
ASoC: add Renesas MSIOF sound driverMerge series from Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>:Renesas MSIOF can work as both SPI and I2S.Current Linux supports MSIOF-SPI. This patch-set adds new MSIOF-I2S.Because it is using same HW-IP, we want to share same compatible for bothMSIOF-SPI/I2S case. MSIOF-I2S (Sound) will use Audio-Graph-Card/Card2 whichuses Of-Graph, but MSIOF-SPI is not use Of-Graph.So, this patch-set assumes it was used as MSIOF-I2S if DT is using Of-Graph,otherwise, it is MSIOF-SPI (This assumption will works if SPI *never*use Of-Graph in the future).One note so far is that it is using "spi@xxx" node name for bothMSIOF-SPI/I2S. DTC will automatically checks "spi@xxx" node as SPI devicewhich requests #address-cells/#size-cells. But is not needed for I2S.So we will get warning about it on Sparrow Hawk which uses MSIOF-I2S.We have no solution about it, so far.Link: https://lore.kernel.org/r/87zfgi1a5a.wl-kuninori.morimoto.gx@renesas.comLink: https://lore.kernel.org/r/87h62vh5mj.wl-kuninori.morimoto.gx@renesas.comLink: https://lore.kernel.org/r/875xjeb0wu.wl-kuninori.morimoto.gx@renesas.com
ASoC: renesas: add MSIOF sound supportRenesas MSIOF (Clock-Synchronized Serial Interface with FIFO) can work asboth SPI and I2S. Adds MSIOF-I2S driver.MSIOF-SPI/I2S are using same DT compatible
ASoC: renesas: add MSIOF sound supportRenesas MSIOF (Clock-Synchronized Serial Interface with FIFO) can work asboth SPI and I2S. Adds MSIOF-I2S driver.MSIOF-SPI/I2S are using same DT compatible properties.MSIOF-I2S uses Of-Graph for Audio-Graph-Card/Card2,MSIOF-SPI doesn't use Of-Graph.Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>Link: https://patch.msgid.link/87r01q2wzv.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
ASoC: renesas: rsnd: enable to use "adg" clockADG needs its MSTP to use it, and it was handled as "clk_i" before.R-Car Gen2/Gen3 are using it, but Gen4 doesn't have it."clk_i" is not intuitive fo
ASoC: renesas: rsnd: enable to use "adg" clockADG needs its MSTP to use it, and it was handled as "clk_i" before.R-Car Gen2/Gen3 are using it, but Gen4 doesn't have it."clk_i" is not intuitive for ADG MSTP.Let's enable to use "adg" clock. It can keep compatible with R-CarGen2/Gen3 and Gen4.Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Link: https://patch.msgid.link/87sem62x00.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
ASoC: renesas: rsnd: care BRGA/BRGB select in rsnd_adg_clk_enable()Renesas rsnd related clocks are enabled by rsnd_adg_clk_enable(),but it doesn't care about BRGA/BRGB selection (It is handled whe
ASoC: renesas: rsnd: care BRGA/BRGB select in rsnd_adg_clk_enable()Renesas rsnd related clocks are enabled by rsnd_adg_clk_enable(),but it doesn't care about BRGA/BRGB selection (It is handled whenSSI was started) (BRGA is used for 44.1kHz lineage, BRGB is used for48kHz lineage in this driver).But it should be handled since probe time.Includes BRGCKR_31 in adg->ckr to handle it since boot time.Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Link: https://patch.msgid.link/87tt6m2x05.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
ASoC: renesas: rsnd: allow to use ADG as standaloneAudio clock generator (= ADG) can be used standalone (without DAI),but current driver indicates error if it doesn't have DAI on DT.It is not err
ASoC: renesas: rsnd: allow to use ADG as standaloneAudio clock generator (= ADG) can be used standalone (without DAI),but current driver indicates error if it doesn't have DAI on DT.It is not error, allow to use ADG as standalone.Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Link: https://patch.msgid.link/87v7r22x0a.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
ASoC: rsnd: use snd_pcm_direction_name()We already have snd_pcm_direction_name(). Let's use it.Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Link: https://patch.msgid.link/8
ASoC: rsnd: use snd_pcm_direction_name()We already have snd_pcm_direction_name(). Let's use it.Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Link: https://patch.msgid.link/87bjszr1xp.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
ASoC: rcar: Convert to SYSTEM_SLEEP_PM_OPS()Use the newer SYSTEM_SLEEP_PM_OPS() macro instead ofSET_SYSTEM_SLEEP_PM_OPS() together with pm_ptr(), which allows us todrop ugly __maybe_unused attrib
ASoC: rcar: Convert to SYSTEM_SLEEP_PM_OPS()Use the newer SYSTEM_SLEEP_PM_OPS() macro instead ofSET_SYSTEM_SLEEP_PM_OPS() together with pm_ptr(), which allows us todrop ugly __maybe_unused attributes.This optimizes slightly when CONFIG_PM is disabled, too.Acked-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Signed-off-by: Takashi Iwai <tiwai@suse.de>Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com>Link: https://patch.msgid.link/20250317095603.20073-75-tiwai@suse.deSigned-off-by: Mark Brown <broonie@kernel.org>
ASoC: rsnd: adjust convert rate limitationCurrent rsnd driver supports Synchronous SRC Mode, but HW allow to updaterate only within 1% from current rate. Adjust to it.Becially, this feature is u
ASoC: rsnd: adjust convert rate limitationCurrent rsnd driver supports Synchronous SRC Mode, but HW allow to updaterate only within 1% from current rate. Adjust to it.Becially, this feature is used to fine-tune subtle difference that occurduring sampling rate conversion in SRC. So, it should be called within 1%margin of rate difference.If there was difference over 1%, it will apply with 1% increments by usingloop without indicating error message.Cc: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Reviewed-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>Tested-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>Link: https://patch.msgid.link/871pwd2qe8.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
ASoC: rsnd: don't indicate warning on rsnd_kctrl_accept_runtime()rsnd_kctrl_accept_runtime() (1) is used for runtime convert rate(= Synchronous SRC Mode). Now, rsnd driver has 2 kctrls for it(A)
ASoC: rsnd: don't indicate warning on rsnd_kctrl_accept_runtime()rsnd_kctrl_accept_runtime() (1) is used for runtime convert rate(= Synchronous SRC Mode). Now, rsnd driver has 2 kctrls for it(A): "SRC Out Rate Switch"(B): "SRC Out Rate" // it calls (1)(A): can be called anytime(B): can be called only runtime, and will indicate warning if it was used at non-runtime.To use runtime convert rate (= Synchronous SRC Mode), user might usescommand in below order.(X): > amixer set "SRC Out Rate" on > aplay xxx.wav &(Y): > amixer set "SRC Out Rate" 48010 // convert rate to 48010Hz(Y): calls B(X): calls both A and B.In this case, when user calls (X), it calls both (A) and (B), but it is notyet start running. So, (B) will indicate warning.This warning was added by commit b5c088689847 ("ASoC: rsnd: add warningmessage to rsnd_kctrl_accept_runtime()"), but the message sounds like theoperation was not correct. Let's update warning message.The message is very SRC specific, implement it in src.cSigned-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Reviewed-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>Link: https://patch.msgid.link/8734gt2qed.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
ASoC: rsnd: indicate unsupported clock rateIt will indicate "unsupported clock rate" when setup clock failed.But it is unclear what kind of rate was failed. Indicate it.Signed-off-by: Kuninori M
ASoC: rsnd: indicate unsupported clock rateIt will indicate "unsupported clock rate" when setup clock failed.But it is unclear what kind of rate was failed. Indicate it.Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Reviewed-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>Link: https://patch.msgid.link/874j192qej.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
ASoC: rsnd: check rsnd_adg_clk_enable() return valuersnd_adg_clk_enable() might be failed for some reasons, but it doesn'tcheck return value for now. In such case, we might get below WARNING from
ASoC: rsnd: check rsnd_adg_clk_enable() return valuersnd_adg_clk_enable() might be failed for some reasons, but it doesn'tcheck return value for now. In such case, we might get below WARNING fromclk_disable() during probe or suspend. Check rsnd_adg_clk_enable() returnvalue. clk_multiplier already disabled ... Call trace: clk_core_disable+0xd0/0xd8 (P) clk_disable+0x2c/0x44 rsnd_adg_clk_control+0x80/0xf4According to Geert, it happened only 7 times during the last 2 years.So I have reproduced the issue and created patch by Intentionally makingan error.Link: https://lore.kernel.org/r/CAMuHMdVUKpO2rsia+36BLFFwdMapE8LrYS0duyd0FmrxDvwEfg@mail.gmail.comReported-by: Geert Uytterhoeven <geert@linux-m68k.org>Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Link: https://patch.msgid.link/87seps2522.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
ASoC: sh: switch to use rtd->id from rtd->numNow rtd->num is renamed to rtd->id. Let's switch.Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Link: https://patch.msgid.link/87
ASoC: sh: switch to use rtd->id from rtd->numNow rtd->num is renamed to rtd->id. Let's switch.Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Link: https://patch.msgid.link/87v7xib85e.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>
ASoC: Rename "sh" to "renesas"Rename the "sh" folder to "renesas" to better reflect the Renesas-specificdrivers.Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>Acked-by: K
ASoC: Rename "sh" to "renesas"Rename the "sh" folder to "renesas" to better reflect the Renesas-specificdrivers.Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>Acked-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>Link: https://patch.msgid.link/20241025150511.722040-2-prabhakar.mahadev-lad.rj@bp.renesas.comSigned-off-by: Mark Brown <broonie@kernel.org>