diff options
author | Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> | 2023-03-24 04:44:07 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2023-03-29 17:03:09 +0300 |
commit | cf1d6a3ad07c982a09455bf8720dc75754909932 (patch) | |
tree | 32a38910b7accf394757640692e568a8bd4444e7 /sound/soc/codecs/rt715-sdca.h | |
parent | e506b2bd1d2e9daaedd1db2ef9868f7b8c4c86c3 (diff) | |
download | linux-cf1d6a3ad07c982a09455bf8720dc75754909932.tar.xz |
ASoC: codecs: rt715-sdca: simplify set_stream
Using a dynamic allocation to store a single pointer is not very
efficient/useful.
Worse, the memory is released in the SoundWire stream.c file, but
still accessed in the DAI shutdown, leading to kmemleak reports.
And last the API requires the previous stream information to be
cleared when the argument is NULL.
Simplify the code to address all 3 problems.
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com>
Reviewed-by: Rander Wang <rander.wang@intel.com>
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Link: https://lore.kernel.org/r/20230324014408.1677505-13-yung-chuan.liao@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/codecs/rt715-sdca.h')
-rw-r--r-- | sound/soc/codecs/rt715-sdca.h | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/sound/soc/codecs/rt715-sdca.h b/sound/soc/codecs/rt715-sdca.h index 90881b455ece..7577f3151934 100644 --- a/sound/soc/codecs/rt715-sdca.h +++ b/sound/soc/codecs/rt715-sdca.h @@ -37,10 +37,6 @@ struct rt715_sdca_priv { int kctl_8ch_orig[8]; }; -struct rt715_sdw_stream_data { - struct sdw_stream_runtime *sdw_stream; -}; - struct rt715_sdca_kcontrol_private { unsigned int reg_base; unsigned int count; |