Signed-off-by: Irena Gannon ([email protected]<mailto:[email protected]>)

Acquire the mad_lock before accessing the mad_list in __free_mads

Index: B:/users/irena/proj1/trunk/core/al/al.c
===================================================================
--- B:/users/irena/proj1/trunk/core/al/al.c          (revision 6997)
+++ B:/users/irena/proj1/trunk/core/al/al.c       (revision 6998)
@@ -132,6 +132,7 @@
                ib_api_status_t                                                
status;

                /* Return all outstanding MADs to their MAD pools. */
+             cl_spinlock_acquire( &h_al->mad_lock);
                for( p_list_item = cl_qlist_head( &h_al->mad_list );
                                 p_list_item != cl_qlist_end( &h_al->mad_list );
                                 p_list_item = cl_qlist_head( &h_al->mad_list ) 
)
@@ -147,6 +148,7 @@
                                                                
ib_get_err_str(status)) );
                                }
                }
+             cl_spinlock_release( &h_al->mad_lock);
 }


Attachment: free_mads.patch
Description: free_mads.patch

_______________________________________________
ofw mailing list
[email protected]
http://lists.openfabrics.org/cgi-bin/mailman/listinfo/ofw

Reply via email to