diff options
author | Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> | 2014-01-23 21:40:03 -0500 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2014-02-03 07:41:36 -0500 |
commit | 9b5ab573a81b9ac0df90b74d732651fdf8b24525 (patch) | |
tree | 9d3a7ade932bf8b1e466e3e0dc0dc5d1c434e7e9 | |
parent | 41c6221c39accdc4fe2b0c0fa196b6302b704e57 (diff) |
ASoC: rsnd: remove duplicate *priv from rsnd_dma
*priv pointer exists under rsnd_mod,
and, it can get rsnd_mod pointer from rsnd_dma.
remove duplicate rsnd_dma :: priv
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
-rw-r--r-- | sound/soc/sh/rcar/core.c | 5 | ||||
-rw-r--r-- | sound/soc/sh/rcar/rsnd.h | 1 |
2 files changed, 2 insertions, 4 deletions
diff --git a/sound/soc/sh/rcar/core.c b/sound/soc/sh/rcar/core.c index 743de5e3b1e1..ed8611f9c64f 100644 --- a/sound/soc/sh/rcar/core.c +++ b/sound/soc/sh/rcar/core.c | |||
@@ -156,7 +156,7 @@ void rsnd_dma_stop(struct rsnd_dma *dma) | |||
156 | static void rsnd_dma_complete(void *data) | 156 | static void rsnd_dma_complete(void *data) |
157 | { | 157 | { |
158 | struct rsnd_dma *dma = (struct rsnd_dma *)data; | 158 | struct rsnd_dma *dma = (struct rsnd_dma *)data; |
159 | struct rsnd_priv *priv = dma->priv; | 159 | struct rsnd_priv *priv = rsnd_mod_to_priv(rsnd_dma_to_mod(dma)); |
160 | unsigned long flags; | 160 | unsigned long flags; |
161 | 161 | ||
162 | rsnd_lock(priv, flags); | 162 | rsnd_lock(priv, flags); |
@@ -172,7 +172,7 @@ static void rsnd_dma_complete(void *data) | |||
172 | static void rsnd_dma_do_work(struct work_struct *work) | 172 | static void rsnd_dma_do_work(struct work_struct *work) |
173 | { | 173 | { |
174 | struct rsnd_dma *dma = container_of(work, struct rsnd_dma, work); | 174 | struct rsnd_dma *dma = container_of(work, struct rsnd_dma, work); |
175 | struct rsnd_priv *priv = dma->priv; | 175 | struct rsnd_priv *priv = rsnd_mod_to_priv(rsnd_dma_to_mod(dma)); |
176 | struct device *dev = rsnd_priv_to_dev(priv); | 176 | struct device *dev = rsnd_priv_to_dev(priv); |
177 | struct dma_async_tx_descriptor *desc; | 177 | struct dma_async_tx_descriptor *desc; |
178 | dma_addr_t buf; | 178 | dma_addr_t buf; |
@@ -246,7 +246,6 @@ int rsnd_dma_init(struct rsnd_priv *priv, struct rsnd_dma *dma, | |||
246 | goto rsnd_dma_init_err; | 246 | goto rsnd_dma_init_err; |
247 | 247 | ||
248 | dma->dir = is_play ? DMA_TO_DEVICE : DMA_FROM_DEVICE; | 248 | dma->dir = is_play ? DMA_TO_DEVICE : DMA_FROM_DEVICE; |
249 | dma->priv = priv; | ||
250 | dma->inquiry = inquiry; | 249 | dma->inquiry = inquiry; |
251 | dma->complete = complete; | 250 | dma->complete = complete; |
252 | INIT_WORK(&dma->work, rsnd_dma_do_work); | 251 | INIT_WORK(&dma->work, rsnd_dma_do_work); |
diff --git a/sound/soc/sh/rcar/rsnd.h b/sound/soc/sh/rcar/rsnd.h index e92b1f438f74..33c01fb9f5fd 100644 --- a/sound/soc/sh/rcar/rsnd.h +++ b/sound/soc/sh/rcar/rsnd.h | |||
@@ -96,7 +96,6 @@ void rsnd_bset(struct rsnd_priv *priv, struct rsnd_mod *mod, enum rsnd_reg reg, | |||
96 | * R-Car DMA | 96 | * R-Car DMA |
97 | */ | 97 | */ |
98 | struct rsnd_dma { | 98 | struct rsnd_dma { |
99 | struct rsnd_priv *priv; | ||
100 | struct sh_dmae_slave slave; | 99 | struct sh_dmae_slave slave; |
101 | struct work_struct work; | 100 | struct work_struct work; |
102 | struct dma_chan *chan; | 101 | struct dma_chan *chan; |