Bluetooth: Fix reserve param of bt_l2cap_create_pdu()
reserve parameter of bt_l2cap_create_pdu() is incorrectly passed as timeout. Change-Id: Ieed293f52c2e98f16f1e43c498140178703236db Signed-off-by: Jaganath Kanakkassery <jaganathx.kanakkassery@intel.com>
This commit is contained in:
parent
aaf6bbf33c
commit
5f3ce62eed
4 changed files with 9 additions and 9 deletions
|
@ -322,7 +322,7 @@ static int rfcomm_send_sabm(struct bt_rfcomm_session *session, uint8_t dlci)
|
|||
struct net_buf *buf;
|
||||
uint8_t cr, fcs;
|
||||
|
||||
buf = bt_l2cap_create_pdu(&rfcomm_session_pool, K_FOREVER);
|
||||
buf = bt_l2cap_create_pdu(&rfcomm_session_pool, 0);
|
||||
|
||||
hdr = net_buf_add(buf, sizeof(*hdr));
|
||||
cr = BT_RFCOMM_CMD_CR(session->role);
|
||||
|
@ -345,7 +345,7 @@ static struct net_buf *rfcomm_make_uih_msg(struct bt_rfcomm_session *session,
|
|||
struct net_buf *buf;
|
||||
uint8_t hdr_cr;
|
||||
|
||||
buf = bt_l2cap_create_pdu(&rfcomm_session_pool, K_FOREVER);
|
||||
buf = bt_l2cap_create_pdu(&rfcomm_session_pool, 0);
|
||||
|
||||
hdr = net_buf_add(buf, sizeof(*hdr));
|
||||
hdr_cr = BT_RFCOMM_UIH_CR(session->role);
|
||||
|
@ -442,7 +442,7 @@ static int rfcomm_send_dm(struct bt_rfcomm_session *session, uint8_t dlci)
|
|||
|
||||
BT_DBG("dlci %d", dlci);
|
||||
|
||||
buf = bt_l2cap_create_pdu(&rfcomm_session_pool, K_FOREVER);
|
||||
buf = bt_l2cap_create_pdu(&rfcomm_session_pool, 0);
|
||||
|
||||
hdr = net_buf_add(buf, sizeof(*hdr));
|
||||
cr = BT_RFCOMM_RESP_CR(session->role);
|
||||
|
@ -464,7 +464,7 @@ static int rfcomm_send_disc(struct bt_rfcomm_session *session, uint8_t dlci)
|
|||
|
||||
BT_DBG("dlci %d", dlci);
|
||||
|
||||
buf = bt_l2cap_create_pdu(&rfcomm_session_pool, K_FOREVER);
|
||||
buf = bt_l2cap_create_pdu(&rfcomm_session_pool, 0);
|
||||
|
||||
hdr = net_buf_add(buf, sizeof(*hdr));
|
||||
cr = BT_RFCOMM_RESP_CR(session->role);
|
||||
|
@ -547,7 +547,7 @@ static int rfcomm_send_ua(struct bt_rfcomm_session *session, uint8_t dlci)
|
|||
struct net_buf *buf;
|
||||
uint8_t cr, fcs;
|
||||
|
||||
buf = bt_l2cap_create_pdu(&rfcomm_session_pool, K_FOREVER);
|
||||
buf = bt_l2cap_create_pdu(&rfcomm_session_pool, 0);
|
||||
|
||||
hdr = net_buf_add(buf, sizeof(*hdr));
|
||||
cr = BT_RFCOMM_RESP_CR(session->role);
|
||||
|
@ -829,7 +829,7 @@ static int rfcomm_send_credit(struct bt_rfcomm_dlc *dlc, uint8_t credits)
|
|||
|
||||
BT_DBG("Dlc %p credits %d", dlc, credits);
|
||||
|
||||
buf = bt_l2cap_create_pdu(&rfcomm_session_pool, K_FOREVER);
|
||||
buf = bt_l2cap_create_pdu(&rfcomm_session_pool, 0);
|
||||
|
||||
hdr = net_buf_add(buf, sizeof(*hdr));
|
||||
cr = BT_RFCOMM_UIH_CR(dlc->session->role);
|
||||
|
|
|
@ -130,7 +130,7 @@ struct net_buf *bt_sdp_create_pdu(void)
|
|||
{
|
||||
struct net_buf *buf;
|
||||
|
||||
buf = bt_l2cap_create_pdu(&sdp_pool, K_FOREVER);
|
||||
buf = bt_l2cap_create_pdu(&sdp_pool, 0);
|
||||
/* NULL is not a possible return due to K_FOREVER */
|
||||
net_buf_reserve(buf, sizeof(struct bt_sdp_hdr));
|
||||
|
||||
|
|
|
@ -336,7 +336,7 @@ static struct net_buf *smp_create_pdu(struct bt_conn *conn, uint8_t op,
|
|||
struct bt_smp_hdr *hdr;
|
||||
struct net_buf *buf;
|
||||
|
||||
buf = bt_l2cap_create_pdu(&smp_pool, K_FOREVER);
|
||||
buf = bt_l2cap_create_pdu(&smp_pool, 0);
|
||||
/* NULL is not a possible return due to K_FOREVER */
|
||||
|
||||
hdr = net_buf_add(buf, sizeof(*hdr));
|
||||
|
|
|
@ -62,7 +62,7 @@ static void bt_smp_recv(struct bt_l2cap_chan *chan, struct net_buf *buf)
|
|||
* Core Specification Vol. 3, Part H, 3.3
|
||||
*/
|
||||
|
||||
buf = bt_l2cap_create_pdu(&smp_pool, K_FOREVER);
|
||||
buf = bt_l2cap_create_pdu(&smp_pool, 0);
|
||||
/* NULL is not a possible return due to K_FOREVER */
|
||||
|
||||
hdr = net_buf_add(buf, sizeof(*hdr));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue