Commit 70bad2c7 authored by Lars-Peter Clausen's avatar Lars-Peter Clausen Committed by Mark Brown

ASoC: wm8741: Constify rate constraints

The rate constraints in this driver are shared between all device instances. It
should not be (and is not) modified at runtime, so make them const.
Signed-off-by: default avatarLars-Peter Clausen <lars@metafoo.de>
Acked-by: default avatarCharles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: default avatarMark Brown <broonie@linaro.org>
parent 38dbfb59
...@@ -44,7 +44,7 @@ struct wm8741_priv { ...@@ -44,7 +44,7 @@ struct wm8741_priv {
struct regmap *regmap; struct regmap *regmap;
struct regulator_bulk_data supplies[WM8741_NUM_SUPPLIES]; struct regulator_bulk_data supplies[WM8741_NUM_SUPPLIES];
unsigned int sysclk; unsigned int sysclk;
struct snd_pcm_hw_constraint_list *sysclk_constraints; const struct snd_pcm_hw_constraint_list *sysclk_constraints;
}; };
static const struct reg_default wm8741_reg_defaults[] = { static const struct reg_default wm8741_reg_defaults[] = {
...@@ -122,74 +122,74 @@ static struct { ...@@ -122,74 +122,74 @@ static struct {
{ 6, 768 }, { 6, 768 },
}; };
static unsigned int rates_11289[] = { static const unsigned int rates_11289[] = {
44100, 88235, 44100, 88235,
}; };
static struct snd_pcm_hw_constraint_list constraints_11289 = { static const struct snd_pcm_hw_constraint_list constraints_11289 = {
.count = ARRAY_SIZE(rates_11289), .count = ARRAY_SIZE(rates_11289),
.list = rates_11289, .list = rates_11289,
}; };
static unsigned int rates_12288[] = { static const unsigned int rates_12288[] = {
32000, 48000, 96000, 32000, 48000, 96000,
}; };
static struct snd_pcm_hw_constraint_list constraints_12288 = { static const struct snd_pcm_hw_constraint_list constraints_12288 = {
.count = ARRAY_SIZE(rates_12288), .count = ARRAY_SIZE(rates_12288),
.list = rates_12288, .list = rates_12288,
}; };
static unsigned int rates_16384[] = { static const unsigned int rates_16384[] = {
32000, 32000,
}; };
static struct snd_pcm_hw_constraint_list constraints_16384 = { static const struct snd_pcm_hw_constraint_list constraints_16384 = {
.count = ARRAY_SIZE(rates_16384), .count = ARRAY_SIZE(rates_16384),
.list = rates_16384, .list = rates_16384,
}; };
static unsigned int rates_16934[] = { static const unsigned int rates_16934[] = {
44100, 88235, 44100, 88235,
}; };
static struct snd_pcm_hw_constraint_list constraints_16934 = { static const struct snd_pcm_hw_constraint_list constraints_16934 = {
.count = ARRAY_SIZE(rates_16934), .count = ARRAY_SIZE(rates_16934),
.list = rates_16934, .list = rates_16934,
}; };
static unsigned int rates_18432[] = { static const unsigned int rates_18432[] = {
48000, 96000, 48000, 96000,
}; };
static struct snd_pcm_hw_constraint_list constraints_18432 = { static const struct snd_pcm_hw_constraint_list constraints_18432 = {
.count = ARRAY_SIZE(rates_18432), .count = ARRAY_SIZE(rates_18432),
.list = rates_18432, .list = rates_18432,
}; };
static unsigned int rates_22579[] = { static const unsigned int rates_22579[] = {
44100, 88235, 1764000 44100, 88235, 1764000
}; };
static struct snd_pcm_hw_constraint_list constraints_22579 = { static const struct snd_pcm_hw_constraint_list constraints_22579 = {
.count = ARRAY_SIZE(rates_22579), .count = ARRAY_SIZE(rates_22579),
.list = rates_22579, .list = rates_22579,
}; };
static unsigned int rates_24576[] = { static const unsigned int rates_24576[] = {
32000, 48000, 96000, 192000 32000, 48000, 96000, 192000
}; };
static struct snd_pcm_hw_constraint_list constraints_24576 = { static const struct snd_pcm_hw_constraint_list constraints_24576 = {
.count = ARRAY_SIZE(rates_24576), .count = ARRAY_SIZE(rates_24576),
.list = rates_24576, .list = rates_24576,
}; };
static unsigned int rates_36864[] = { static const unsigned int rates_36864[] = {
48000, 96000, 19200 48000, 96000, 19200
}; };
static struct snd_pcm_hw_constraint_list constraints_36864 = { static const struct snd_pcm_hw_constraint_list constraints_36864 = {
.count = ARRAY_SIZE(rates_36864), .count = ARRAY_SIZE(rates_36864),
.list = rates_36864, .list = rates_36864,
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment