Cute, but paying that penalty for every open() on a filesystem which
isn't a module (true for 99%, ext2 root) seems a little harsh. Hmm,
could be cached, but Al's solution has the advantage of not making me
want to barf...
> While we're at it - can we get rid of MOD_INC_USE_COUNT and
> __MOD_INC_USE_COUNT altogether to force people to be aware of the need for
> try_inc_mod_count and checking its return value? First thing in 2.5 along
> with removing sleep_on() ?
Are you volunteering to go through net/ipv4/netfilter/ and change them
all? Because that'd be really great!
For 2.5, I'd prefer the two-stage cleanup solution, because it is easy
for module writers to understand (`deactivate' deregisters so that
module counts won't increase after sys_del_module syncs bhs, `cleanup'
frees resources), allows module counts to increment inside interrupt
handlers, is simple to write assertions to check behaviour, and for
code like mine, avoids the ugly `loop and schedule()' in cleanup().
But that's a long way away, and getting furthur,
Rusty.
-- Hacking time.- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/