aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2017-06-14ASoC: rsnd: reduce confusable macro parameter magicKuninori Morimoto1-2/+3
rsnd_dai_call() macro is using "priv" inside. Thus, if caller function doesn't have "priv" related operation, strange phenomenon occur which code is using "priv", but compiler indicates "unused variable 'priv'". >From code point of view, it is not problem, but it is very confusable. This patch removes "priv" from rsnd_dai_call() macro, and adds "priv" on caller function. Signed-off-by: Kuninori Morimoto <[email protected]> Tested-by: Hiroyuki Yokoyama <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-06-13ASoC: rsnd: control kctrl items acceptance anytime/runtimeKuninori Morimoto5-6/+40
Current SRC/DVC/CTU adds kctrl for each device, and SRC can adjust its sampling rate during playback, thus, this feature should be enabled only *during* playback. This patch controls it more clearly Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-06-13ASoC: rsnd: add detail explanation of L/R conversion timingKuninori Morimoto1-0/+18
Renesas Sound device *Hardware* L/R and Linux *Software* L/R are inverted. Because of this background, it needs to convert L/R. Then, DVC needs *Hardware* L/R, and Linux needs *Software* L/R. Because Playback/Capture needs different timing, and there is no explanation about it on source code / git log, this patch adds it. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-06-07ASoC: rsnd: cleanup pointer related codeKuninori Morimoto4-56/+65
Current rsnd driver is sharing pointer related code between PIO / DMA. But, it is used only PIO mode now, no longer needed. This patch cleanup these. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-06-07Merge branch 'fix/rcar' of ↵Mark Brown8-8/+86
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into asoc-rcar
2017-06-07ASoC: rsnd: update pointer more accurateKuninori Morimoto4-3/+48
Current rsnd driver updates pointer when DMA transfer was finished in DMA transfer mode. But PulseAudio requests more accurate pointer update when timer mode. This patch consider about DMA transfer residue and update more accurate pointer. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-06-07ASoC: simple-scu-card: remove duplicate paramera from asoc_simple_card_parse_ofKuninori Morimoto1-3/+3
Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-06-06ASoC: rsnd: Document optional reset propertiesGeert Uytterhoeven1-0/+3
Document the optional properties for describing module resets, to support resetting these modules on R-Car Gen2 and Gen3. Note that the audio module has resets for the Serial Sound Interfaces only. Signed-off-by: Geert Uytterhoeven <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-06-06ASoC: simple-card-utils: share same dev_dbg() for sysclkKuninori Morimoto6-28/+10
Let's share same debug message for sysclk Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-06-06ASoC: simple-card-utils: share same dev_dbg() for Dai NameKuninori Morimoto3-2/+2
Let's share same debug message for DAI Name Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-06-06ASoC: simple-card-utils: share same dev_dbg() for DAI formatKuninori Morimoto3-2/+2
Let's share same debug message for DAI format Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-06-06ASoC: simple-card-utils: share same dev_dbg() for Card NameKuninori Morimoto3-4/+2
Let's share same debug message for Card Name Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-06-06ASoC: audio-graph-scu-card: add missing MIX binding exampleKuninori Morimoto1-1/+46
Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-06-06ASoC: simple-scu-card: tidyup "Sampling Rate Conversion"Kuninori Morimoto1-1/+1
"Sampling Rate Conversion" is better than "Sampling Rate Convert" Reported-by: James Cameron <[email protected]> Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-06-06ASoC: rsnd: remove unused rsnd_dai_path_infoKuninori Morimoto1-1/+0
commit 2ea2cc86db7c ("ASoC: rsnd: remove struct rcar_snd_info") removed all struct rsnd_dai_path_info related code. This patch removes unused rsnd_dai_path_info. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-06-06ASoC: rsnd: remove unused rsnd_ssi_non_opsKuninori Morimoto1-8/+0
rsnd_ssi_non_ops is never used. Let's remove it Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-29ASoC: audio-graph-scu-card: tidyup return method from probe()Kuninori Morimoto1-2/+4
Current return method from probe() is very confusable. This patch tidyup it to normal return method Reported-by: Dan Carpenter <[email protected]> Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-29ASoC: add audio-graph-scu-card supportKuninori Morimoto3-0/+427
OF-graph base DT binding is used on V4L2, and ALSA SoC is using different style of DT today. Now ALSA SoC supports simple-card driver for generic/simple sound card, and we have simple-scu-card driver for simple-card + ALSA DPCM case. In the future, V4L2 / ALSA will support HDMI, and then, DT bindings between V4L2 / ALSA should be merged. This patch adds new Audio Graph SCU Card which is OF-graph base of simple-scu-card Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-29ASoC: add audio-graph-scu-card documentKuninori Morimoto1-0/+72
Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-29Merge branch 'topic/of-graph' of ↵Mark Brown11-61/+676
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into asoc-rcar
2017-05-26ASoC: simple-card-utils: remove strict limitation of bit/frame masterKuninori Morimoto1-2/+1
Current asoc_simple_card_parse_daifmt is keeping backward compatibility for bitmaster/framemaster which didn't use phandle. The keep compatibility, it is checking prefix length, but it is too strict. let's loosen it. Otherwise, OF-graph base sound card which doesn't have prefix can't detect daifmt. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-26ASoC: rsnd: fixup parent_clk_name of AUDIO_CLKOUTxKuninori Morimoto1-2/+4
commit 25165f79adc7 ("ASoC: rsnd: enable clock-frequency for both 44.1kHz/48kHz") supported both 44.1kHz/48kHz for AUDIO_CLKOUTx, but it didn't care its parent clock name. This patch fixes it. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-24ASoC: simple-card-utils: support snd_soc_get_dai_id()Kuninori Morimoto1-0/+9
ALSA SoC needs to know connected DAI ID for detecting. It is not a big problem if device/driver was only for sound, but getting DAI ID will be difficult if device includes both Video/Sound, like HDMI. To solve this issue, this patch adds new snd_soc_get_dai_id() and its related .of_xlate_dai_id callback on component driver. In below case, we can handle Sound port (= port@2) as ID = 0 if .of_xlate_dai_id has its support. hdmi { port@0 { /* VIDEO */ }; port@1 { /* VIDEO */ }; port@2 { /* SOUND */ }; }; Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-24Merge branch 'topic/dai-id' of ↵Mark Brown2-0/+40
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into asoc-of-graph
2017-05-24ASoC: add snd_soc_get_dai_id() functionKuninori Morimoto2-0/+40
ALSA SoC needs to know connected DAI ID for detecting. It is not a big problem if device/driver was only for sound, but getting DAI ID will be difficult if device includes both Video/Sound, like HDMI. To solve this issue, this patch adds new snd_soc_get_dai_id() and its related .of_xlate_dai_id callback on component driver. In below case, we can handle Sound port (= port@2) as ID = 0 if .of_xlate_dai_id has its support. hdmi { port@0 { /* VIDEO */ }; port@1 { /* VIDEO */ }; port@2 { /* SOUND */ }; }; Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-24ASoC: rsnd: SSI PIO adjust to 24bit modeKuninori Morimoto1-2/+9
commit 90431eb49bff ("ASoC: rsnd: don't use PDTA bit for 24bit on SSI") fixups 24bit mode data alignment, but PIO was not cared. This patch fixes PIO mode 24bit data alignment Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-19ASoC: rsnd: add HDMI output supportKuninori Morimoto6-3/+112
Renesas R-Car Gen3 can output HDMI sound if SSIU/SSI are connected to R-Car built-in HDMI device (R-Car Gen3 built-in HDMI device will be controlled by DRM/KMS driver). If SSIx was connected to HDMI0/1 on DT, SSI driver will detect it automatically by this patch. Note is that now Renesas R-Car sound driver is assuming that it is using OF-graph base simple card for HDMI sound. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-19ASoC: rsnd: add support graph base DT phase 2Kuninori Morimoto1-75/+84
To enable OF-graph base DT on rsnd driver, and to keep compatible previous normal sound card style, it need to support both "rcar_sound,dai" and "ports" (or "port") on DT. This patch parses both style. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-19ASoC: rsnd: add support graph base DT phase 1Kuninori Morimoto2-2/+39
To enable OF-graph base DT on rsnd driver, and to keep compatible previous normal sound card style, it need to support both "rcar_sound,dai" and "ports" (or "port") on DT. This patch modify rsnd_dai_of_node() to parse "rcar_sound,dai" and "ports" (or "port") as phase 1. It can detect graph base style, but do nothing at this point. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-19ASoC: rsnd: don't call free_irq() on Parent SSIKuninori Morimoto1-0/+5
If SSI uses shared pin, some SSI will be used as parent SSI. Then, normal SSI's remove and Parent SSI's remove (these are same SSI) will be called when unbind or remove timing. In this case, free_irq() will be called twice. This patch solve this issue. Signed-off-by: Kuninori Morimoto <[email protected]> Tested-by: Hiroyuki Yokoyama <[email protected]> Reported-by: Hiroyuki Yokoyama <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-19ASoC: simple-scu-card: cleanup documentationKuninori Morimoto1-41/+24
simple-scu-card is almost same as simple-card. This is already explained in document. But simple-card and simple-scu-card both has same explanation for same property. This patch forward explantion to simple-card if possible to avoid duplication. This patch also cleanup DT binding example which is not good matching to simple-scu-card. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-19ASoC: audio-graph-card: fix spelling mistake: "missmatch" -> "mismatch"Colin Ian King1-1/+1
Trivial fix to spelling mistake in dev_err message Signed-off-by: Colin Ian King <[email protected]> Acked-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-19ASoC: audio-graph-card: tidyup return method from probe()Kuninori Morimoto1-2/+4
Current return method from probe() is very confusable. This patch tidyup it to normal return method Reported-by: Dan Carpenter <[email protected]> Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-19ASoC: simple-scu-card: tidyup return method from probe()Kuninori Morimoto1-2/+4
Current return method from probe() is very confusable. This patch tidyup it to normal return method Reported-by: Dan Carpenter <[email protected]> Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-19ASoC: simple-card: tidyup return method from probe()Kuninori Morimoto1-2/+4
Current return method from probe() is very confusable. This patch tidyup it to normal return method Reported-by: Dan Carpenter <[email protected]> Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17ASoC: rsnd: don't use PDTA bit for 24bit on SSIKuninori Morimoto7-4/+68
Current SSI uses PDTA bit which indicates data that Input/Output data are Right-Aligned. But, 24bit sound should be Left-Aligned in this HW. Because Linux is using Right-Aligned data, and HW uses Left-Aligned data, current 24bit data is missing lower 8bit. To fix this issue, this patch removes PDTA bit, and shift 8bit in necessary module Reported-by: Hiroyuki Yokoyama <[email protected]> Signed-off-by: Kuninori Morimoto <[email protected]> Tested-by: Hiroyuki Yokoyama <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17ASoC: rsnd: check src mod pointer for rsnd_mod_id()Kuninori Morimoto1-0/+3
Without this patch, gcc 4.9.x says sound/soc/sh/rcar/cmd.c: In function 'rsnd_cmd_init': sound/soc/sh/rcar/cmd.c:85:14: warning: array subscript is below array\ bounds [-Warray-bounds] data = path[rsnd_mod_id(src)] | Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17ASoC: rsnd: need to call nolock_stop if nolock_start was failedKuninori Morimoto1-1/+6
rsnd_dai_call() is counting the called number of start/stop functions. nolock_stop should be called if nolock_start was failed. Otherwise, nolock_start doesn't called in 2nd play. This patch solved this issue. Signed-off-by: Kuninori Morimoto <[email protected]> Reported-by: Hiroyuki Yokoyama <[email protected]> Tested-by: Hiroyuki Yokoyama <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17ASoC: rsnd: remove error pointer for adg->clkout[i]Kuninori Morimoto1-1/+0
commit d7f298197a22f11b38059f257842dac7c30a564c ("ASoC: rcar: fixup of_clk_add_provider() usage for multi clkout") added adg->clkout[i] = ERR_PTR(-ENOENT), but, adg->clkout[i] are assumed NULL or clk pointer. This patch fix it. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17ASoC: rsnd: clkout-lr-asynchronous is AUDIO_CLKOUT related propertyKuninori Morimoto1-4/+3
clkout-lr-asynchronous is AUDIO_CLKOUT related property, thus, it should be handled by rsnd_adg_get_clkout(). Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17ASoC: rsnd: remove mismatch explain comment from src.cKuninori Morimoto1-14/+0
Before, src.c cares SRC and SSIU, but now SSIU is cared by ssiu.c by commit c7f69ab5364d ("ASoC: rsnd: use mod base common method on SSIU"). This patch removes mismatched explanation for SRC/SSIU from src.c Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17ASoC: rsnd: remove un-used OUF_SRCO/I macroKuninori Morimoto1-4/+0
Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17ASoC: rsnd: add missing clocks/clock-names on DocumentKuninori Morimoto1-0/+4
Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17ASoC: rsnd: move "renesas,rsrc-card" to "simple-scu-audio-card" on DocumentKuninori Morimoto1-15/+15
"renesas,rsrc-card" is exchanged to "simple-scu-card". Let's update Document Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17ASoC: add audio-graph-card supportKuninori Morimoto3-0/+318
OF-graph base DT binding are used on V4L2, and ALSA SoC is using different style of DT today. Now ALSA SoC supports simple-card driver for generic/simple sound card. In the future, V4L2 / ALSA will support HDMI, and then, DT bindings between V4L2 / ALSA should be merged. This patch adds new Audio Graph Card which is OF-graph base of simple-card Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17ASoC: add audio-graph-card documentKuninori Morimoto1-0/+124
"Audio Graph Card" = "Simple Card" + "OF-graph" Signed-off-by: Kuninori Morimoto <[email protected]> Reviewed-by: Rob Herring <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17ASoC: simple-card-utils: add asoc_simple_card_parse_graph_dai()Kuninori Morimoto2-0/+67
simple-card already has asoc_simple_card_parse_dai(), but graph base parsing needs graph specific version of it. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17ASoC: simple-card-utils: enable "label" on asoc_simple_card_parse_card_nameKuninori Morimoto1-5/+11
Current asoc_simple_card_parse_card_name() detects [prefix]name, but in generally, we uses "label" for user visible names. This patch enables it. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17ASoC: soc-core: enable "dai-format" on snd_soc_of_parse_daifmt()Kuninori Morimoto1-3/+7
Current snd_soc_of_parse_daifmt() detects [prefix]format, but "format" was unclear in some case. This patch checks "dai-format" first, and try to check "[prefix]format" if "dai-format" was not exist. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2017-05-17of_graph: add of_graph_get_endpoint_count()Kuninori Morimoto2-0/+18
OF graph want to count its endpoint number, same as of_get_child_count(). This patch adds of_graph_get_endpoint_count() Signed-off-by: Kuninori Morimoto <[email protected]> Acked-by: Rob Herring <[email protected]> Signed-off-by: Mark Brown <[email protected]>