IB/ipoib: Suppress the retry related completion errors
authorSantosh Shilimkar <santosh.shilimkar@oracle.com>
Thu, 7 Sep 2017 10:38:18 +0000 (13:38 +0300)
committerDoug Ledford <dledford@redhat.com>
Fri, 22 Sep 2017 17:12:36 +0000 (13:12 -0400)
IPoIB doesn't support transport/rnr retry schemes as per
RFC so those errors are expected. No need to flood the
log files with them.

Tested-by: Michael Nowak <michael.nowak@oracle.com>
Tested-by: Rafael Alejandro Peralez <rafael.peralez@oracle.com>
Tested-by: Liwen Huang <liwen.huang@oracle.com>
Tested-by: Hong Liu <hong.x.liu@oracle.com>
Reviewed-by: Mukesh Kacker <mukesh.kacker@oracle.com>
Reported-by: Rajiv Raja <rajiv.raja@oracle.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@oracle.com>
Signed-off-by: Yuval Shaia <yuval.shaia@oracle.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/ulp/ipoib/ipoib_cm.c

index 14b62f7472b4f6632f344d7d4ac2eb81518cf3c8..7774654c2ccbce600f99e751c7b37e15e7f1dd8a 100644 (file)
@@ -823,12 +823,18 @@ void ipoib_cm_handle_tx_wc(struct net_device *dev, struct ib_wc *wc)
            wc->status != IB_WC_WR_FLUSH_ERR) {
                struct ipoib_neigh *neigh;
 
-               if (wc->status != IB_WC_RNR_RETRY_EXC_ERR)
-                       ipoib_warn(priv, "failed cm send event (status=%d, wrid=%d vend_err %x)\n",
-                                  wc->status, wr_id, wc->vendor_err);
+               /* IB_WC[_RNR]_RETRY_EXC_ERR error is part of the life cycle,
+                * so don't make waves.
+                */
+               if (wc->status == IB_WC_RNR_RETRY_EXC_ERR ||
+                   wc->status == IB_WC_RETRY_EXC_ERR)
+                       ipoib_dbg(priv,
+                                 "%s: failed cm send event (status=%d, wrid=%d vend_err 0x%x)\n",
+                                  __func__, wc->status, wr_id, wc->vendor_err);
                else
-                       ipoib_dbg(priv, "failed cm send event (status=%d, wrid=%d vend_err %x)\n",
-                                 wc->status, wr_id, wc->vendor_err);
+                       ipoib_warn(priv,
+                                   "%s: failed cm send event (status=%d, wrid=%d vend_err 0x%x)\n",
+                                  __func__, wc->status, wr_id, wc->vendor_err);
 
                spin_lock_irqsave(&priv->lock, flags);
                neigh = tx->neigh;