未验证 提交 10b155fd 编写于 作者: R Rikard Falkeborn 提交者: Mark Brown

ASoC: intel: boards: bytcht*: Constify static snd_soc_ops

These are only assigned to the ops fields in the snd_soc_dai_link struct
which is a pointer to const struct snd_soc_ops. Make them const to allow
the compiler to put them in read-only memory.
Signed-off-by: NRikard Falkeborn <rikard.falkeborn@gmail.com>
Acked-by: NPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20211127091954.12075-1-rikard.falkeborn@gmail.comSigned-off-by: NMark Brown <broonie@kernel.org>
上级 11918cdc
...@@ -147,7 +147,7 @@ static int byt_cht_cx2072x_aif1_startup(struct snd_pcm_substream *substream) ...@@ -147,7 +147,7 @@ static int byt_cht_cx2072x_aif1_startup(struct snd_pcm_substream *substream)
SNDRV_PCM_HW_PARAM_RATE, 48000); SNDRV_PCM_HW_PARAM_RATE, 48000);
} }
static struct snd_soc_ops byt_cht_cx2072x_aif1_ops = { static const struct snd_soc_ops byt_cht_cx2072x_aif1_ops = {
.startup = byt_cht_cx2072x_aif1_startup, .startup = byt_cht_cx2072x_aif1_startup,
}; };
......
...@@ -93,7 +93,7 @@ static int aif1_startup(struct snd_pcm_substream *substream) ...@@ -93,7 +93,7 @@ static int aif1_startup(struct snd_pcm_substream *substream)
&constraints_48000); &constraints_48000);
} }
static struct snd_soc_ops aif1_ops = { static const struct snd_soc_ops aif1_ops = {
.startup = aif1_startup, .startup = aif1_startup,
}; };
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册