Home
last modified time | relevance | path

Searched refs:credits (Results 1 – 9 of 9) sorted by relevance

/net/sched/
Dsch_cbs.c74 s64 credits; /* in bytes */ member
119 if (sch->q.qlen == 0 && q->credits > 0) { in cbs_enqueue_soft()
123 q->credits = 0; in cbs_enqueue_soft()
144 static s64 delay_from_credits(s64 credits, s64 slope) in delay_from_credits() argument
149 return div64_s64(-credits * NSEC_PER_SEC, slope); in delay_from_credits()
181 s64 credits; in cbs_dequeue_soft() local
189 if (q->credits < 0) { in cbs_dequeue_soft()
190 credits = timediff_to_credits(now - q->last, q->idleslope); in cbs_dequeue_soft()
192 credits = q->credits + credits; in cbs_dequeue_soft()
193 q->credits = min_t(s64, credits, q->hicredit); in cbs_dequeue_soft()
[all …]
/net/sunrpc/xprtrdma/
Dsvc_rdma_backchannel.c33 u32 credits; in svc_rdma_handle_bc_reply() local
64 credits = be32_to_cpup(rdma_resp + 2); in svc_rdma_handle_bc_reply()
65 if (credits == 0) in svc_rdma_handle_bc_reply()
66 credits = 1; /* don't deadlock */ in svc_rdma_handle_bc_reply()
67 else if (credits > r_xprt->rx_buf.rb_bc_max_requests) in svc_rdma_handle_bc_reply()
68 credits = r_xprt->rx_buf.rb_bc_max_requests; in svc_rdma_handle_bc_reply()
71 xprt->cwnd = credits << RPC_CWNDSHIFT; in svc_rdma_handle_bc_reply()
Drpc_rdma.c1343 u32 credits; in rpcrdma_reply_handler() local
1360 credits = be32_to_cpu(*p++); in rpcrdma_reply_handler()
1379 if (credits == 0) in rpcrdma_reply_handler()
1380 credits = 1; /* don't deadlock */ in rpcrdma_reply_handler()
1381 else if (credits > buf->rb_max_requests) in rpcrdma_reply_handler()
1382 credits = buf->rb_max_requests; in rpcrdma_reply_handler()
1383 if (buf->rb_credits != credits) { in rpcrdma_reply_handler()
1385 buf->rb_credits = credits; in rpcrdma_reply_handler()
1386 xprt->cwnd = credits << RPC_CWNDSHIFT; in rpcrdma_reply_handler()
1399 trace_xprtrdma_reply(rqst->rq_task, rep, req, credits); in rpcrdma_reply_handler()
/net/rds/
Dib_cm.c56 static void rds_ib_set_flow_control(struct rds_connection *conn, u32 credits) in rds_ib_set_flow_control() argument
60 if (rds_ib_sysctl_flow_control && credits != 0) { in rds_ib_set_flow_control()
63 rds_ib_send_add_credits(conn, credits); in rds_ib_set_flow_control()
252 unsigned int credits; in rds_ib_cm_fill_conn_param() local
254 credits = IB_GET_POST_CREDITS in rds_ib_cm_fill_conn_param()
257 dp->ricp_v6.dp_credit = cpu_to_be32(credits); in rds_ib_cm_fill_conn_param()
259 dp->ricp_v4.dp_credit = cpu_to_be32(credits); in rds_ib_cm_fill_conn_param()
260 atomic_sub(IB_SET_POST_CREDITS(credits), in rds_ib_cm_fill_conn_param()
Dib_send.c407 void rds_ib_send_add_credits(struct rds_connection *conn, unsigned int credits) in rds_ib_send_add_credits() argument
411 if (credits == 0) in rds_ib_send_add_credits()
415 credits, in rds_ib_send_add_credits()
419 atomic_add(IB_SET_SEND_CREDITS(credits), &ic->i_credits); in rds_ib_send_add_credits()
423 WARN_ON(IB_GET_SEND_CREDITS(credits) >= 16384); in rds_ib_send_add_credits()
Dib.h437 void rds_ib_send_add_credits(struct rds_connection *conn, unsigned int credits);
/net/bluetooth/rfcomm/
Dcore.c62 static int rfcomm_send_credits(struct rfcomm_session *s, u8 addr, u8 credits);
979 pn->credits = RFCOMM_DEFAULT_CREDITS; in rfcomm_send_pn()
982 pn->credits = 0; in rfcomm_send_pn()
1163 static int rfcomm_send_credits(struct rfcomm_session *s, u8 addr, u8 credits) in rfcomm_send_credits() argument
1168 BT_DBG("%p addr %d credits %d", s, addr, credits); in rfcomm_send_credits()
1175 *ptr = credits; ptr++; in rfcomm_send_credits()
1407 d, d->state, d->dlci, pn->mtu, pn->flow_ctrl, pn->credits); in rfcomm_apply_pn()
1412 d->tx_credits = pn->credits; in rfcomm_apply_pn()
1717 u8 credits = *(u8 *) skb->data; skb_pull(skb, 1); in rfcomm_recv_data() local
1719 d->tx_credits += credits; in rfcomm_recv_data()
/net/bluetooth/
Dl2cap_core.c736 rsp.credits = cpu_to_le16(chan->rx_credits); in l2cap_chan_le_connect_reject()
1334 req.credits = cpu_to_le16(chan->rx_credits); in l2cap_le_connect()
3730 rsp.credits = cpu_to_le16(chan->rx_credits); in __l2cap_le_connect_rsp_defer()
5369 u16 dcid, mtu, mps, credits, result; in l2cap_le_connect_rsp() local
5379 credits = __le16_to_cpu(rsp->credits); in l2cap_le_connect_rsp()
5388 dcid, mtu, mps, credits, result); in l2cap_le_connect_rsp()
5413 chan->tx_credits = credits; in l2cap_le_connect_rsp()
5537 u16 dcid, scid, credits, mtu, mps; in l2cap_le_connect_req() local
5549 credits = 0; in l2cap_le_connect_req()
5620 l2cap_le_flowctl_init(chan, __le16_to_cpu(req->credits)); in l2cap_le_connect_req()
[all …]
/net/nfc/nci/
Dntf.c49 ntf->conn_entries[i].credits); in nci_core_conn_credits_ntf_packet()
56 atomic_add(ntf->conn_entries[i].credits, in nci_core_conn_credits_ntf_packet()