Commit 27ad02f3 authored by Krzysztof Kozlowski's avatar Krzysztof Kozlowski Committed by Mark Brown

ASoC: wm8804: Constify struct regmap_config and snd_soc_codec_driver

The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const. Make struct
snd_soc_codec_driver (snd_soc_register_codec() accepts pointer to const)
and array of default register values const as well.
Signed-off-by: default avatarKrzysztof Kozlowski <k.kozlowski@samsung.com>
Acked-by: default avatarBrian Austin <brian.austin@cirrus.com>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent c0b36389
...@@ -44,7 +44,7 @@ static const char *wm8995_supply_names[WM8995_NUM_SUPPLIES] = { ...@@ -44,7 +44,7 @@ static const char *wm8995_supply_names[WM8995_NUM_SUPPLIES] = {
"MICVDD" "MICVDD"
}; };
static struct reg_default wm8995_reg_defaults[] = { static const struct reg_default wm8995_reg_defaults[] = {
{ 0, 0x8995 }, { 0, 0x8995 },
{ 5, 0x0100 }, { 5, 0x0100 },
{ 16, 0x000b }, { 16, 0x000b },
...@@ -2190,7 +2190,7 @@ static struct snd_soc_dai_driver wm8995_dai[] = { ...@@ -2190,7 +2190,7 @@ static struct snd_soc_dai_driver wm8995_dai[] = {
} }
}; };
static struct snd_soc_codec_driver soc_codec_dev_wm8995 = { static const struct snd_soc_codec_driver soc_codec_dev_wm8995 = {
.probe = wm8995_probe, .probe = wm8995_probe,
.remove = wm8995_remove, .remove = wm8995_remove,
.set_bias_level = wm8995_set_bias_level, .set_bias_level = wm8995_set_bias_level,
...@@ -2204,7 +2204,7 @@ static struct snd_soc_codec_driver soc_codec_dev_wm8995 = { ...@@ -2204,7 +2204,7 @@ static struct snd_soc_codec_driver soc_codec_dev_wm8995 = {
.num_dapm_routes = ARRAY_SIZE(wm8995_intercon), .num_dapm_routes = ARRAY_SIZE(wm8995_intercon),
}; };
static struct regmap_config wm8995_regmap = { static const struct regmap_config wm8995_regmap = {
.reg_bits = 16, .reg_bits = 16,
.val_bits = 16, .val_bits = 16,
......
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