From 99fa1447212437d2c9150b3d6c90ec3bc1f7aeb2 Mon Sep 17 00:00:00 2001 From: Prathyusha N Date: Fri, 6 Dec 2019 09:38:39 +0530 Subject: [PATCH] mesh: Start link establishment timer of 60 sec 5.3.2 of Mesh Profile Bluetooth specification: To open a link, the provisioner shall start the link establishment timer, set to 60 seconds, and then shall start sending Link Open messages. On timeout, close indication will be sent. Provisioner cancels the Link Establishment timer, when the link is open i.e. in pb_adv_tx(). --- mesh/pb-adv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mesh/pb-adv.c b/mesh/pb-adv.c index 27cbc469e..c9a2a6574 100644 --- a/mesh/pb-adv.c +++ b/mesh/pb-adv.c @@ -458,6 +458,8 @@ bool pb_adv_reg(bool initiator, mesh_prov_open_func_t open_cb, if (initiator) { l_getrandom(&pb_session->link_id, sizeof(pb_session->link_id)); + pb_session->tx_timeout = l_timeout_create(60, tx_timeout, + pb_session, NULL); send_open_req(pb_session); } -- 2.47.3