diff options
author | Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> | 2018-01-29 03:43:45 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2018-02-12 12:45:15 +0100 |
commit | be3eabe99803b2526f8829b7c7225763f0703b1f (patch) | |
tree | 0a78e6ecd145a9157e6c6b38f54a4f0559d0821e /sound/soc/sh/siu_pcm.c | |
parent | ASoC: sh: fsi: replace platform to component (diff) | |
download | linux-be3eabe99803b2526f8829b7c7225763f0703b1f.tar.xz linux-be3eabe99803b2526f8829b7c7225763f0703b1f.zip |
ASoC: sh: siu: replace platform to component
Now platform can be replaced to component, let's do it.
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/sh/siu_pcm.c')
-rw-r--r-- | sound/soc/sh/siu_pcm.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/sound/soc/sh/siu_pcm.c b/sound/soc/sh/siu_pcm.c index 3118cb0ee3f2..172909570ed5 100644 --- a/sound/soc/sh/siu_pcm.c +++ b/sound/soc/sh/siu_pcm.c @@ -35,6 +35,7 @@ #include "siu.h" +#define DRV_NAME "siu-i2s" #define GET_MAX_PERIODS(buf_bytes, period_bytes) \ ((buf_bytes) / (period_bytes)) #define PERIOD_OFFSET(buf_addr, period_num, period_bytes) \ @@ -340,7 +341,8 @@ static int siu_pcm_open(struct snd_pcm_substream *ss) { /* Playback / Capture */ struct snd_soc_pcm_runtime *rtd = ss->private_data; - struct siu_platform *pdata = rtd->platform->dev->platform_data; + struct snd_soc_component *component = snd_soc_rtdcom_lookup(rtd, DRV_NAME); + struct siu_platform *pdata = component->dev->platform_data; struct siu_info *info = siu_i2s_data; struct siu_port *port_info = siu_port_info(ss); struct siu_stream *siu_stream; @@ -604,9 +606,10 @@ static const struct snd_pcm_ops siu_pcm_ops = { .pointer = siu_pcm_pointer_dma, }; -struct snd_soc_platform_driver siu_platform = { +struct snd_soc_component_driver siu_component = { + .name = DRV_NAME, .ops = &siu_pcm_ops, .pcm_new = siu_pcm_new, .pcm_free = siu_pcm_free, }; -EXPORT_SYMBOL_GPL(siu_platform); +EXPORT_SYMBOL_GPL(siu_component); |