[openib-general] [openfabrics-ewg] OFED-1.1-rc4 is ready
Robert Walsh
rjwalsh at pathscale.com
Wed Sep 13 15:49:25 PDT 2006
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
> I don't think you can do symbol versioning here.
Right - probably being a little more verbose about finding the file but
not the symbol would be a good idea, though. It took me a bit of gdb
work to track the problem down: not really a big deal, but a clearer
error might have helped.
Another idea (I haven't thought the implications through yet - just
throwing it out there) is to dlsym() a "version" symbol that the library
is expected to provide and check that it matches what you expect it to:
sort of like the way the user verbs stuff checks that the kernel uverbs
module matches it. If dlsym() fails to find a symbol, then you're
running an older one anyway.
None of this helps at compile time, where it would be preferable to spot
the problem. Another not-really-sat-down-and-thought-about-it idea is
to have something like this in infiniband/driver.h:
#define VERBS_LIBRARY_VERSION 2
#ifdef VERBS_DRIVER_VERSION
#if VERBS_DRIVER_VERSION != VERBS_LIBRARY_VERSION
#error verbs library version doesn't match driver version.
#endif
#endif
The VERBS_LIBRARY_VERSION would be bumped on an API change.
VERBS_DRIVER_VERSION would be defined in the driver library (in mthca.h,
ipathverbs.h and ehca_uinit.c) and would be updated to match.
Just brainstorming. Anyone else got any thoughts or suggestions?
Regards,
Robert.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org
iQEVAwUBRQiK9fzvnpzTd9fxAQLIEAf9G56jSWtGyG3kFwnbV7WpMNVmuA04xvm4
FA/y3BwjsNAckfBGm+13BVUuvqs9idm7UmC82jaXxIvm+cwoDNfBXSUj/4VqJW/y
ZHESz0ulcyNXEhEANoIFb2NjmL1Fadl8cWEPW9rDPxyw7eSke/Wd1a8qwkKA+1dq
L9L5+Cp72IV+5cKm4EPqV+R+MeO5UjNkd06/g4XVKVuEMYhnTvBhpu9ePt+mZ1zP
otwwC/eI5ngvMAk2thBQfi0zEaFkqiLkiEUGP/PofmaJZuN4lcp1R/2FSiP7K2fj
3KY6HLGl+6wDpjJ0PpnIhSp3h3vFkeRFtJHKhNhOr+vM8qiGrQTlHg==
=LVqb
-----END PGP SIGNATURE-----
More information about the general
mailing list