Skip to content

Commit ab85c44

Browse files
krzkbroonie
authored andcommitted
ASoC: SOF: imx8: Constify snd_sof_dsp_ops
'struct snd_sof_dsp_ops' is not modified by core code, so it can be made const for increased code safety. Tested-by: Pierre-Louis Bossart <[email protected]> Signed-off-by: Krzysztof Kozlowski <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
1 parent 04f2f51 commit ab85c44

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sound/soc/sof/imx/imx8.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -478,7 +478,7 @@ static int imx8_dsp_set_power_state(struct snd_sof_dev *sdev,
478478
}
479479

480480
/* i.MX8 ops */
481-
static struct snd_sof_dsp_ops sof_imx8_ops = {
481+
static const struct snd_sof_dsp_ops sof_imx8_ops = {
482482
/* probe and remove */
483483
.probe = imx8_probe,
484484
.remove = imx8_remove,
@@ -539,7 +539,7 @@ static struct snd_sof_dsp_ops sof_imx8_ops = {
539539
};
540540

541541
/* i.MX8X ops */
542-
static struct snd_sof_dsp_ops sof_imx8x_ops = {
542+
static const struct snd_sof_dsp_ops sof_imx8x_ops = {
543543
/* probe and remove */
544544
.probe = imx8_probe,
545545
.remove = imx8_remove,

0 commit comments

Comments
 (0)