Robert> Well, it needs to be refcounted, as we need to create it
Robert> on first add_one and remove it on the last remove_one. If
Robert> I put a spinlock around it, would that suffice?
Yes, that should be fine, although I assume you'll need to set a flag
and then create the file outside the lock. (I guess you could also
get fancy and use atomic_inc_return() and atomic_dec_and_test() too if
you wanted).
I'm still curious -- what is the problem with creating the file before
any devices are found? Why does modprobe get stuck?
- R.
_______________________________________________
openib-general mailing list
[email protected]
http://openib.org/mailman/listinfo/openib-general
To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general