[openib-general] Re: [PATH] problem dlopen libibverbs.so

Gleb Natapov glebn at voltaire.com
Wed Jul 20 12:05:35 PDT 2005


On Wed, Jul 20, 2005 at 06:45:09PM +0300, Michael S. Tsirkin wrote:
> Quoting r. Gleb Natapov <glebn at voltaire.com>:
> > > > > What about passing RTLD_GLOBAL to dlopen, instead?
> > > >
> > > > The strange thing is it doesn't work, but it should according to man
> > > > page.
> > > 
> > > Better debug it then.
> > > 
> > It seems that RTLD_GLOBAL doesn't work as expected because libibverbs
> > calls ldopen from constructor and it is to early for RTLD_GLOBAL to take
> > effect. If I ldopen mthca.so after dlopen ("libibverbs.so", RTLD_NOW | RTLD_GLOBAL) 
> > returns it actually succeeds. But alas it it to late.
> > 
> 
> I wander if its a better idea to scan the plugin directory on ibv_get_devices.
> Seems to me it might be more debuggable for applications if they get
> error messages when they call ibv_get_devices, and not at startup:
> they can step in debugger to figure out what is printing these things.
> 
I thought the same thing.

--
			Gleb.



More information about the general mailing list