[openib-general] [PATCH][IPOIB] bring interface down panic

Shirley Ma xma at us.ibm.com
Wed Feb 16 15:51:58 PST 2005


I found a panic while testing a lock patch. 

In ipoib_mcast_dev_flush(), list_for_each_entry() should be 
list_for_each_entry_safe().

Here is the patch.

diff -urN infiniband/ulp/ipoib/ipoib_multicast.c 
infiniband-down/ulp/ipoib/ipoib_multicast.c
--- infiniband/ulp/ipoib/ipoib_multicast.c      2005-02-04 
16:05:13.000000000 -0800
+++ infiniband-down/ulp/ipoib/ipoib_multicast.c 2005-02-16 
15:49:42.278230248 -0800
@@ -790,7 +790,7 @@
 
        spin_unlock_irqrestore(&priv->lock, flags);
 
-       list_for_each_entry(mcast, &remove_list, list) {
+       list_for_each_entry_safe(mcast, tmcast, &remove_list, list) {
                ipoib_mcast_leave(dev, mcast);
                ipoib_mcast_free(mcast);
        }





Thanks
Shirley Ma
IBM Linux Technology Center
15300 SW Koll Parkway
Beaverton, OR 97006-6063
Phone(Fax): (503) 578-7638

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openfabrics.org/pipermail/general/attachments/20050216/7fc88a56/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: infiniband-down.patch
Type: application/octet-stream
Size: 507 bytes
Desc: not available
URL: <http://lists.openfabrics.org/pipermail/general/attachments/20050216/7fc88a56/attachment.obj>


More information about the general mailing list