aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorArvind Yadav <arvind.yadav.cs@gmail.com>2017-08-14 01:56:26 -0400
committerMark Brown <broonie@kernel.org>2017-08-14 12:17:53 -0400
commitb6ed072028705620ea2937ddafd77a202df034af (patch)
tree417e93f9ed792a145da0a1147e2d9caba04e50a9
parent06d15a2ede999a77f0d05aa600ed473d90d9a909 (diff)
ASoC: fsl: constify snd_pcm_ops structures
snd_pcm_ops are not supposed to change at runtime. All functions working with snd_pcm_ops provided by <sound/soc.h> work with const snd_pcm_ops. So mark the non-const structs as const. Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r--sound/soc/fsl/fsl_dma.c2
-rw-r--r--sound/soc/fsl/imx-pcm-fiq.c2
-rw-r--r--sound/soc/fsl/mpc5200_dma.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/sound/soc/fsl/fsl_dma.c b/sound/soc/fsl/fsl_dma.c
index ed8ea002902d..979ed1b3ecc4 100644
--- a/sound/soc/fsl/fsl_dma.c
+++ b/sound/soc/fsl/fsl_dma.c
@@ -870,7 +870,7 @@ static struct device_node *find_ssi_node(struct device_node *dma_channel_np)
870 return NULL; 870 return NULL;
871} 871}
872 872
873static struct snd_pcm_ops fsl_dma_ops = { 873static const struct snd_pcm_ops fsl_dma_ops = {
874 .open = fsl_dma_open, 874 .open = fsl_dma_open,
875 .close = fsl_dma_close, 875 .close = fsl_dma_close,
876 .ioctl = snd_pcm_lib_ioctl, 876 .ioctl = snd_pcm_lib_ioctl,
diff --git a/sound/soc/fsl/imx-pcm-fiq.c b/sound/soc/fsl/imx-pcm-fiq.c
index 92410f7ca1fa..9ce37616ef5d 100644
--- a/sound/soc/fsl/imx-pcm-fiq.c
+++ b/sound/soc/fsl/imx-pcm-fiq.c
@@ -227,7 +227,7 @@ static int snd_imx_pcm_mmap(struct snd_pcm_substream *substream,
227 return ret; 227 return ret;
228} 228}
229 229
230static struct snd_pcm_ops imx_pcm_ops = { 230static const struct snd_pcm_ops imx_pcm_ops = {
231 .open = snd_imx_open, 231 .open = snd_imx_open,
232 .close = snd_imx_close, 232 .close = snd_imx_close,
233 .ioctl = snd_pcm_lib_ioctl, 233 .ioctl = snd_pcm_lib_ioctl,
diff --git a/sound/soc/fsl/mpc5200_dma.c b/sound/soc/fsl/mpc5200_dma.c
index 1f7e70bfbd55..66042ce86edc 100644
--- a/sound/soc/fsl/mpc5200_dma.c
+++ b/sound/soc/fsl/mpc5200_dma.c
@@ -287,7 +287,7 @@ psc_dma_hw_params(struct snd_pcm_substream *substream,
287 return 0; 287 return 0;
288} 288}
289 289
290static struct snd_pcm_ops psc_dma_ops = { 290static const struct snd_pcm_ops psc_dma_ops = {
291 .open = psc_dma_open, 291 .open = psc_dma_open,
292 .close = psc_dma_close, 292 .close = psc_dma_close,
293 .hw_free = psc_dma_hw_free, 293 .hw_free = psc_dma_hw_free,