[Fwd: Re: [openib-general] ib_verbs.h ib_device_attr device type]

Hal Rosenstock halr at voltaire.com
Wed Sep 1 09:15:53 PDT 2004


On Wed, 2004-09-01 at 10:52, Sean Hefty wrote:
> On Wed, 01 Sep 2004 10:58:45 -0400
> One question though, where are these flags set in the ib_device 
> structure?  

I would think that this would be done when the device driver is notified
by PCI that the device is present (and would be done inside
mthca_provider.c:mthca_register_device() where it is setting up all the
other ib_device fields). Since the entire mthca_dev structure is cleared
via memset (in mthca_main.c:mthca_init_one), the flags are 0 as is
correct for an HCA.

> I was looking at this request yesterday and thought 
> about extending the ib_device_cap_flags, but these seemed a little 
> different.  Maybe we could call the enum ib_device_type and add a 
> new field to ib_device?

device_cap is different from this (and device_type is better). It could
be done this way as well (as using the device flags).

-- Hal




More information about the general mailing list