IB/rxe: Avoid accessing timers for non RC QPs
Subsystems (2)
PATCH 1/2 IB/rxe: Avoid accessing timers for non RC QPs
From: Parav Pandit <parav-VPRAkNaXOzVWk0Htik3J/[email protected]>
This patch avoids RNR NAK timer and retransmit timer initialization and cleanup for non RC QPs (such as UD QP, GSI QP).
--- drivers/infiniband/sw/rxe/rxe_qp.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-)
drivers/infiniband/sw/rxe/rxe_qp.c +8 -5
@@ -273,10 +273,11 @@ static int rxe_qp_init_req(struct rxe_dev *rxe, struct rxe_qp *qp,rxe_init_task (rxe, &qp->comp.task, qp, rxe_completer,"comp" ); -setup_timer (&qp->rnr_nak_timer, rnr_nak_timer, (unsigned long )qp); -setup_timer (&qp->retrans_timer, retransmit_timer, (unsigned long )qp); qp->qp_timeout_jiffies =0 ;/* Can't be set for UD/UC in modify_qp */ - +if (init->qp_type ==IB_QPT_RC ) { +setup_timer (&qp->rnr_nak_timer, rnr_nak_timer, (unsigned long )qp); +setup_timer (&qp->retrans_timer, retransmit_timer, (unsigned long )qp); + }return 0 ; }
@@ -804,8 +805,10 @@ void rxe_qp_destroy(struct rxe_qp *qp) qp->qp_timeout_jiffies =0 ;rxe_cleanup_task (&qp->resp.task); -del_timer_sync (&qp->retrans_timer); -del_timer_sync (&qp->rnr_nak_timer); +if (qp_type (qp) ==IB_QPT_RC ) { +del_timer_sync (&qp->retrans_timer); +del_timer_sync (&qp->rnr_nak_timer); + }rxe_cleanup_task (&qp->req.task);rxe_cleanup_task (&qp->comp.task);
Signature · 6 lines
2.12.0 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 20170319092057.9103-1-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org
PATCH 2/2 IB/rxe: Do not export module's private function
From: Parav Pandit <parav-VPRAkNaXOzVWk0Htik3J/[email protected]>
Function rxe_rcv is used internally in RXE and don't need to be exported. This patch removes such export declaration.
--- drivers/infiniband/sw/rxe/rxe_recv.c | 1 - 1 file changed, 1 deletion(-)
drivers/infiniband/sw/rxe/rxe_recv.c +0 -1
@@ -417,4 +417,3 @@ int rxe_rcv(struct sk_buff *skb)kfree_skb (skb);return 0 ; } -EXPORT_SYMBOL (rxe_rcv);
Signature · 6 lines
2.12.0 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 20170319092057.9103-2-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org
Yuval Shaia
Reviewed-byRe: [PATCH rdma-next 2/2] IB/rxe: Do not export module's private function
Quoted 16 lines · Leon Romanovsky
From: Parav Pandit <parav-VPRAkNaXOzVWk0Htik3J/[email protected]>
Function
rxe_rcvis used internally in RXE and don't need to be exported. This patch removes such export declaration.Signed-off-by Leon Romanovsky <[email protected]>--- drivers/infiniband/sw/rxe/rxe_recv.c | 1 - 1 file changed, 1 deletion(-)drivers/infiniband/sw/rxe/rxe_recv.c +0
-0
drivers/infiniband/sw/rxe/rxe_recv.c int rxe_rcv(struct sk_buff *skb) · line 420
Quoted 4 lines
drivers/infiniband/sw/rxe/rxe_recv.c +0
-1@@ -417,4 +417,3 @@ int rxe_rcv(struct sk_buff *skb)kfree_skb (skb);return 0 ; } -EXPORT_SYMBOL (rxe_rcv);
Quoted 7 lines
Signature · 6 lines
2.12.0 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Doug Ledford
AppliedRe: [PATCH rdma-next 2/2] IB/rxe: Do not export module's private function
In reply to a message not in the archiveQuoted 7 lines · Leon Romanovsky
From: Parav Pandit <parav-VPRAkNaXOzVWk0Htik3J/[email protected]>
Function
rxe_rcvis used internally in RXE and don't need to be exported. This patch removes such export declaration.Signed-off-by Leon Romanovsky <[email protected]>
Thanks, applied.
Signature · 9 lines
Doug Ledford <[email protected]> GPG KeyID: B826A3330E572FDD Key fingerprint = AE6B 1BDA 122B 23B4 265B 1274 B826 A333 0E57 2FDD -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Yuval Shaia
Reviewed-byQuoted 32 lines · Leon Romanovsky
From: Parav Pandit <parav-VPRAkNaXOzVWk0Htik3J/[email protected]>
This patch avoids RNR NAK timer and retransmit timer initialization and cleanup for non RC QPs (such as UD QP, GSI QP).
Signed-off-by Leon Romanovsky <[email protected]>--- drivers/infiniband/sw/rxe/rxe_qp.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-)drivers/infiniband/sw/rxe/rxe_qp.c +4
-3@@ -273,10 +273,11 @@ static int rxe_qp_init_req(struct rxe_dev *rxe, struct rxe_qp *qp,rxe_init_task (rxe, &qp->comp.task, qp, rxe_completer,"comp" ); -setup_timer (&qp->rnr_nak_timer, rnr_nak_timer, (unsigned long )qp); -setup_timer (&qp->retrans_timer, retransmit_timer, (unsigned long )qp); qp->qp_timeout_jiffies =0 ;/* Can't be set for UD/UC in modify_qp */ - +if (init->qp_type ==IB_QPT_RC ) { +setup_timer (&qp->rnr_nak_timer, rnr_nak_timer, (unsigned long )qp); +setup_timer (&qp->retrans_timer, retransmit_timer, (unsigned long )qp); + }return 0 ; }
drivers/infiniband/sw/rxe/rxe_qp.c void rxe_qp_destroy(struct rxe_qp *qp) · line 811
Quoted 9 lines
drivers/infiniband/sw/rxe/rxe_qp.c +4
-2@@ -804,8 +805,10 @@ void rxe_qp_destroy(struct rxe_qp *qp) qp->qp_timeout_jiffies =0 ;rxe_cleanup_task (&qp->resp.task); -del_timer_sync (&qp->retrans_timer); -del_timer_sync (&qp->rnr_nak_timer); +if (qp_type (qp) ==IB_QPT_RC ) { +del_timer_sync (&qp->retrans_timer); +del_timer_sync (&qp->rnr_nak_timer); + }
Quoted 10 lines
drivers/infiniband/sw/rxe/rxe_qp.c +0
-0rxe_cleanup_task (&qp->req.task);rxe_cleanup_task (&qp->comp.task);Signature · 6 lines
2.12.0 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Doug Ledford
AppliedQuoted 9 lines · Leon Romanovsky
From: Parav Pandit <parav-VPRAkNaXOzVWk0Htik3J/[email protected]>
This patch avoids RNR NAK timer and retransmit timer initialization and
cleanup for non RC QPs (such as UD QP, GSI QP).Signed-off-by Leon Romanovsky <[email protected]>
Thanks, applied.
Signature · 9 lines
Doug Ledford <[email protected]> GPG KeyID: B826A3330E572FDD Key fingerprint = AE6B 1BDA 122B 23B4 265B 1274 B826 A333 0E57 2FDD -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html