Skip to contentSkip to conversation

ASoC: rcar: mark device data as constant

PATCH Applied Uwe Kleine-König 2 participants 2 messages Mar 31, 2015 – Apr 1, 2015

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ASoC: rcar: mark device data as constant

A driver's device data should and can be const. This is a follow-up on commit 33187fb4a203 (ASoC: rsnd: constify of_device_id array) which marked the of_device_id as const.

---
This is also patch 4 of my series[1] which degraded to this hunk when rebasing to next because all the other changes were already addressed by Fabian.

Best regards
Uwe

[1] http://thread.gmane.org/gmane.linux.alsa.devel/136241/

 sound/soc/sh/rcar/core.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
sound/soc/sh/rcar/core.c +2 -2
index 3d8e4d60c83d..9f48d75fa992 100644
@@ -99,11 +99,11 @@
 #define RSND_RATES SNDRV_PCM_RATE_8000_96000
 #define RSND_FMTS (SNDRV_PCM_FMTBIT_S24_LE | SNDRV_PCM_FMTBIT_S16_LE)
 
-static struct rsnd_of_data rsnd_of_data_gen1 = {
+static const struct rsnd_of_data rsnd_of_data_gen1 = {
 	.flags = RSND_GEN1,
 };
 
-static struct rsnd_of_data rsnd_of_data_gen2 = {
+static const struct rsnd_of_data rsnd_of_data_gen2 = {
 	.flags = RSND_GEN2,
 };
 
Signature · 5 lines
2.1.4

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
maintainer Applied
#1 lore raw
Quoted 3 lines · Uwe Kleine-König

A driver's device data should and can be const. This is a follow-up on commit 33187fb4a203 (ASoC: rsnd: constify of_device_id array) which marked the of_device_id as const.

Applied, thanks. Please CC maintainers on patches and try to avoid CCing people who aren't really relevant - the latter helps cut down on mail volume.