summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Madieu <john.madieu.xa@bp.renesas.com>2026-05-25 11:02:23 +0000
committerMark Brown <broonie@kernel.org>2026-06-01 15:30:21 +0100
commit692f03422f0e79365e33e7518e994bf7d3d12595 (patch)
treeb61e2d15f6955ac8321278f6d3ea4b6ab9139898
parent80f43c5217715641a3147eb223677e3c1600e65b (diff)
downloadlinux-next-692f03422f0e79365e33e7518e994bf7d3d12595.tar.gz
linux-next-692f03422f0e79365e33e7518e994bf7d3d12595.zip
ASoC: rsnd: Add SSI reset support for RZ/G3E platform
Acquire the per-SSI reset controller and pass it through rsnd_mod_init() so it is wired into the rsnd_mod->rstc plumbing. The RZ/G3E SoC exposes one reset line per SSI instance. Use the indexed-name rsnd_devm_reset_control_get_optional_indexed() helper so the same code accepts both the hyphenated RZ/G3E names ("ssi-0", "ssi-1", ...) and the legacy dotted names used by R-Car ("ssi.0", ...). The helper returns NULL when no reset is described in DT, leaving existing R-Car generations unaffected. Signed-off-by: John Madieu <john.madieu.xa@bp.renesas.com> Acked-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://patch.msgid.link/20260525110230.4014435-12-john.madieu.xa@bp.renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r--sound/soc/renesas/rcar/ssi.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/sound/soc/renesas/rcar/ssi.c b/sound/soc/renesas/rcar/ssi.c
index cf98cc9ee44c..e6734671328c 100644
--- a/sound/soc/renesas/rcar/ssi.c
+++ b/sound/soc/renesas/rcar/ssi.c
@@ -1157,6 +1157,7 @@ int __rsnd_ssi_is_pin_sharing(struct rsnd_mod *mod)
int rsnd_ssi_probe(struct rsnd_priv *priv)
{
+ struct reset_control *rstc;
struct device_node *node;
struct device *dev = rsnd_priv_to_dev(priv);
struct rsnd_mod_ops *ops;
@@ -1202,6 +1203,17 @@ int rsnd_ssi_probe(struct rsnd_priv *priv)
goto rsnd_ssi_probe_done;
}
+ /*
+ * RZ/G3E uses per-SSI reset controllers.
+ * R-Car platforms typically don't have SSI reset controls.
+ */
+ rstc = rsnd_devm_reset_control_get_optional_indexed(dev,
+ SSI_NAME, i);
+ if (IS_ERR(rstc)) {
+ ret = PTR_ERR(rstc);
+ goto rsnd_ssi_probe_done;
+ }
+
if (of_property_read_bool(np, "shared-pin"))
rsnd_flags_set(ssi, RSND_SSI_CLK_PIN_SHARE);
@@ -1220,7 +1232,7 @@ int rsnd_ssi_probe(struct rsnd_priv *priv)
ops = &rsnd_ssi_dma_ops;
ret = rsnd_mod_init(priv, rsnd_mod_get(ssi), ops, clk,
- NULL, RSND_MOD_SSI, i);
+ rstc, RSND_MOD_SSI, i);
if (ret)
goto rsnd_ssi_probe_done;