Lines Matching full:mps

564 	/* Derive MPS from connection MTU to stop HCI fragmentation */  in l2cap_le_flowctl_init()
565 chan->mps = min_t(u16, chan->imtu, chan->conn->mtu - L2CAP_HDR_SIZE); in l2cap_le_flowctl_init()
567 chan->rx_credits = (chan->imtu / chan->mps) + 1; in l2cap_le_flowctl_init()
576 /* L2CAP implementations shall support a minimum MPS of 64 octets */ in l2cap_ecred_init()
577 if (chan->mps < L2CAP_ECRED_MIN_MPS) { in l2cap_ecred_init()
578 chan->mps = L2CAP_ECRED_MIN_MPS; in l2cap_ecred_init()
579 chan->rx_credits = (chan->imtu / chan->mps) + 1; in l2cap_ecred_init()
768 rsp.mps = cpu_to_le16(chan->mps); in l2cap_chan_le_connect_reject()
1405 req.mps = cpu_to_le16(chan->mps); in l2cap_le_connect()
1472 data.pdu.req.mps = cpu_to_le16(chan->mps); in l2cap_ecred_connect()
3907 chan->mps = le16_to_cpu(rfc.max_pdu_size); in l2cap_parse_conf_rsp()
3923 chan->mps = le16_to_cpu(rfc.max_pdu_size); in l2cap_parse_conf_rsp()
3957 rsp.mps = cpu_to_le16(chan->mps); in __l2cap_le_connect_rsp_defer()
3981 pdu.rsp.mps = cpu_to_le16(chan->mps); in __l2cap_ecred_conn_rsp_defer()
4077 chan->mps = le16_to_cpu(rfc.max_pdu_size); in l2cap_conf_rfc_get()
4085 chan->mps = le16_to_cpu(rfc.max_pdu_size); in l2cap_conf_rfc_get()
5630 u16 dcid, mtu, mps, credits, result; in l2cap_le_connect_rsp() local
5639 mps = __le16_to_cpu(rsp->mps); in l2cap_le_connect_rsp()
5643 if (result == L2CAP_CR_LE_SUCCESS && (mtu < 23 || mps < 23 || in l2cap_le_connect_rsp()
5648 BT_DBG("dcid 0x%4.4x mtu %u mps %u credits %u result 0x%2.2x", in l2cap_le_connect_rsp()
5649 dcid, mtu, mps, credits, result); in l2cap_le_connect_rsp()
5673 chan->remote_mps = mps; in l2cap_le_connect_rsp()
5798 u16 dcid, scid, credits, mtu, mps; in l2cap_le_connect_req() local
5807 mps = __le16_to_cpu(req->mps); in l2cap_le_connect_req()
5812 if (mtu < 23 || mps < 23) in l2cap_le_connect_req()
5815 BT_DBG("psm 0x%2.2x scid 0x%4.4x mtu %u mps %u", __le16_to_cpu(psm), in l2cap_le_connect_req()
5816 scid, mtu, mps); in l2cap_le_connect_req()
5877 chan->remote_mps = mps; in l2cap_le_connect_req()
5915 rsp.mps = cpu_to_le16(chan->mps); in l2cap_le_connect_req()
5918 rsp.mps = 0; in l2cap_le_connect_req()
5987 u16 mtu, mps; in l2cap_ecred_conn_req() local
6010 mps = __le16_to_cpu(req->mps); in l2cap_ecred_conn_req()
6012 if (mtu < L2CAP_ECRED_MIN_MTU || mps < L2CAP_ECRED_MIN_MPS) { in l2cap_ecred_conn_req()
6031 BT_DBG("psm 0x%2.2x mtu %u mps %u", __le16_to_cpu(psm), mtu, mps); in l2cap_ecred_conn_req()
6087 chan->remote_mps = mps; in l2cap_ecred_conn_req()
6096 pdu.rsp.mps = cpu_to_le16(chan->mps); in l2cap_ecred_conn_req()
6138 u16 mtu, mps, credits, result; in l2cap_ecred_conn_rsp() local
6147 mps = __le16_to_cpu(rsp->mps); in l2cap_ecred_conn_rsp()
6151 BT_DBG("mtu %u mps %u credits %u result 0x%4.4x", mtu, mps, credits, in l2cap_ecred_conn_rsp()
6232 chan->remote_mps = mps; in l2cap_ecred_conn_rsp()
6252 u16 mtu, mps, result; in l2cap_ecred_reconf_req() local
6265 mps = __le16_to_cpu(req->mps); in l2cap_ecred_reconf_req()
6267 BT_DBG("mtu %u mps %u", mtu, mps); in l2cap_ecred_reconf_req()
6274 if (mps < L2CAP_ECRED_MIN_MPS) { in l2cap_ecred_reconf_req()
6305 chan->remote_mps = mps; in l2cap_ecred_reconf_req()
7418 if (len > chan->mps) { in l2cap_data_rcv()
7493 return_credits = (chan->imtu / chan->mps) + 1; in l2cap_chan_le_send_credits()
7546 * if the remote is not using the entire MPS. in l2cap_ecred_data_rcv()
7581 /* Detect if remote is not able to use the selected MPS */ in l2cap_ecred_data_rcv()
7582 if (skb->len + L2CAP_SDULEN_SIZE < chan->mps) { in l2cap_ecred_data_rcv()
7586 BT_DBG("chan->mps %u -> %u", chan->mps, mps_len); in l2cap_ecred_data_rcv()
7587 chan->mps = mps_len; in l2cap_ecred_data_rcv()
8114 pdu.req.mps = cpu_to_le16(chan->mps); in l2cap_ecred_reconfigure()