aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/spear/spear_pcm.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2013-12-18ASoC: SPEAr: remove custom DMA alloc compat functionStephen Warren1-14/+7
spear_pcm_request_chan() is almost identical to dmaengine_pcm_compat_request_channel(), with the exception that the latter: a) Assumes that the DAI DMA data is a struct snd_dmaengine_dai_dma_data pointer rather than some custom type. b) dma_data->filter_data rather than dma_data should be passed to snd_dmaengine_pcm_request_channel() as the filter data. Make minor changes to the SPEAr DAI drivers so that those two conditions are met. This allows removal of the custom .compat_request_channel(). Signed-off-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-18ASoC: SPEAr: get rid of spear-pcm-audio struct deviceStephen Warren1-14/+4
Modify the SPEAr PCM driver so that it's a utility library that can be registered on each DAI, rather than a separate struct device. This is more in line with how many recent DT-converted platforms operate, and avoids the need for yet another struct device. This is also required as a pre-cursor to removing spear_pcm_request_chan(). Signed-off-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-11-28ASoC: spear: Use devm_snd_dmaengine_pcm_registerLars-Peter Clausen1-8/+1
Makes the code slightly shorter. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Rajeev Kumar <rajeev-dlh.kumar@st.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-05-12ASoC: spear: Use generic dmaengine PCMLars-Peter Clausen1-137/+15
Use the generic dmaengine PCM driver instead of a custom implementation. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-18Merge tag 'asoc-v3.10-2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-nextTakashi Iwai1-2/+3
ASoC: More updates for v3.10 The main additional change here is Lars-Peter's DMA work plus the platform conversions which have been tested - getting this in mainline will make life easier for development after the merge window. These factor a large chunk of code out of the drivers for the platforms using dmaengine, greatly simplifying development.
2013-04-17Merge tag 'v3.9-rc7' into asoc-dmaMark Brown1-6/+6
Linux 3.9-rc7
2013-04-17ASoC: dmaengine-pcm: Make requesting the DMA channel at PCM open optionalLars-Peter Clausen1-2/+3
Refactor the dmaengine PCM library to allow the DMA channel to be requested before opening a PCM substream. snd_dmaengine_pcm_open() now expects a DMA channel instead of a filter function and filter parameter as its parameters. snd_dmaengine_pcm_close() is updated to not release the DMA channel. This allows a dmaengine based PCM driver to request its channels before the substream is opened. The patch also introduces two new functions, snd_dmaengine_pcm_open_request_chan() and snd_dmaengine_pcm_close_release_chan(), which have the same signature and behaviour of the old snd_dmaengine_pcm_{open,close}() and internally use the new variants of these functions. All users of snd_dmaengine_pcm_{open,close}() are updated to use snd_dmaengine_pcm_open_request_chan() and snd_dmaengine_pcm_close_release_chan(). Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Tested-by: Stephen Warren <swarren@nvidia.com> Tested-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-12Merge remote-tracking branch 'asoc/topic/spear' into asoc-nextMark Brown1-2/+2
2013-04-12Merge remote-tracking branch 'asoc/topic/dma' into asoc-nextMark Brown1-16/+2
2013-03-26ASoC: speaer_pcm: No need to use snd_dmaengine_pcm_set_data()Lars-Peter Clausen1-7/+1
The driver never uses snd_dmaengine_pcm_get_data(), so there is no need to use snd_dmaengine_pcm_set_data(). Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Rajeev Kumar <rajeev-dlh.kumar@st.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-26ASoC: spear_pcm: No need to wrap snd_dmaengine_pcm_close()Lars-Peter Clausen1-9/+1
If a PCM driver using the dmaengine PCM helper functions doesn't need to do anything special in its pcm_close callback, snd_dmaengine_pcm_close can be used directly for as the pcm_close callback and there is no need to wrap it in a custom function. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Rajeev Kumar <rajeev-dlh.kumar@st.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-20ASoC: spear_pcm: Staticize non-exported structsLars-Peter Clausen1-2/+2
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Rajeev Kumar <rajeev-dlh.kumar@st.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-03-20ASoC: spear_pcm: Update to new pcm_new() APILars-Peter Clausen1-6/+6
Commit 552d1ef6 ("ASoC: core - Optimise and refactor pcm_new() to pass only rtd") updated the pcm_new() callback to take the rtd as the only parameter. The spear PCM driver (which was merged much later) still uses the old API. This patch updates the driver to the new API. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Rajeev Kumar <rajeev-dlh.kumar@st.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: stable@vger.kernel.org
2012-12-10ASoC: spear: remove __dev* attributesBill Pemberton1-3/+3
CONFIG_HOTPLUG is going away as an option. As result the __dev* markings will be going away. Remove use of __devinit, __devexit_p, __devinitdata, __devinitconst, and __devexit. Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-08-31ASoC: spear: correct the check for NULL dma_buffer pointerPrasad Joshi1-1/+1
The if condition if (!buf && !buf->area) checks if the buf pointer is NULL and then dereferences it again to check if the buffer area is NULL, resulting in possible NULL dereference. Signed-off-by: Prasad Joshi <prasadjoshi.linux@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-06-22ASoC: Add support for SPEAr ASoC pcm layer.Rajeev Kumar1-0/+214
This patch add support for the SPEAr ASoC pcm layer in ASoC framework. The pcm layer uses common snd_dmaengine framework. Signed-off-by: Rajeev Kumar <rajeev-dlh.kumar@st.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>