[openib-general] Re: [PATCHv2] OpenSM: OpenIB vendor layer: Implement osm_vendor_d elete

Eitan Zahavi eitan at mellanox.co.il
Wed Sep 14 06:32:37 PDT 2005


Hal Rosenstock wrote:
> Hi Yael,
> 
> On Sun, 2005-09-11 at 04:11, Yael Kalka wrote: 
> 
>>There is a problem with the patch.
>>1. In osm_vendor_unbind: You used free(p_bind), when the pointer was
>>allocated using cl_zalloc.
>>   You need to use cl_free.
> 
> 
> OK.
> 
> 
>>2. There is a race between the cl_free and the receiver thread. We get
>>a segmentation fault due to the fact that the thread isn't destroyed
>>before freeing the p_bind object. There should be a way to signal the
>>reciever thread to exit, and the unbind should wait for that thread to
>>join.
> 
> 
> How can I reproduce that seg fault ? I never saw that in my testing of
> this.
For us it happened every time we run OpenSM: SuSE Linux 9.3, 2.6.11.4-20a-smp
I think it depends on the OS or the way glibc was compiled: gcc (GCC) 3.3.5 20050117 (prerelease) (SUSE Linux)

> 
> I will issue an updated version of this patch when I fix these issues.
> Thanks.
> 
> -- Hal
> 




More information about the general mailing list