On Thu, 17 May 2012, Glauber Costa wrote: > > Why can this processing not be done when sysfs has just been initialized? > > If we can be 100 % sure that idr/ida is always initialized before sysfs, than > yes, we can. idr_init_cache() is run even before kmem_cache_init_late(). Have a look at init/main.c. No need to muck with the bootup sequence. > > The reason to use == is because we want things to happen only at a > > particular stage of things. The == SYSFS means we will only do an action > > if the slab system is fully functional. Such things will have to be > > reevaluated if the number of states change. > > Yes, but you are actually arguing in my favor. "fully functional" means >= > SYSFS, not == SYSFS. That is only true if you add another state. > If for whatever reordering people may decide doing another state is added, or > this function is called later, that will fail Then the assumptions that SYSFS is the final state is no longer true and therefore the code needs to be inspected if this change affects anything. -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@xxxxxxxxx. For more info on Linux MM, see: http://www.linux-mm.org/ . Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/ Don't email: <a href=mailto:"dont@xxxxxxxxx"> email@xxxxxxxxx </a>