提交 d39e0602 编写于 作者: S Steve Wise 提交者: David S. Miller

RDS/IW+IB: Set the RDS_LL_SEND_FULL bit when we're throttled.

The RDS_LL_SEND_FULL bit should be set when we stop transmitted due to
flow control.  Otherwise the send worker will keep trying as opposed to
sleeping until we unthrottle.  Saves CPU.
Signed-off-by: NSteve Wise <swise@opengridcomputing.com>
Signed-off-by: NAndy Grover <andy.grover@oracle.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 11bc9421
...@@ -506,7 +506,7 @@ int rds_ib_xmit(struct rds_connection *conn, struct rds_message *rm, ...@@ -506,7 +506,7 @@ int rds_ib_xmit(struct rds_connection *conn, struct rds_message *rm,
flow_controlled++; flow_controlled++;
} }
if (work_alloc == 0) { if (work_alloc == 0) {
rds_ib_ring_unalloc(&ic->i_send_ring, work_alloc); set_bit(RDS_LL_SEND_FULL, &conn->c_flags);
rds_ib_stats_inc(s_ib_tx_throttle); rds_ib_stats_inc(s_ib_tx_throttle);
ret = -ENOMEM; ret = -ENOMEM;
goto out; goto out;
......
...@@ -549,7 +549,7 @@ int rds_iw_xmit(struct rds_connection *conn, struct rds_message *rm, ...@@ -549,7 +549,7 @@ int rds_iw_xmit(struct rds_connection *conn, struct rds_message *rm,
flow_controlled++; flow_controlled++;
} }
if (work_alloc == 0) { if (work_alloc == 0) {
rds_iw_ring_unalloc(&ic->i_send_ring, work_alloc); set_bit(RDS_LL_SEND_FULL, &conn->c_flags);
rds_iw_stats_inc(s_iw_tx_throttle); rds_iw_stats_inc(s_iw_tx_throttle);
ret = -ENOMEM; ret = -ENOMEM;
goto out; goto out;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册