[openib-general] Re: [PATCH] Opensm - fix segfault on exit - cont.

Hal Rosenstock halr at voltaire.com
Mon Dec 19 03:41:53 PST 2005


Hi Yael,

On Mon, 2005-12-19 at 04:19, Yael Kalka wrote:
> Hi Hal,
> 
> I've noticed that under certain operating systems,

Seems more likely like a compiler difference rather than OS difference.
Can you mention on which distribution/compiler this made a difference ?

> when driver isn't 
> loaded, the SM still exits with segfault.
> The following patch fixes this.
> 
> Thanks,
> Yael
> 
> Signed-off-by:  Yael Kalka <yael at mellanox.co.il>
> 
> Index: libvendor/osm_vendor_ibumad.c
> ===================================================================
> --- libvendor/osm_vendor_ibumad.c       (revision 4522)
> +++ libvendor/osm_vendor_ibumad.c       (working copy)
> @@ -552,7 +552,7 @@ osm_vendor_delete(
>  
>         /* umad receiver thread ? */
>         p_ur = (*pp_vend)->receiver;
> -       if (&p_ur->signal)
> +       if (&p_ur->signal != NULL)

If this makes a difference, there are other uses of similar syntax which
should be changed :-(

>                 cl_event_destroy( &p_ur->signal );
>         cl_spinlock_destroy( &(*pp_vend)->cb_lock );
>         cl_spinlock_destroy( &(*pp_vend)->match_tbl_lock );

-- Hal




More information about the general mailing list