* [PATCH v3 0/2] ASoC: imx-card: support playback or capture only
@ 2025-02-17 2:17 Shengjiu Wang
2025-02-17 2:17 ` [PATCH v3 1/2] ASoC: dt-bindings: imx-card: Add playback-only and capture-only property Shengjiu Wang
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Shengjiu Wang @ 2025-02-17 2:17 UTC (permalink / raw)
To: shengjiu.wang, Xiubo.Lee, festevam, nicoleotsuka, lgirdwood,
broonie, perex, tiwai, shawnguo, s.hauer, kernel, linux-sound,
linuxppc-dev, imx, linux-arm-kernel, linux-kernel, robh, krzk+dt,
conor+dt, devicetree
Be similar to audio graph card, support playback or capture only for
imx-audio-card.
imx-card can't directly refer to audio-graph-port.yaml, because it is
not based on 'ports'. Add playback-only and capture-only property
directly
changes in v3:
- add mutually exclusive expression
changes in v2:
- wrap at 75 chars for commit messages
Shengjiu Wang (2):
ASoC: dt-bindings: imx-card: Add playback-only and capture-only
property
ASoC: imx-card: Add playback_only or capture_only support
.../devicetree/bindings/sound/imx-audio-card.yaml | 14 ++++++++++++++
sound/soc/fsl/imx-card.c | 5 +++++
2 files changed, 19 insertions(+)
--
2.34.1
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH v3 1/2] ASoC: dt-bindings: imx-card: Add playback-only and capture-only property
2025-02-17 2:17 [PATCH v3 0/2] ASoC: imx-card: support playback or capture only Shengjiu Wang
@ 2025-02-17 2:17 ` Shengjiu Wang
2025-02-19 23:13 ` Rob Herring (Arm)
2025-02-17 2:17 ` [PATCH v3 2/2] ASoC: imx-card: Add playback_only or capture_only support Shengjiu Wang
2025-02-25 17:03 ` [PATCH v3 0/2] ASoC: imx-card: support playback or capture only Mark Brown
2 siblings, 1 reply; 5+ messages in thread
From: Shengjiu Wang @ 2025-02-17 2:17 UTC (permalink / raw)
To: shengjiu.wang, Xiubo.Lee, festevam, nicoleotsuka, lgirdwood,
broonie, perex, tiwai, shawnguo, s.hauer, kernel, linux-sound,
linuxppc-dev, imx, linux-arm-kernel, linux-kernel, robh, krzk+dt,
conor+dt, devicetree
Refer to audio graph card, add playback-only and capture-only property
for imx-audio-card.yaml for the case that only playback or capture is
supported.
Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
Reviewed-by: Daniel Baluta <daniel.baluta@nxp.com>
Reviewed-by: Iuliana Prodan <iuliana.prodan@nxp.com>
---
.../devicetree/bindings/sound/imx-audio-card.yaml | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/Documentation/devicetree/bindings/sound/imx-audio-card.yaml b/Documentation/devicetree/bindings/sound/imx-audio-card.yaml
index f7ad5ea2491e..3c75c8c78987 100644
--- a/Documentation/devicetree/bindings/sound/imx-audio-card.yaml
+++ b/Documentation/devicetree/bindings/sound/imx-audio-card.yaml
@@ -46,6 +46,14 @@ patternProperties:
description: see tdm-slot.txt.
$ref: /schemas/types.yaml#/definitions/uint32
+ playback-only:
+ description: link is used only for playback
+ $ref: /schemas/types.yaml#/definitions/flag
+
+ capture-only:
+ description: link is used only for capture
+ $ref: /schemas/types.yaml#/definitions/flag
+
cpu:
description: Holds subnode which indicates cpu dai.
type: object
@@ -71,6 +79,12 @@ patternProperties:
- link-name
- cpu
+ allOf:
+ - not:
+ required:
+ - playback-only
+ - capture-only
+
additionalProperties: false
required:
--
2.34.1
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH v3 2/2] ASoC: imx-card: Add playback_only or capture_only support
2025-02-17 2:17 [PATCH v3 0/2] ASoC: imx-card: support playback or capture only Shengjiu Wang
2025-02-17 2:17 ` [PATCH v3 1/2] ASoC: dt-bindings: imx-card: Add playback-only and capture-only property Shengjiu Wang
@ 2025-02-17 2:17 ` Shengjiu Wang
2025-02-25 17:03 ` [PATCH v3 0/2] ASoC: imx-card: support playback or capture only Mark Brown
2 siblings, 0 replies; 5+ messages in thread
From: Shengjiu Wang @ 2025-02-17 2:17 UTC (permalink / raw)
To: shengjiu.wang, Xiubo.Lee, festevam, nicoleotsuka, lgirdwood,
broonie, perex, tiwai, shawnguo, s.hauer, kernel, linux-sound,
linuxppc-dev, imx, linux-arm-kernel, linux-kernel, robh, krzk+dt,
conor+dt, devicetree
With the DPCM case, the backend only support capture or playback, then
the linked frontend can only support capture or playback, but frontend
can't automatically enable only capture or playback, it needs the input
from dt-binding.
Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
Reviewed-by: Daniel Baluta <daniel.baluta@nxp.com>
Reviewed-by: Iuliana Prodan <iuliana.prodan@nxp.com>
---
sound/soc/fsl/imx-card.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/sound/soc/fsl/imx-card.c b/sound/soc/fsl/imx-card.c
index ac043ad367ac..905294682996 100644
--- a/sound/soc/fsl/imx-card.c
+++ b/sound/soc/fsl/imx-card.c
@@ -518,6 +518,7 @@ static int imx_card_parse_of(struct imx_card_data *data)
struct snd_soc_dai_link *link;
struct dai_link_data *link_data;
struct of_phandle_args args;
+ bool playback_only, capture_only;
int ret, num_links;
u32 asrc_fmt = 0;
u32 width;
@@ -679,6 +680,10 @@ static int imx_card_parse_of(struct imx_card_data *data)
link->ops = &imx_aif_ops;
}
+ graph_util_parse_link_direction(np, &playback_only, &capture_only);
+ link->playback_only = playback_only;
+ link->capture_only = capture_only;
+
/* Get dai fmt */
ret = simple_util_parse_daifmt(dev, np, codec,
NULL, &link->dai_fmt);
--
2.34.1
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v3 1/2] ASoC: dt-bindings: imx-card: Add playback-only and capture-only property
2025-02-17 2:17 ` [PATCH v3 1/2] ASoC: dt-bindings: imx-card: Add playback-only and capture-only property Shengjiu Wang
@ 2025-02-19 23:13 ` Rob Herring (Arm)
0 siblings, 0 replies; 5+ messages in thread
From: Rob Herring (Arm) @ 2025-02-19 23:13 UTC (permalink / raw)
To: Shengjiu Wang
Cc: shengjiu.wang, festevam, krzk+dt, lgirdwood, linux-sound,
linuxppc-dev, devicetree, s.hauer, kernel, shawnguo, tiwai,
nicoleotsuka, conor+dt, perex, imx, linux-arm-kernel,
linux-kernel, broonie, Xiubo.Lee
On Mon, 17 Feb 2025 10:17:14 +0800, Shengjiu Wang wrote:
> Refer to audio graph card, add playback-only and capture-only property
> for imx-audio-card.yaml for the case that only playback or capture is
> supported.
>
> Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
> Reviewed-by: Daniel Baluta <daniel.baluta@nxp.com>
> Reviewed-by: Iuliana Prodan <iuliana.prodan@nxp.com>
> ---
> .../devicetree/bindings/sound/imx-audio-card.yaml | 14 ++++++++++++++
> 1 file changed, 14 insertions(+)
>
Acked-by: Rob Herring (Arm) <robh@kernel.org>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v3 0/2] ASoC: imx-card: support playback or capture only
2025-02-17 2:17 [PATCH v3 0/2] ASoC: imx-card: support playback or capture only Shengjiu Wang
2025-02-17 2:17 ` [PATCH v3 1/2] ASoC: dt-bindings: imx-card: Add playback-only and capture-only property Shengjiu Wang
2025-02-17 2:17 ` [PATCH v3 2/2] ASoC: imx-card: Add playback_only or capture_only support Shengjiu Wang
@ 2025-02-25 17:03 ` Mark Brown
2 siblings, 0 replies; 5+ messages in thread
From: Mark Brown @ 2025-02-25 17:03 UTC (permalink / raw)
To: shengjiu.wang, Xiubo.Lee, festevam, nicoleotsuka, lgirdwood,
perex, tiwai, shawnguo, s.hauer, kernel, linux-sound,
linuxppc-dev, imx, linux-arm-kernel, linux-kernel, robh, krzk+dt,
conor+dt, devicetree, Shengjiu Wang
On Mon, 17 Feb 2025 10:17:13 +0800, Shengjiu Wang wrote:
> Be similar to audio graph card, support playback or capture only for
> imx-audio-card.
>
> imx-card can't directly refer to audio-graph-port.yaml, because it is
> not based on 'ports'. Add playback-only and capture-only property
> directly
>
> [...]
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
Thanks!
[1/2] ASoC: dt-bindings: imx-card: Add playback-only and capture-only property
commit: 8c6ede5cc4226fd841f252d02ab0372cb92ee75c
[2/2] ASoC: imx-card: Add playback_only or capture_only support
commit: 1877c3e7937fb2b9373ba263a4900448d50917b7
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
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2025-02-25 17:03 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-02-17 2:17 [PATCH v3 0/2] ASoC: imx-card: support playback or capture only Shengjiu Wang
2025-02-17 2:17 ` [PATCH v3 1/2] ASoC: dt-bindings: imx-card: Add playback-only and capture-only property Shengjiu Wang
2025-02-19 23:13 ` Rob Herring (Arm)
2025-02-17 2:17 ` [PATCH v3 2/2] ASoC: imx-card: Add playback_only or capture_only support Shengjiu Wang
2025-02-25 17:03 ` [PATCH v3 0/2] ASoC: imx-card: support playback or capture only Mark Brown
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®