Vladimir Sokolovsky wrote:
> Hi Yossi,
> Please send this patch in the "OFED" format:
> kernel_patches/fixes/ipoib... with backports (if required).
> 
> Thanks,
> Vladimir

Here is:

diff --git a/kernel_patches/fixes/ipoib_0560_clear_admin_up_flag.patch 
b/kernel_patches/fixes/ipoib_0560_clear_admin_up_flag.patch
new file mode 100644
index 0000000..78b8a67
--- /dev/null
+++ b/kernel_patches/fixes/ipoib_0560_clear_admin_up_flag.patch
@@ -0,0 +1,39 @@
+ipoib: clear IPOIB_FLAG_ADMIN_UP if ipoib_open fails
+
+  If ipoib_open() fails, it should clear IPOIB_FLAG_ADMIN_UP bit and not
+leave if on.
+This is already fixed in 2.6.30.
+
+Reported-by: Jack Morgenstein <ja...@dev.mellanox.co.il>
+Signed-off-by: Yossi Etigin <yos...@voltaire.com>
+
+---
+
+Index: b/drivers/infiniband/ulp/ipoib/ipoib_main.c
+===================================================================
+--- a/drivers/infiniband/ulp/ipoib/ipoib_main.c        2009-04-22 
19:45:11.000000000 +0300
++++ b/drivers/infiniband/ulp/ipoib/ipoib_main.c        2009-04-22 
19:51:51.000000000 +0300
+@@ -112,11 +112,11 @@ int ipoib_open(struct net_device *dev)
+               return 0;
+ 
+       if (ipoib_ib_dev_open(dev))
+-              return -EINVAL;
++              goto err;
+ 
+       if (ipoib_ib_dev_up(dev)) {
+               ipoib_ib_dev_stop(dev, 1);
+-              return -EINVAL;
++              goto err;
+       }
+ 
+       if (!test_bit(IPOIB_FLAG_SUBINTERFACE, &priv->flags)) {
+@@ -139,6 +139,9 @@ int ipoib_open(struct net_device *dev)
+       netif_start_queue(dev);
+ 
+       return 0;
++err:
++      clear_bit(IPOIB_FLAG_ADMIN_UP, &priv->flags);
++      return -EINVAL;
+ }
+ 
+ static int ipoib_stop(struct net_device *dev)
_______________________________________________
ewg mailing list
ewg@lists.openfabrics.org
http://lists.openfabrics.org/cgi-bin/mailman/listinfo/ewg

Reply via email to