diff options
author | Takashi Iwai <tiwai@suse.de> | 2020-01-03 11:16:50 +0300 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2020-01-03 11:24:24 +0300 |
commit | 0da2c47a951c27f1be34cb9221d77b0ed2db6cee (patch) | |
tree | b1f4052dd361aeb6b02a4e4d380200a7bc58957a /sound/i2c/tea6330t.c | |
parent | 2eccd408037449ac6c1ceba1d74bd10c67dc13d7 (diff) | |
download | linux-0da2c47a951c27f1be34cb9221d77b0ed2db6cee.tar.xz |
ALSA: i2c: Constify snd_kcontrol_new items
Most of snd_kcontrol_new definitions are read-only and passed as-is.
Let's declare them as const for further optimization.
There should be no functional changes by this patch.
Link: https://lore.kernel.org/r/20200103081714.9560-35-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/i2c/tea6330t.c')
-rw-r--r-- | sound/i2c/tea6330t.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/i2c/tea6330t.c b/sound/i2c/tea6330t.c index 93ca8bb71f54..08eb6a873768 100644 --- a/sound/i2c/tea6330t.c +++ b/sound/i2c/tea6330t.c @@ -260,7 +260,7 @@ static int snd_tea6330t_put_treble(struct snd_kcontrol *kcontrol, return change; } -static struct snd_kcontrol_new snd_tea6330t_controls[] = { +static const struct snd_kcontrol_new snd_tea6330t_controls[] = { TEA6330T_MASTER_SWITCH("Master Playback Switch", 0), TEA6330T_MASTER_VOLUME("Master Playback Volume", 0), TEA6330T_BASS("Tone Control - Bass", 0), @@ -278,7 +278,7 @@ int snd_tea6330t_update_mixer(struct snd_card *card, { struct snd_i2c_device *device; struct tea6330t *tea; - struct snd_kcontrol_new *knew; + const struct snd_kcontrol_new *knew; unsigned int idx; int err = -ENOMEM; u8 default_treble, default_bass; |