From: Mark Brown <broonie@kernel.org> To: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Cc: Mark Brown <broonie@kernel.org>, lee.jones@linaro.org, robh+dt@kernel.org, broonie@kernel.org, mark.rutland@arm.com, devicetree@vger.kernel.org, alsa-devel@alsa-project.org, bgoswami@codeaurora.org, tiwai@suse.com, lgirdwood@gmail.com, linux-kernel@vger.kernel.org, vkoul@kernel.org, alsa-devel@alsa-project.org Subject: Applied "ASoC: core: add support to snd_soc_dai_get_channel_map()" to the asoc tree Date: Tue, 24 Jul 2018 12:50:37 +0100 (BST) [thread overview] Message-ID: <20180724115037.3DF0E440078@finisterre.ee.mobilebroadband> (raw) In-Reply-To: <20180723155410.9494-6-srinivas.kandagatla@linaro.org> The patch ASoC: core: add support to snd_soc_dai_get_channel_map() has been applied to the asoc tree at https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted. You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed. If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced. Please add any relevant lists and maintainers to the CCs when replying to this mail. Thanks, Mark From 467b061f1ac80f323bedb56d20a24f7bc0d2cec5 Mon Sep 17 00:00:00 2001 From: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Mon, 23 Jul 2018 16:54:03 +0100 Subject: [PATCH] ASoC: core: add support to snd_soc_dai_get_channel_map() On Qualcomm platforms, specifically with SLIMbus interfaced codecs, the codec slim channel numbers are passed to DSP while configuring the slim audio path. Having get_channel_map() would allow dais to share such information across multiple dais. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org> --- include/sound/soc-dai.h | 8 ++++++++ sound/soc/soc-core.c | 22 ++++++++++++++++++++++ 2 files changed, 30 insertions(+) diff --git a/include/sound/soc-dai.h b/include/sound/soc-dai.h index a14bc0608ae9..f5d70041108f 100644 --- a/include/sound/soc-dai.h +++ b/include/sound/soc-dai.h @@ -138,6 +138,11 @@ int snd_soc_dai_set_tristate(struct snd_soc_dai *dai, int tristate); int snd_soc_dai_digital_mute(struct snd_soc_dai *dai, int mute, int direction); + +int snd_soc_dai_get_channel_map(struct snd_soc_dai *dai, + unsigned int *tx_num, unsigned int *tx_slot, + unsigned int *rx_num, unsigned int *rx_slot); + int snd_soc_dai_is_dummy(struct snd_soc_dai *dai); struct snd_soc_dai_ops { @@ -165,6 +170,9 @@ struct snd_soc_dai_ops { int (*set_channel_map)(struct snd_soc_dai *dai, unsigned int tx_num, unsigned int *tx_slot, unsigned int rx_num, unsigned int *rx_slot); + int (*get_channel_map)(struct snd_soc_dai *dai, + unsigned int *tx_num, unsigned int *tx_slot, + unsigned int *rx_num, unsigned int *rx_slot); int (*set_tristate)(struct snd_soc_dai *dai, int tristate); int (*set_sdw_stream)(struct snd_soc_dai *dai, diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c index ad5b0ef16d82..81b27923303d 100644 --- a/sound/soc/soc-core.c +++ b/sound/soc/soc-core.c @@ -2679,6 +2679,28 @@ int snd_soc_dai_set_channel_map(struct snd_soc_dai *dai, } EXPORT_SYMBOL_GPL(snd_soc_dai_set_channel_map); +/** + * snd_soc_dai_get_channel_map - Get DAI audio channel map + * @dai: DAI + * @tx_num: how many TX channels + * @tx_slot: pointer to an array which imply the TX slot number channel + * 0~num-1 uses + * @rx_num: how many RX channels + * @rx_slot: pointer to an array which imply the RX slot number channel + * 0~num-1 uses + */ +int snd_soc_dai_get_channel_map(struct snd_soc_dai *dai, + unsigned int *tx_num, unsigned int *tx_slot, + unsigned int *rx_num, unsigned int *rx_slot) +{ + if (dai->driver->ops->get_channel_map) + return dai->driver->ops->get_channel_map(dai, tx_num, tx_slot, + rx_num, rx_slot); + else + return -ENOTSUPP; +} +EXPORT_SYMBOL_GPL(snd_soc_dai_get_channel_map); + /** * snd_soc_dai_set_tristate - configure DAI system or master clock. * @dai: DAI -- 2.18.0
WARNING: multiple messages have this Message-ID (diff)
From: Mark Brown <broonie@kernel.org> To: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Cc: mark.rutland@arm.com, devicetree@vger.kernel.org, alsa-devel@alsa-project.org, bgoswami@codeaurora.org, linux-kernel@vger.kernel.org, tiwai@suse.com, robh+dt@kernel.org, lgirdwood@gmail.com, vkoul@kernel.org, broonie@kernel.org, lee.jones@linaro.org Subject: Applied "ASoC: core: add support to snd_soc_dai_get_channel_map()" to the asoc tree Date: Tue, 24 Jul 2018 12:50:37 +0100 (BST) [thread overview] Message-ID: <20180724115037.3DF0E440078@finisterre.ee.mobilebroadband> (raw) In-Reply-To: <20180723155410.9494-6-srinivas.kandagatla@linaro.org> The patch ASoC: core: add support to snd_soc_dai_get_channel_map() has been applied to the asoc tree at https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted. You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed. If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced. Please add any relevant lists and maintainers to the CCs when replying to this mail. Thanks, Mark >From 467b061f1ac80f323bedb56d20a24f7bc0d2cec5 Mon Sep 17 00:00:00 2001 From: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Date: Mon, 23 Jul 2018 16:54:03 +0100 Subject: [PATCH] ASoC: core: add support to snd_soc_dai_get_channel_map() On Qualcomm platforms, specifically with SLIMbus interfaced codecs, the codec slim channel numbers are passed to DSP while configuring the slim audio path. Having get_channel_map() would allow dais to share such information across multiple dais. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org> --- include/sound/soc-dai.h | 8 ++++++++ sound/soc/soc-core.c | 22 ++++++++++++++++++++++ 2 files changed, 30 insertions(+) diff --git a/include/sound/soc-dai.h b/include/sound/soc-dai.h index a14bc0608ae9..f5d70041108f 100644 --- a/include/sound/soc-dai.h +++ b/include/sound/soc-dai.h @@ -138,6 +138,11 @@ int snd_soc_dai_set_tristate(struct snd_soc_dai *dai, int tristate); int snd_soc_dai_digital_mute(struct snd_soc_dai *dai, int mute, int direction); + +int snd_soc_dai_get_channel_map(struct snd_soc_dai *dai, + unsigned int *tx_num, unsigned int *tx_slot, + unsigned int *rx_num, unsigned int *rx_slot); + int snd_soc_dai_is_dummy(struct snd_soc_dai *dai); struct snd_soc_dai_ops { @@ -165,6 +170,9 @@ struct snd_soc_dai_ops { int (*set_channel_map)(struct snd_soc_dai *dai, unsigned int tx_num, unsigned int *tx_slot, unsigned int rx_num, unsigned int *rx_slot); + int (*get_channel_map)(struct snd_soc_dai *dai, + unsigned int *tx_num, unsigned int *tx_slot, + unsigned int *rx_num, unsigned int *rx_slot); int (*set_tristate)(struct snd_soc_dai *dai, int tristate); int (*set_sdw_stream)(struct snd_soc_dai *dai, diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c index ad5b0ef16d82..81b27923303d 100644 --- a/sound/soc/soc-core.c +++ b/sound/soc/soc-core.c @@ -2679,6 +2679,28 @@ int snd_soc_dai_set_channel_map(struct snd_soc_dai *dai, } EXPORT_SYMBOL_GPL(snd_soc_dai_set_channel_map); +/** + * snd_soc_dai_get_channel_map - Get DAI audio channel map + * @dai: DAI + * @tx_num: how many TX channels + * @tx_slot: pointer to an array which imply the TX slot number channel + * 0~num-1 uses + * @rx_num: how many RX channels + * @rx_slot: pointer to an array which imply the RX slot number channel + * 0~num-1 uses + */ +int snd_soc_dai_get_channel_map(struct snd_soc_dai *dai, + unsigned int *tx_num, unsigned int *tx_slot, + unsigned int *rx_num, unsigned int *rx_slot) +{ + if (dai->driver->ops->get_channel_map) + return dai->driver->ops->get_channel_map(dai, tx_num, tx_slot, + rx_num, rx_slot); + else + return -ENOTSUPP; +} +EXPORT_SYMBOL_GPL(snd_soc_dai_get_channel_map); + /** * snd_soc_dai_set_tristate - configure DAI system or master clock. * @dai: DAI -- 2.18.0
next prev parent reply other threads:[~2018-07-24 11:50 UTC|newest] Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top 2018-07-23 15:53 [PATCH 00/12] mfd: Add support to WCD9335 Audio Codec Srinivas Kandagatla 2018-07-23 15:53 ` [PATCH 01/12] mfd: dt-bindings: Add wcd9335 mfd bindings Srinivas Kandagatla 2018-07-23 15:53 ` Srinivas Kandagatla 2018-07-24 5:56 ` Vinod 2018-07-24 5:56 ` Vinod 2018-07-24 11:50 ` Srinivas Kandagatla 2018-07-23 15:54 ` [PATCH 02/12] mfd: wcd9335: add support to wcd9335 core Srinivas Kandagatla 2018-07-23 15:54 ` Srinivas Kandagatla 2018-07-23 15:54 ` [PATCH 03/12] mfd: wcd9335: add wcd irq support Srinivas Kandagatla 2018-07-23 15:54 ` [PATCH 04/12] ASoC: dt-bindings: add dt bindings for wcd9335 audio codec Srinivas Kandagatla 2018-07-23 15:54 ` Srinivas Kandagatla 2018-07-24 11:06 ` Mark Brown 2018-07-24 11:06 ` Mark Brown 2018-07-24 11:48 ` Srinivas Kandagatla 2018-07-24 11:48 ` Srinivas Kandagatla 2018-07-23 15:54 ` [PATCH 05/12] ASoC: core: add support to snd_soc_dai_get_channel_map() Srinivas Kandagatla 2018-07-24 11:50 ` Mark Brown [this message] 2018-07-24 11:50 ` Applied "ASoC: core: add support to snd_soc_dai_get_channel_map()" to the asoc tree Mark Brown 2018-07-23 15:54 ` [PATCH 06/12] ASoC: wcd9335: add support to wcd9335 codec Srinivas Kandagatla 2018-07-23 15:54 ` [PATCH 07/12] ASoC: wcd9335: add CLASS-H Controller support Srinivas Kandagatla 2018-07-24 11:59 ` Mark Brown 2018-07-24 11:59 ` Mark Brown 2018-07-24 12:05 ` Srinivas Kandagatla 2018-07-23 15:54 ` [PATCH 08/12] ASoC: wcd9335: add basic controls Srinivas Kandagatla 2018-07-25 12:04 ` Vinod 2018-07-27 9:55 ` Srinivas Kandagatla 2018-07-23 15:54 ` [PATCH 09/12] ASoC: wcd9335: add playback dapm widgets Srinivas Kandagatla 2018-07-23 15:54 ` [PATCH 10/12] ASoC: wcd9335: add capture " Srinivas Kandagatla 2018-07-23 15:54 ` [PATCH 11/12] ASoC: wcd9335: add audio routings Srinivas Kandagatla 2018-07-23 15:54 ` [PATCH 12/12] ASoC: apq8096: Add support to Analog audio via WCD9335 slim Srinivas Kandagatla 2018-07-25 16:24 ` Mark Brown 2018-07-25 16:24 ` Mark Brown 2018-07-24 5:53 ` [PATCH 00/12] mfd: Add support to WCD9335 Audio Codec Vinod
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20180724115037.3DF0E440078@finisterre.ee.mobilebroadband \ --to=broonie@kernel.org \ --cc=alsa-devel@alsa-project.org \ --cc=bgoswami@codeaurora.org \ --cc=devicetree@vger.kernel.org \ --cc=lee.jones@linaro.org \ --cc=lgirdwood@gmail.com \ --cc=linux-kernel@vger.kernel.org \ --cc=mark.rutland@arm.com \ --cc=robh+dt@kernel.org \ --cc=srinivas.kandagatla@linaro.org \ --cc=tiwai@suse.com \ --cc=vkoul@kernel.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.