It looks like this assignment is not needed at all if "wait_for_prunes" is moved after dput(root), since no more dentries should exist after that point and wakeup can not potentially happen.+ /* avoid further wakeups */
+ sb->s_pending_iputs = 65000;
This looks a bit ugly, what is 65000?
Just the first big number that came to by head... probably not needed.
ok, I would rather use a const or a #define and hide it under a
meaningful name, with comments. If it is not needed, then nothing like
avoiding magic numbers.