summaryrefslogtreecommitdiffstats
path: root/sound/soc/ux500/ux500_msp_i2s.c
AgeCommit message (Collapse)AuthorFilesLines
2022-06-06ASoC: ux500: Remove some leftover from the "Replace GPLv2 ↵Christophe JAILLET1-2/+0
boilerplate/reference with SPDX" rules The "Replace GPLv2 boilerplate/reference with SPDX" has left some empty "License terms" paragraphs. Remove them as well. Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr> Link: https://lore.kernel.org/r/84d94977c57deee9e85249f18394ebf8d72497bc.1653724723.git.christophe.jaillet@wanadoo.fr Signed-off-by: Mark Brown <broonie@kernel.org>
2020-07-10ASoC: ux500: ux500_msp_i2s: Remove unused variables 'reg_val_DR' and ↵Lee Jones1-4/+4
'reg_val_TSTDR' Looks like these have been unchecked since the driver's inception in 2012. Fixes the following W=1 kernel build warning(s): sound/soc/ux500/ux500_msp_i2s.c: In function ‘flush_fifo_rx’: sound/soc/ux500/ux500_msp_i2s.c:398:6: warning: variable ‘reg_val_DR’ set but not used [-Wunused-but-set-variable] sound/soc/ux500/ux500_msp_i2s.c: In function ‘flush_fifo_tx’: sound/soc/ux500/ux500_msp_i2s.c:415:6: warning: variable ‘reg_val_TSTDR’ set but not used [-Wunused-but-set-variable] Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Cc: zhong jiang <zhongjiang@huawei.com> Cc: Ola Lilja <ola.o.lilja@stericsson.com> Cc: Roger Nilsson <roger.xr.nilsson@stericsson.com> Cc: Sandeep Kaushik <sandeep.kaushik@st.com> Link: https://lore.kernel.org/r/20200709162328.259586-7-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2019-11-04ASoC: ux500: Remove redundant variable "status"zhong jiang1-2/+1
local variable "status" is not used. hence it is safe to remove and just return 0. Signed-off-by: zhong jiang <zhongjiang@huawei.com> Link: https://lore.kernel.org/r/1572528855-25990-1-git-send-email-zhongjiang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-19treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500Thomas Gleixner1-4/+1
Based on 2 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms of the gnu general public license version 2 as published by the free software foundation this program is free software you can redistribute it and or modify it under the terms of the gnu general public license version 2 as published by the free software foundation # extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 4122 file(s). Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Enrico Weigelt <info@metux.net> Reviewed-by: Kate Stewart <kstewart@linuxfoundation.org> Reviewed-by: Allison Randal <allison@lohutok.net> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190604081206.933168790@linutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-03-07ASoC: ux500: Remove unuseful break after returnCodrut Grosu1-1/+0
This was reported by checkpatch.pl Signed-off-by: Codrut GROSU <codrut.cristian.grosu@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2014-01-08ASoC: ux500: Fix sparse non static symbol warningWei Yongjun1-3/+3
Fixes the following sparse warning: sound/soc/ux500/ux500_msp_i2s.c:649:5: warning: symbol 'ux500_msp_i2s_of_init_msp' was not declared. Should it be static? Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Acked-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-01-07ASoC: ux500_pcm: Extend Device Tree support to deal with DMA dataLee Jones1-15/+41
Soon we will strip out pdata support from the Ux500 set of ASoC drivers. When this happens it will have to supply a DMA slave_config to the dmaengine. At the moment a great deal of this comes from pdata via AUXDATA. We need to become independent of this soon. This patch starts the process by allocating memory for the associated data structures and fetches the MSP id used for const struct indexing. Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-06-12ASoC: ux500: Set DMA address during device initFabio Baltieri1-0/+3
Add a field with the tx/rx register address to the DMA parameters structure, and set it to the correct address during device initialization. This address used to be hardcoded in the DMA controller driver, it now needs to be explicitly figured out by the device driver. Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Acked-by: Linus Walleij <linus.walleij@linaro.org> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-06-12ASoC: ux500: Move DMA parameters into ux500_mspFabio Baltieri1-4/+6
Move struct ux500_msp_dma_params declaration from ux500_msp_i2s_drvdata to ux500_msp, this saves some confusing pointer passing and allows to access all DMA configuration fields from ux500_msp_i2s. Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Acked-by: Linus Walleij <linus.walleij@linaro.org> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-05-25ASoC: ux500: Drop dangling struct i2s_controllerFabio Baltieri1-19/+0
Drop struct i2s_controller from the ux500 ASoC driver as right now it is instantiated but not used anywhere. Also drop a mismatched device_unregister in the process. Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-05-25ASoC: ux500: Drop pinctrl sleep supportFabio Baltieri1-54/+2
Drop pinctrl default/sleep state switching code, as it was breaking the capture interface by putting the I2S pins in hi-z mode regardless of its usage status, and not giving any real benefit. Pinctrl default mode configuration is already managed automatically by a specific pinctrl hog. Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2013-04-08ARM: ux500: get rid of <mach/[hardware|db8500-regs].h>Linus Walleij1-2/+0
This removes <mach/hardware.h> and <mach/db8500-regs.h> from the Ux500, merging them into the local include "db8500-regs.h" in mach-ux500. There is some impact outside the ux500 machine, but most of it is dealt with in earlier patches. Contains portions of a clean-up patch from Arnd Bergmann. Cc: Samuel Ortiz <sameo@linux.intel.com> Cc: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Mike Turquette <mturquette@linaro.org> Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2013-04-08ARM: ux500: move mach/msp.h to <linux/platform_data/*>Arnd Bergmann1-1/+1
This header file only contains platform data structure definitions, so it's straightforward to move. Signed-off-by: Arnd Bergmann <arnd@arndb.de> [Delete one include rather than move it] Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2012-10-16ASoC: ux500_msp_i2s: Fix devm_* and return code merge errorLee Jones1-5/+3
Some ux500_msp_i2s patches clashed with: b18e93a493626c1446f9788ebd5844d008bbf71c ASoC: ux500_msp_i2s: better use devm functions and fix error return code ... leaving the driver uncompilable. This patch fixes the issues encountered. Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-09-22Merge remote-tracking branch 'asoc/topic/ux500' into for-3.7Mark Brown1-19/+70
2012-09-22Merge tag 'v3.6-rc6' into for-3.7Mark Brown1-20/+5
Linux 3.6-rc6 has all our bug fixes. Conflicts (trivial overlap): sound/soc/omap/am3517evm.c
2012-09-20ASoC: Ux500: Enable ux500 MSP driver for Device TreeLee Jones1-3/+19
Register both parts of the MSP driver from Device Tree so that they are probed when Device Tree is enabled. Also, as there is platform data involved, we ensure that there is allocated memory to place the configuration into and that the correct information is extracted from the DT binary. Acked-by: Ola Lilja <ola.o.lilja@stericsson.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org>
2012-09-20ASoC: Ux500: Move MSP pinctrl setup into the MSP driverLee Jones1-16/+51
In the initial submission of the MSP driver msp1 and msp3's associated pinctrl mechanism was passed back to platform code using a plat_init() call-back routine, but it has no place in platform code. The MSP driver should set this up for the appropriate ports. Instead we use a use_pinctrl identifier which is passed from platform_data/Device Tree which indicates which ports should use pinctrl. Acked-by: Ola Lilja <ola.o.lilja@stericsson.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org>
2012-08-20ASoC: ux500_msp_i2s: better use devm functions and fix error return codeJulia Lawall1-20/+5
Remove unnecessary calls to devm_kfree and replace iounmap by devm_iounmap (and use resource_size for the third argument). These changes make it possible to remove the error-handling code at the end of ux500_msp_i2s_init_msp, and all of the gotos become direct returns. In the case of the second call to devm_kzalloc, the return variable ret was not initialized. Here it is changed to a direct return of -ENOMEM. A simplified version of the semantic match that finds the second problem is as follows: (http://coccinelle.lip6.fr/) // <smpl> ( if@p1 (\(ret < 0\|ret != 0\)) { ... return ret; } | ret@p1 = 0 ) ... when != ret = e1 when != &ret *if(...) { ... when != ret = e2 when forall return ret; } // </smpl> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-08-03ASoC: ux500: Strengthen error checking after memory allocationLee Jones1-0/+2
Currently there is no out-of-memory error checking after attempting to allocate memory for the ux500_msp or ux500_msp_i2s_drvdata data structures. Instead we go about populating them regardless. This patch applies the necessary error checking to prevent a panic. Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-07-26ASoC: ux500: Include the correct header filesLee Jones1-1/+1
Thought to be another merge error, board-mop500-msp.h has never existed in the upstream kernel, only msp.h. This patch changes the include files to match the existing file name. Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-06-13ASoC: Ux500: Correct license stringsOla Lilja1-1/+1
GPLv2 -> GPL v2 Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Ola Lilja <ola.o.lilja@stericsson.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-05-09ASoC: Ux500: Add MSP I2S-driverOla Lilja1-0/+742
Add driver for running I2S with the MSP-block. Signed-off-by: Ola Lilja <ola.o.lilja@stericsson.com> [Fixed trailing whitespace -- broonie] Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>