diff options
author | Takashi Iwai <tiwai@suse.de> | 2024-03-11 09:12:58 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2024-03-11 09:12:58 +0100 |
commit | 14b9e4ab71b3f58828c107d7158e52da1e670d1c (patch) | |
tree | c47d143c8315a02985cce3e0d6d63b07b5f865a2 /sound/soc/codecs/cs35l56.c | |
parent | Merge tag 'asoc-fix-v6.8-rc7' of https://git.kernel.org/pub/scm/linux/kernel/... (diff) | |
parent | platform/x86: serial-multi-instantiate: Add support for CS35L54 and CS35L57 (diff) | |
download | linux-14b9e4ab71b3f58828c107d7158e52da1e670d1c.tar.xz linux-14b9e4ab71b3f58828c107d7158e52da1e670d1c.zip |
Merge branch 'for-next' into for-linus
Prep for 6.9 merge.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/soc/codecs/cs35l56.c')
-rw-r--r-- | sound/soc/codecs/cs35l56.c | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/sound/soc/codecs/cs35l56.c b/sound/soc/codecs/cs35l56.c index 6dd0319bc843..450a163e6628 100644 --- a/sound/soc/codecs/cs35l56.c +++ b/sound/soc/codecs/cs35l56.c @@ -972,6 +972,10 @@ static int cs35l56_component_probe(struct snd_soc_component *component) return -ENODEV; } + cs35l56->dsp.part = kasprintf(GFP_KERNEL, "cs35l%02x", cs35l56->base.type); + if (!cs35l56->dsp.part) + return -ENOMEM; + cs35l56->component = component; wm_adsp2_component_probe(&cs35l56->dsp, component); @@ -1002,6 +1006,9 @@ static void cs35l56_component_remove(struct snd_soc_component *component) wm_adsp2_component_remove(&cs35l56->dsp, component); + kfree(cs35l56->dsp.part); + cs35l56->dsp.part = NULL; + kfree(cs35l56->dsp.fwf_name); cs35l56->dsp.fwf_name = NULL; @@ -1221,7 +1228,12 @@ static int cs35l56_dsp_init(struct cs35l56_private *cs35l56) dsp = &cs35l56->dsp; cs35l56_init_cs_dsp(&cs35l56->base, &dsp->cs_dsp); - dsp->part = "cs35l56"; + + /* + * dsp->part is filled in later as it is based on the DEVID. In a + * SoundWire system that cannot be read until enumeration has occurred + * and the device has attached. + */ dsp->fw = 12; dsp->wmfw_optional = true; |