this change is wrong.

you need read_unlock(&kmxlnd_data.kmx_peers_lock); before return from
mxlnd_get_peer_info to avoid leak lock.


diff -pru ../lustre-old/lnet/klnds/mxlnd/mxlnd_cb.c
./lnet/klnds/mxlnd/mxlnd_cb.c
--- ../lustre-old/lnet/klnds/mxlnd/mxlnd_cb.c   2007-02-09
19:04:46.000000000 -0500
+++ ./lnet/klnds/mxlnd/mxlnd_cb.c       2007-04-13 09:24:50.000000000
-0400
@@ -1099,6 +1099,7 @@ mxlnd_get_peer_info(int index, lnet_nid_
 
                         *nidp = peer->mxp_nid;
                         *count = atomic_read(&peer->mxp_refcount);
+                        return 0;
                 }
         }
         read_unlock(&kmxlnd_data.kmx_peers_lock);


On Fri, 2007-04-13 at 18:01, Scott Atchley wrote:
> Hi Eric,
> 
> I forgot to include one other small change. The corrected patch is  
> attached.
> 
> Scott
> 
> 
> ______________________________________________________________________
> _______________________________________________
> Lustre-devel mailing list
> [EMAIL PROTECTED]
> https://mail.clusterfs.com/mailman/listinfo/lustre-devel
-- 
Alexey Lyashkov <[EMAIL PROTECTED]>
Beaver team

_______________________________________________
Lustre-devel mailing list
[EMAIL PROTECTED]
https://mail.clusterfs.com/mailman/listinfo/lustre-devel

Reply via email to