[PATCH v2 0/2] {ASoC,media}: constify snd_soc_component_driver when used as read-only
From: Javier Carrasco
Date: Mon Jul 29 2024 - 05:38:04 EST
Declare `snd_soc_component_driver` as const to move their declarations
to read-only sections for the drivers that do not modify the struct
after its declaration.
Apart from a single case under media/, the affected drivers are members
of the ASoC subsystem.
To: Tim Harvey <tharvey@xxxxxxxxxxxxx>
To: Mauro Carvalho Chehab <mchehab@xxxxxxxxxx>
To: Liam Girdwood <lgirdwood@xxxxxxxxx>
To: Mark Brown <broonie@xxxxxxxxxx>
To: Jaroslav Kysela <perex@xxxxxxxx>
To: Takashi Iwai <tiwai@xxxxxxxx>
To: Ray Jui <rjui@xxxxxxxxxxxx>
To: Scott Branden <sbranden@xxxxxxxxxxxx>
To: Broadcom internal kernel review list <bcm-kernel-feedback-list@xxxxxxxxxxxx>
To: Shenghao Ding <shenghao-ding@xxxxxx>
To: Kevin Lu <kevin-lu@xxxxxx>
To: Baojun Xu <baojun.xu@xxxxxx>
To: Olivier Moysan <olivier.moysan@xxxxxxxxxxx>
To: Arnaud Pouliquen <arnaud.pouliquen@xxxxxxxxxxx>
To: Maxime Coquelin <mcoquelin.stm32@xxxxxxxxx>
To: Alexandre Torgue <alexandre.torgue@xxxxxxxxxxx>
To: Kunihiko Hayashi <hayashi.kunihiko@xxxxxxxxxxxxx>
To: Masami Hiramatsu <mhiramat@xxxxxxxxxx>
Cc: linux-media@xxxxxxxxxxxxxxx
Cc: linux-kernel@xxxxxxxxxxxxxxx
Cc: linux-sound@xxxxxxxxxxxxxxx
Cc: linux-arm-kernel@xxxxxxxxxxxxxxxxxxx
Cc: alsa-devel@xxxxxxxxxxxxxxxx
Cc: linux-stm32@xxxxxxxxxxxxxxxxxxxxxxxxxxxx
Signed-off-by: Javier Carrasco <javier.carrasco.cruz@xxxxxxxxx>
Changes in v2:
- drop cs43130 and sti-sas, as they modifiy the struct in the probe
function.
- Link to v1: https://lore.kernel.org/r/20240725-const_snd_soc_component_driver-v1-0-3d7ee08e129b@xxxxxxxxx
---
Javier Carrasco (2):
media: i2c: tda1997x: constify snd_soc_component_driver struct
ASoC: constify snd_soc_component_driver struct
drivers/media/i2c/tda1997x.c | 2 +-
sound/soc/au1x/dbdma2.c | 2 +-
sound/soc/au1x/dma.c | 2 +-
sound/soc/bcm/cygnus-pcm.c | 2 +-
sound/soc/codecs/cpcap.c | 2 +-
sound/soc/codecs/pcm186x.c | 4 ++--
sound/soc/codecs/pcm5102a.c | 2 +-
sound/soc/codecs/spdif_receiver.c | 2 +-
sound/soc/codecs/spdif_transmitter.c | 2 +-
sound/soc/codecs/tas6424.c | 2 +-
sound/soc/stm/stm32_adfsdm.c | 2 +-
sound/soc/uniphier/evea.c | 2 +-
12 files changed, 13 insertions(+), 13 deletions(-)
---
base-commit: 8400291e289ee6b2bf9779ff1c83a291501f017b
change-id: 20240725-const_snd_soc_component_driver-b9629a95b948
Best regards,
--
Javier Carrasco <javier.carrasco.cruz@xxxxxxxxx>