From: Maxime Chevallier <maxime.chevallier@smile.fr>
To: linux-bluetooth@vger.kernel.org
Cc: luiz.dentz@gmail.com, Maxime Chevallier <maxime.chevallier@smile.fr>
Subject: [PATCH 1/1] profiles/network: look for GN servers to accept incoming connections
Date: Thu, 13 Oct 2016 15:24:39 +0200 [thread overview]
Message-ID: <1476365079-3469-2-git-send-email-maxime.chevallier@smile.fr> (raw)
In-Reply-To: <1476365079-3469-1-git-send-email-maxime.chevallier@smile.fr>
When asking confirmation to accept an incoming connection, we must
try to get both NAP and GN servers from the adapter.
This fixes the PAN GN Master role, allowing devices to connect to it.
---
profiles/network/server.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/profiles/network/server.c b/profiles/network/server.c
index 1bff9f8..843472f 100644
--- a/profiles/network/server.c
+++ b/profiles/network/server.c
@@ -455,8 +455,13 @@ static void confirm_event(GIOChannel *chan, gpointer user_data)
}
ns = find_server(na->servers, BNEP_SVC_NAP);
- if (!ns || !ns->record_id || !ns->bridge)
- goto drop;
+ if (!ns || !ns->record_id || !ns->bridge) {
+
+ ns = find_server(na->servers, BNEP_SVC_GN);
+ if (!ns || !ns->record_id || !ns->bridge)
+ goto drop;
+
+ }
na->setup = g_new0(struct network_session, 1);
bacpy(&na->setup->dst, &dst);
--
2.1.4
prev parent reply other threads:[~2016-10-13 13:24 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-10-13 13:24 [PATCH 0/1] GN Master role fails to accept connections Maxime Chevallier
2016-10-13 13:24 ` Maxime Chevallier [this message]
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=1476365079-3469-2-git-send-email-maxime.chevallier@smile.fr \
--to=maxime.chevallier@smile.fr \
--cc=linux-bluetooth@vger.kernel.org \
--cc=luiz.dentz@gmail.com \
/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).