[openib-general] Re: [PATH] problem dlopen libibverbs.so
Michael S. Tsirkin
mst at mellanox.co.il
Wed Jul 20 23:27:44 PDT 2005
Quoting r. Gleb Natapov <glebn at voltaire.com>:
> Subject: Re: [PATH] problem dlopen libibverbs.so
>
> On Thu, Jul 21, 2005 at 01:18:30AM +0300, Michael S. Tsirkin wrote:
> > Quoting r. Roland Dreier <rolandd at cisco.com>:
> > > Subject: Re: [PATH] problem dlopen libibverbs.so
> > >
> > > Michael> I wander if its a better idea to scan the plugin
> > > Michael> directory on ibv_get_devices. Seems to me it might be
> > > Michael> more debuggable for applications if they get error
> > > Michael> messages when they call ibv_get_devices, and not at
> > > Michael> startup: they can step in debugger to figure out what is
> > > Michael> printing these things.
> > >
> > > Michael> Roland, would you take such a patch?
> > >
> > > I was thinking the same thing -- lazy initialization of libibverbs
> > > when it is first use. So yes, such a patch would be useful.
> > >
> > > - R.
> > >
> >
> > Question:
> >
> > dlist_for_each_data(driver_list, driver, struct ibv_driver) {
> > dev = driver->init_func(verbs_dev);
> > if (dev) {
> > dev->dev = verbs_dev;
> > dev->ibdev = ib_dev;
> > dev->driver = driver;
> >
> > dlist_push(device_list, dev);
> >
> > return;
> > }
> > }
> >
> > Why is this done at library initialization?
> > Wouldnt device opening be a better place?
> > Am I missing something?
>
> If you are going to rewrite library initialisation and device discovery
Probably not yet :).
> perhaps you should write support for hotpluggable devices too? Currently
> libibdev scans sysfs only once during init. What if device was plugged
> after application was launched?
>
> What do you think?
I have hotplug in the cards, but cant commit to any specific dates.
--
MST
More information about the general
mailing list