From: Luiz Augusto von Dentz <luiz.dentz@gmail.com>
To: linux-bluetooth@vger.kernel.org
Subject: [PATCH v3 4/6] a2dp: Fix reconfiguring when there multiple devices connected
Date: Mon, 6 May 2019 15:43:08 +0300 [thread overview]
Message-ID: <20190506124310.19151-4-luiz.dentz@gmail.com> (raw)
In-Reply-To: <20190506124310.19151-1-luiz.dentz@gmail.com>
From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
When there are multiple devices connected streams need to be matched
with the sessions they belong.
---
profiles/audio/a2dp.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/profiles/audio/a2dp.c b/profiles/audio/a2dp.c
index 2ce7c06cb..f89105a8d 100644
--- a/profiles/audio/a2dp.c
+++ b/profiles/audio/a2dp.c
@@ -1648,6 +1648,10 @@ static int a2dp_reconfig(struct a2dp_channel *chan, const char *sender,
tmp->user_data)))
return -EPERM;
+ /* Check if stream is for the channel */
+ if (!avdtp_has_stream(chan->session, tmp->stream))
+ continue;
+
err = avdtp_close(chan->session, tmp->stream, FALSE);
if (err < 0) {
err = avdtp_abort(chan->session, tmp->stream);
--
2.20.1
next prev parent reply other threads:[~2019-05-06 12:43 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-06 12:43 [PATCH v3 1/6] a2dp: Fix crash when endpoint respond with an error Luiz Augusto von Dentz
2019-05-06 12:43 ` [PATCH v3 2/6] a2dp: Try aborting when switching endpoints Luiz Augusto von Dentz
2019-05-06 12:43 ` [PATCH v3 3/6] a2dp: Update last used on open indication Luiz Augusto von Dentz
2019-05-06 12:43 ` Luiz Augusto von Dentz [this message]
2019-05-06 12:43 ` [PATCH v3 5/6] a2dp: Fix useless statement Luiz Augusto von Dentz
2019-05-06 12:43 ` [PATCH v3 6/6] a2dp: Reword LastUsed Luiz Augusto von Dentz
2019-05-06 12:46 ` Luiz Augusto von Dentz
2019-05-06 13:02 ` Pali Rohár
2019-05-07 8:52 ` Pali Rohár
2019-05-07 10:13 ` Luiz Augusto von Dentz
2019-05-07 18:57 ` Pali Rohár
2019-06-07 13:04 ` Pali Rohár
2019-06-07 15:18 ` Luiz Augusto von Dentz
2019-06-10 12:35 ` Pali Rohár
2019-06-10 13:02 ` Luiz Augusto von Dentz
2019-05-07 10:17 ` [PATCH v3 1/6] a2dp: Fix crash when endpoint respond with an error Luiz Augusto von Dentz
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=20190506124310.19151-4-luiz.dentz@gmail.com \
--to=luiz.dentz@gmail.com \
--cc=linux-bluetooth@vger.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: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).