From: Takashi Iwai <tiwai@suse.de>
To: alsa-devel@alsa-project.org
Subject: [PATCH] ALSA: usb-audio: Pass JOINT_DUPLEX info flag for implicit fb streams
Date: Thu, 7 Oct 2021 10:35:28 +0200 [thread overview]
Message-ID: <20211007083528.4184-1-tiwai@suse.de> (raw)
When a stream is in the implicit feedback mode, it's more or less tied
with a capture stream. Passing SNDRV_PCM_INFO_JOINT_DUPLEX may help
for user-space to understand the situation.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
---
sound/usb/pcm.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/sound/usb/pcm.c b/sound/usb/pcm.c
index f09c7380a923..3bb095a3c9b6 100644
--- a/sound/usb/pcm.c
+++ b/sound/usb/pcm.c
@@ -1080,6 +1080,13 @@ static int setup_hw_info(struct snd_pcm_runtime *runtime, struct snd_usb_substre
if (err < 0)
return err;
+ list_for_each_entry(fp, &subs->fmt_list, list) {
+ if (fp->implicit_fb) {
+ runtime->hw.info |= SNDRV_PCM_INFO_JOINT_DUPLEX;
+ break;
+ }
+ }
+
return 0;
}
--
2.31.1
reply other threads:[~2021-10-07 8:36 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20211007083528.4184-1-tiwai@suse.de \
--to=tiwai@suse.de \
--cc=alsa-devel@alsa-project.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: link
Be 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.