summaryrefslogtreecommitdiff
path: root/sound/soc/intel/boards/skl_rt286.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2017-06-09 00:37:23 +0300
committerMark Brown <broonie@kernel.org>2017-06-13 23:29:38 +0300
commit617647ae2880cf291293048f8cfd54f8111acb1c (patch)
tree825ef032ec655b8bf7484e256f796d2953de1c5f /sound/soc/intel/boards/skl_rt286.c
parent1ebb4d9dbf8f7a429abff359fa1d779b639da76f (diff)
downloadlinux-617647ae2880cf291293048f8cfd54f8111acb1c.tar.xz
ASoC: intel: skl: Constify hw_constraints
snd_pcm_hw_constraint_list(), *_ratnums() and *_ratdens() receive the const pointers. Constify the corresponding static objects for better hardening. Signed-off-by: Takashi Iwai <tiwai@suse.de> Acked-By: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/intel/boards/skl_rt286.c')
-rw-r--r--sound/soc/intel/boards/skl_rt286.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/sound/soc/intel/boards/skl_rt286.c b/sound/soc/intel/boards/skl_rt286.c
index f5ab7b8d51d1..e08c71625fd0 100644
--- a/sound/soc/intel/boards/skl_rt286.c
+++ b/sound/soc/intel/boards/skl_rt286.c
@@ -165,21 +165,21 @@ static int skylake_hdmi_init(struct snd_soc_pcm_runtime *rtd)
return 0;
}
-static unsigned int rates[] = {
+static const unsigned int rates[] = {
48000,
};
-static struct snd_pcm_hw_constraint_list constraints_rates = {
+static const struct snd_pcm_hw_constraint_list constraints_rates = {
.count = ARRAY_SIZE(rates),
.list = rates,
.mask = 0,
};
-static unsigned int channels[] = {
+static const unsigned int channels[] = {
2,
};
-static struct snd_pcm_hw_constraint_list constraints_channels = {
+static const struct snd_pcm_hw_constraint_list constraints_channels = {
.count = ARRAY_SIZE(channels),
.list = channels,
.mask = 0,
@@ -264,11 +264,11 @@ static int skylake_dmic_fixup(struct snd_soc_pcm_runtime *rtd,
return 0;
}
-static unsigned int channels_dmic[] = {
+static const unsigned int channels_dmic[] = {
2, 4,
};
-static struct snd_pcm_hw_constraint_list constraints_dmic_channels = {
+static const struct snd_pcm_hw_constraint_list constraints_dmic_channels = {
.count = ARRAY_SIZE(channels_dmic),
.list = channels_dmic,
.mask = 0,