[openib-general] Couple of questions on struct ib_device
Roland Dreier
roland at topspin.com
Tue Aug 17 17:32:01 PDT 2004
Krishna> Hi, I was looking at ib_verbs.h and I am confused about
Krishna> one thing : why are entry points like open_hca,
Krishna> modify_hca and close_hca missing ?
Not sure which version of ib_verbs.h you were looking at. If you were
looking in my branch then the structure is incomplete. In any case,
modify_hca will be split into modify_port and modify_device functions.
I'm not sure we really need open_hca and close_hca (at least as
defined in the spec), and in any case I think this will be handled in
the access layer (the low-level driver doesn't need to handle the
reference counting or anything else). I expect to get a better idea
about this as I implement device model/sysfs stuff.
Krishna> Also, is there any value in encapsulating the various
Krishna> functions of ib_device into a different structure, like
Krishna> ib_device_ops or something rather than having a visually
Krishna> huge structure that we have today ?
Maybe, but the kernel currently has far bigger structures such as
struct net_device or struct task_struct. We can just keep the
function pointers separate in the declaration of struct ib_device.
- R.
More information about the general
mailing list