Linux Sound subsystem development
 help / color / mirror / Atom feed
* [PATCH 0/7] ASoC: use snd_soc_dapm_to_component()
@ 2025-04-09  2:56 Kuninori Morimoto
  2025-04-09  2:57 ` [PATCH 1/7] ASoC: soc-component: use dapm->component instead of container_of() Kuninori Morimoto
                   ` (6 more replies)
  0 siblings, 7 replies; 18+ messages in thread
From: Kuninori Morimoto @ 2025-04-09  2:56 UTC (permalink / raw)
  To: AngeloGioacchino Del Regno, Bard Liao, Cezary Rojewski,
	Jaroslav Kysela, Kai Vehmanen, Kiseok Jo, Liam Girdwood,
	Mark Brown, Matthias Brugger, Peter Ujfalusi,
	Pierre-Louis Bossart, Ranjani Sridharan, Takashi Iwai,
	Vijendar Mukunda, Benjamin Bara, linux-sound


Hi Mark

Current snd_soc_dapm_to_component() is using container_of(),
thus, caution is required to use it not to get strange pointer.

But, dapm has component pointer (= dapm->component), and we can simply use
it. If we use dapm->component instead of container_of(), above caution
is no longer needed.

Let's use dapm->component in snd_soc_dapm_to_component(), and use it.

Kuninori Morimoto (7):
  ASoC: soc-component: use dapm->component instead of container_of()
  ASoC: amd: use snd_soc_dapm_to_component()
  ASoC: sma1307: use snd_soc_dapm_to_component()
  ASoC: intel: use snd_soc_dapm_to_component()
  ASoC: mediatek: use snd_soc_dapm_to_component()
  ASoC: soc-dapm: use snd_soc_dapm_to_component()
  ASoC: soc-topology: use snd_soc_dapm_to_component()

 include/sound/soc-component.h             |  6 +--
 sound/soc/amd/acp/acp-mach-common.c       |  2 +-
 sound/soc/codecs/sma1307.c                | 32 ++++++-------
 sound/soc/intel/avs/control.c             |  2 +-
 sound/soc/mediatek/mt8195/mt8195-mt6359.c |  2 +-
 sound/soc/soc-dapm.c                      | 58 +++++++++++++++--------
 sound/soc/soc-topology.c                  |  3 +-
 7 files changed, 60 insertions(+), 45 deletions(-)

-- 
2.43.0


^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2025-04-17 23:01 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-09  2:56 [PATCH 0/7] ASoC: use snd_soc_dapm_to_component() Kuninori Morimoto
2025-04-09  2:57 ` [PATCH 1/7] ASoC: soc-component: use dapm->component instead of container_of() Kuninori Morimoto
2025-04-09  7:59   ` Cezary Rojewski
2025-04-10  0:19     ` Kuninori Morimoto
2025-04-11  2:04       ` Kuninori Morimoto
2025-04-11  9:07         ` Cezary Rojewski
2025-04-13 23:39           ` Kuninori Morimoto
2025-04-14  2:01             ` Kuninori Morimoto
2025-04-17  9:34               ` Cezary Rojewski
2025-04-17 23:00                 ` Kuninori Morimoto
2025-04-09  2:57 ` [PATCH 2/7] ASoC: amd: use snd_soc_dapm_to_component() Kuninori Morimoto
2025-04-09  2:57 ` [PATCH 3/7] ASoC: sma1307: " Kuninori Morimoto
2025-04-09  2:57 ` [PATCH 4/7] ASoC: intel: " Kuninori Morimoto
2025-04-09  8:03   ` Cezary Rojewski
2025-04-10  0:20     ` Kuninori Morimoto
2025-04-09  2:57 ` [PATCH 5/7] ASoC: mediatek: " Kuninori Morimoto
2025-04-09  2:57 ` [PATCH 6/7] ASoC: soc-dapm: " Kuninori Morimoto
2025-04-09  2:57 ` [PATCH 7/7] ASoC: soc-topology: " Kuninori Morimoto

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox