aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/sh/rcar
Commit message (Collapse)AuthorAge
...
| * ASoC: rsnd: share reg_field and reduce memoryKuninori Morimoto2014-03-03
| | | | | | | | | | | | | | | | | | Gen1/Gen2 code never be used in same time. Thus, driver can share Gen1 only register and Gen2 only register. It can reduce memory too. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: modify rsnd_adg_ssi_ws_timing_gen2() parameterKuninori Morimoto2014-03-03
| | | | | | | | | | | | | | | | | | | | rsnd_adg_ssi_ws_timing_gen2() returns SSI WS timing, and it used "mod" as parameter. but, this "mod" is sometimes not ssi mod. Get SSI mod from rsnd_dai_stream Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: remove unused SSI_CONTROLKuninori Morimoto2014-03-03
| | | | | | | | | | Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: use function pointer for each probeKuninori Morimoto2014-03-03
| | | | | | | | | | | | | | | | | | R-Car sound consists of many devices. It will have more device support in the future. Thus, for each probe become now function pointer array. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: use devm_clk_get() instead of clk_get()Kuninori Morimoto2014-03-03
| | | | | | | | | | Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: get ssi/scu from rsnd_dai_streamKuninori Morimoto2014-03-03
| | | | | | | | | | | | | | | | | | Current driver is assuming that SSI id = SCU id. But, now, it can get correct SSI/SCU from rsnd_dai_stream. use it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: use mod array instead of list on rdaiKuninori Morimoto2014-03-03
| | | | | | | | | | | | | | | | | | | | struct rsnd_dai_stream used list for mod list. It added only odd flexibility to current driver, and it is a factor which makes extendibility difficult. rsnd use mod array instead of list from now. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: run rsnd_path_init() when probe() timingKuninori Morimoto2014-03-03
| | | | | | | | | | | | | | | | | | | | | | Current rsnd SSIU/SSI/SCU/SRU path is set when playback/capture starts up. But it is meaningless method, since the path is based on platform and can be set in probe() timing. This patch sets the path on probe() timing. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: unify rdai namingKuninori Morimoto2014-03-02
| | | | | | | | | | | | | | | | | | struct rsnd_dai is called as "rdai", but its size has been called as "dai_nr". Unify these as "rdai" Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: remove verbose debug message from scu/ssiKuninori Morimoto2014-03-02
| | | | | | | | | | | | | | scu/ssi probe() already have more detail debug message. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: remove verbose function parameterKuninori Morimoto2014-03-02
| | | | | | | | | | | | | | | | priv has rcar_snd_info pointer. having priv and info in same time is verbose. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: move rsnd_mod_call() macroKuninori Morimoto2014-03-02
| | | | | | | | | | | | | | | | core.c is the only user of rsnd_mod_call() macro. Move it to core.c from rsnd.h Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: move priv member settings to upper sideKuninori Morimoto2014-03-02
| | | | | | | | | | | | | | There is no big meaning, but preparation for platform dai support Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: print error if there is SRC settings mismatchKuninori Morimoto2014-02-12
| | | | | | | | | | | | | | rsnd request clock master if SRC is used Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: set DIV_EN register on rsnd_adg_set_convert_clk_gen2()Kuninori Morimoto2014-02-12
| | | | | | | | | | | | | | DIV_EN register enable bit is required when you use Gen2 SRC Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: tidyup original for_each_rsnd_xxx macroKuninori Morimoto2014-02-12
| | | | | | | | | | | | | | | | | | | | | | Current for_each_rsnd_xxx macro will read out-of-array's memory after last loop operation. It was not good C language operation, and the binary which was compiled by (at least) gcc 4.8.1 is broken This patch tidyup these issues Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: use device dependency clockKuninori Morimoto2014-02-07
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Current R-Car sound driver is using device independent audio clock, but it is not good design for DT support. This patch adds device dependent clock support. But, there are some platform which is using independent audio clock. It is still supported at this point, but it will be removed soon. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: add Gen2 SRC and DMAEngine supportKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Renesas sound Gen2 has SRC (= Sampling Rate Converter) which needs 2 DMAC. The data path image when you use SRC on Gen2 is [mem] -> Audio-DMAC -> SRC -> Audio-DMAC-peri-peri -> SSIU -> SSI This patch support SRC and DMAEnine. It is tested on R-Car H2 Lager board Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: rsnd_ssi_probe() goes forwarder than rsnd_scu_probe()Kuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | rsnd_ssi_probe() goes forwarder than rsnd_scu_probe(), since scu will need ssi information on Gen2 Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: remove SSI dependent DMAEngine callbackKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | | | | | | | | | Renesas Gen2 sound will use 2 DMAC which are Audio-DMAC, and Audio-DMAC-peri-peri. Current driver has callback function for each DMAC, because it assumed each DMAC needs special settings. But it became clear that these can share settings. This patch removes unnecessary callback Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: extracts Gen1/Gen2 common partsKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | | | | | | | | | | | Renesas sound IP Gen1/Gen2 are similar, but different. This patch extracts Gen1/Gen2 common and dependency parts, and create Gen1/Gen2 ops to control it. According to this structure, SSIU setup which has been implemented on ssi.c can be moved to scu.c (SRU/SSIU/SCU should be implemented on scu.c) Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: add rsnd_ssi_is_play()Kuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | SCU needs SSI direction if Gen2. Add rsnd_ssi_is_play() function for it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: merge SRC clock timing/settingKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | | | | | | | | | | | SRC clock and timing setting register exist in SRU and ADG on Gen1. But, these are merged into ADG on Gen2. Current driver is supporting Gen1 SRC only at this point, but, above settings are set as different function. This patch merges these as preparation of Gen2 support. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: rsnd_scu_hpbif_is_enable() become macroKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | rsnd_scu_hpbif_is_enable() is used only scu.c now. It can be local macro Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: Merge macros in scu.cKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | Merge #define lines, since these are defined in the scattering place Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: clarify scu.c areaKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | scu.c cares SRU(Gen1) / SCU(Gen2) / SSIU(Gen2) Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: SCU should be called before SSIKuninori Morimoto2014-02-03
| | | | | | | | | | Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: don't use schedule_work() when rsnd_dma_start()Kuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | | | | | rsnd_dma_start() is the function to start DMAEngine. Current code is using schedule_work() for it, but it breaks DMAC/SSI register setting timing. Don't use schedule_work() on it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: fixup Gen2 module namingKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | Gen2 has SCU, not SRU Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: non 0 is error on probeKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | Some xxx_probe() returns not only -Exx, but also PTR_ERR(). Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: remove duplicate *priv from rsnd_dmaKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | | | *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>
| * ASoC: rsnd: explain SRC bypass mode settings in commentKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | SRC bypass mode is useful for debugging. This patch explains SRC bypass mode settings in comment Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: rename rsnd_scu_convert_rate_ctrl()Kuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | | | | | rsnd_scu_convert_rate_ctrl() is unclear naming, and there is "rsnd_scu_convert_rate" variable. These are confusable. it renamed to rsnd_scu_set_convert_rate() Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: remove ssiu from ssi.cKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | Now, SSI_MODE0/1 are controlled under scu.c ssiu is no longer needed on ssi.c Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: SSI_MODE0/1 settings goes to scu.cKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | | | | | | | | | SRU (Gen1) / SCU (Gen2) / SSIU (Gen2) are controlled under scu.c. (SCU + SSIU (Gen2) was SRU (Gen1)) And register of SSI_MODE0/1 are mapped on these IP. But these have been implemented under ssi.c on this driver. The naming is very confusable, but it should be implemented under scu.c Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: remove pin sync optionKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | | | | | Renesas Chip is supporting multi pin sound, but the HW setting is very difficult and confusable. But driver is supporting it halfway. Remove SYNC option at this point. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: rsnd_dai_is_clk_master() can be sharedKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | | | Current rsnd driver is using ssi local rsnd_rdai_is_clk_master() for checking clock master. But it can be rsnd_dai_is_clk_master(), and share in each file Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: merge rsnd_scu_start/stop() and rsnd_scu_transfer_start/stop()Kuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | rsnd_scu_transfer_start/stop() are no longer needed. merge into rsnd_scu_start/stop() Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: remove meaningless function parameterKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | struct rsnd_priv *priv on rsnd_scu_init/start/stop() are no longer needed Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: add rsnd_scu_init(), and separate init/startKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | | | | | | | Current scu.c has rsnd_scu_start(), and, operation of initialization/start are implemented in this function. This patch adds new rsnd_scu_init() and separates rsnd_scu_start(), since rsnd_mod_ops has .init/.start callbacks. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: control SCU ops in probe timingKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | | | | | SCU will be used if platform requested to use. Current driver is checking it in runtime, but, it can be decided in probe timing. This patch do it Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: remove meaningless rsnd_ssi_non()Kuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | rsnd_ssi_non_ops callback functions are never called. remove these meaningless callback Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: cleanup debug information methodKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | | | | | | | rsnd_mod debug information is implemented in each callback functions now. But, it can be implemented in rsnd_mod_call(), and share this code. This patch adds it Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: tidyup register naming of BUSIF_MODEKuninori Morimoto2014-02-03
| | | | | | | | | | | | | | | | | | Gen1:SRU has only 1 BUSIF_MODE, but Gen2:SSIU/SCU has SRCm_BUSIF_MODE, and SSIn_BUSIF_MODE. This patch rename current BUSIF_MODE to SRC_BUSIF_MODE. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
* | ASoC: rcar: fixup SND_SOC_DAIFMT_CBx_CFx flagsKuninori Morimoto2014-03-14
|/ | | | | | | | SND_SOC_DAIFMT_CBx_CFx means "codec" side master/slave mode. Then, rcar will be master mode if it was SND_SOC_DAIFMT_CBS_CFS. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
*-. Merge remote-tracking branches 'asoc/topic/adsp', 'asoc/topic/atmel', ↵Mark Brown2014-01-16
|\ \ | | | | | | | | | 'asoc/topic/bcm2835', 'asoc/topic/docs', 'asoc/topic/fsl', 'asoc/topic/generic', 'asoc/topic/kirkwood', 'asoc/topic/mc13783', 'asoc/topic/mxs', 'asoc/topic/nuc900', 'asoc/topic/sai', 'asoc/topic/sh', 'asoc/topic/ssm2602', 'asoc/topic/tlv320aic3x', 'asoc/topic/twl4030', 'asoc/topic/ux500', 'asoc/topic/width' and 'asoc/topic/x86' into for-tiwai
| | * ASoC: sh: Don't set unused struct snd_pcm_hardware fieldsLars-Peter Clausen2014-01-09
| |/ | | | | | | | | | | | | | | | | | | | | The ASoC core assumes that the PCM component of the ASoC card transparently moves data around and does not impose any restrictions on the memory layout or the transfer speed. It ignores all fields from the snd_pcm_hardware struct for the PCM driver that are related to this. Setting these fields in the PCM driver might suggest otherwise though, so rather not set them. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Mark Brown <broonie@linaro.org>
* | Merge remote-tracking branches 'asoc/topic/ad1836', 'asoc/topic/ad193x', ↵Mark Brown2014-01-02
|\ \ | |/ |/| | | 'asoc/topic/adav80x', 'asoc/topic/adsp', 'asoc/topic/ak4641', 'asoc/topic/ak4642', 'asoc/topic/arizona', 'asoc/topic/atmel', 'asoc/topic/au1x', 'asoc/topic/axi', 'asoc/topic/bcm2835', 'asoc/topic/blackfin', 'asoc/topic/cs4271', 'asoc/topic/cs42l52', 'asoc/topic/da7210', 'asoc/topic/davinci', 'asoc/topic/ep93xx', 'asoc/topic/fsl', 'asoc/topic/fsl-mxs', 'asoc/topic/generic', 'asoc/topic/hdmi', 'asoc/topic/jack', 'asoc/topic/jz4740', 'asoc/topic/max98090', 'asoc/topic/mxs', 'asoc/topic/omap', 'asoc/topic/pxa', 'asoc/topic/rcar', 'asoc/topic/s6000', 'asoc/topic/sai', 'asoc/topic/samsung', 'asoc/topic/sgtl5000', 'asoc/topic/spear', 'asoc/topic/ssm2518', 'asoc/topic/ssm2602', 'asoc/topic/tegra', 'asoc/topic/tlv320aic3x', 'asoc/topic/twl6040', 'asoc/topic/txx9', 'asoc/topic/uda1380', 'asoc/topic/width', 'asoc/topic/wm8510', 'asoc/topic/wm8523', 'asoc/topic/wm8580', 'asoc/topic/wm8711', 'asoc/topic/wm8728', 'asoc/topic/wm8731', 'asoc/topic/wm8741', 'asoc/topic/wm8750', 'asoc/topic/wm8753', 'asoc/topic/wm8776', 'asoc/topic/wm8804', 'asoc/topic/wm8900', 'asoc/topic/wm8901', 'asoc/topic/wm8940', 'asoc/topic/wm8962', 'asoc/topic/wm8974', 'asoc/topic/wm8985', 'asoc/topic/wm8988', 'asoc/topic/wm8990', 'asoc/topic/wm8991', 'asoc/topic/wm8994', 'asoc/topic/wm8995', 'asoc/topic/wm9081' and 'asoc/topic/x86' into asoc-next
| * ASoC: rsnd: add SRC (Sampling Rate Converter) supportKuninori Morimoto2013-12-31
| | | | | | | | | | | | | | | | | | | | | | | | This patch adds SRC support to Renesas sound driver. SRC converts sampling rate between codec <-> cpu. It needs special codec chip, or very simple DA/AD converter to use it. This patch was tested via ak4554 codec, and supports Gen1 only at this point. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>
| * ASoC: rsnd: tidyup rsnd_ssi_master_clk_start() parameterKuninori Morimoto2013-12-31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Renesas sound has SRC (= Sampling Rate Converter), but, the HW implementation depends on its generation. It was part of SRU on Gen1, and SCU on Gen2. This SCU needs DMA transfer to use it. Current rsnd driver is using it as DMA transfer buffer (= no rate convert), and Gen1 is only supported at this point. This patch cleanup it with focusing about SRC and Gen2 part. ssi clock which is calculated from rsnd_ssi_master_clk_start() should have flexibility since Renesas sound has SRC (= Sampling Rate Converter). But current implementation is using runtime->rate directly. This patch tidyup rsnd_ssi_master_clk_start() parameter as preparation of future SRC support Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@linaro.org>