You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by an...@apache.org on 2018/03/12 13:37:53 UTC
[mynewt-nimble] 19/32: mesh: Resend Link Acknowledgment when
necessary
This is an automated email from the ASF dual-hosted git repository.
andk pushed a commit to branch new-master
in repository https://gitbox.apache.org/repos/asf/mynewt-nimble.git
commit 63b487ad59a15d268dc2a51d493ad0d2582dd49a
Author: MichaĆ Narajowski <mi...@codecoup.pl>
AuthorDate: Tue Feb 20 14:24:33 2018 +0100
mesh: Resend Link Acknowledgment when necessary
The Provisioner might have missed our earlier Link Acknowledgement, so
if we receive another one with matching Link ID and link.expect state,
simply send another acknowledgement.
X-Original-Commit: b6d823cb5131e8750d7ec1152b4d48ea60ac85c3
---
nimble/host/mesh/src/prov.c | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/nimble/host/mesh/src/prov.c b/nimble/host/mesh/src/prov.c
index 0a2d3b2..04cab17 100644
--- a/nimble/host/mesh/src/prov.c
+++ b/nimble/host/mesh/src/prov.c
@@ -1179,7 +1179,14 @@ static void link_open(struct prov_rx *rx, struct os_mbuf *buf)
}
if (atomic_test_bit(link.flags, LINK_ACTIVE)) {
- BT_WARN("Ignoring bearer open: link already active");
+ /* Send another link ack if the provisioner missed the last */
+ if (link.id == rx->link_id && link.expect == PROV_INVITE) {
+ BT_DBG("Resending link ack");
+ bearer_ctl_send(LINK_ACK, NULL, 0);
+ } else {
+ BT_WARN("Ignoring bearer open: link already active");
+ }
+
return;
}
--
To stop receiving notification emails like this one, please contact
andk@apache.org.