IPoIB/cm: Fix timeout check in ipoib_cm_dev_stop()
authorMichael S. Tsirkin <mst@dev.mellanox.co.il>
Thu, 24 May 2007 21:02:39 +0000 (14:02 -0700)
committerRoland Dreier <rolandd@cisco.com>
Thu, 24 May 2007 21:02:39 +0000 (14:02 -0700)
time_after() was used backwards, so the timeout occurred immediately.

Signed-off-by: Michael S. Tsirkin <mst@dev.mellanox.co.il>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
drivers/infiniband/ulp/ipoib/ipoib_cm.c

index ffec794b7913d6470bc2f3409a9fadd93c446cb2..e8fcd628be73fcca1791b505c01471e0f0c42ca0 100644 (file)
@@ -713,7 +713,7 @@ void ipoib_cm_dev_stop(struct net_device *dev)
        while (!list_empty(&priv->cm.rx_error_list) ||
               !list_empty(&priv->cm.rx_flush_list) ||
               !list_empty(&priv->cm.rx_drain_list)) {
-               if (!time_after(jiffies, begin + 5 * HZ)) {
+               if (time_after(jiffies, begin + 5 * HZ)) {
                        ipoib_warn(priv, "RX drain timing out\n");
 
                        /*