[openib-general] ipoib lockdep warning
Roland Dreier
rdreier at cisco.com
Tue Jul 11 16:43:18 PDT 2006
Hmm, good point.
It sort of seems to me like the idr interfaces are broken by design.
Internally, lib/idr.c uses bare spin_lock(&idp->lock) with no
interrupt disabling or anything in both the idr_pre_get() and
idr_get_new() code paths. But idr_pre_get() is supposed to be called
in a context that can sleep, while idr_get_new() is supposed to be
called with locks held to serialize things (at least according to
http://lwn.net/Articles/103209/).
So, ugh... maybe the best thing to do is change lib/idr.c to use
spin_lock_irqsave() internally?
- R.
More information about the general
mailing list