Reorder test_root testing from 3,5,7 to 7,5,3 so that average case becomes good. Even number check is added. Signed-off-by: Prasanna Meda --- a/fs/ext3/balloc.c Fri Jan 28 22:21:45 2005 +++ b/fs/ext3/balloc.c Sat Jan 29 02:51:39 2005 @@ -1451,8 +1451,10 @@ { if (group <= 1) return 1; - return (test_root(group, 3) || test_root(group, 5) || - test_root(group, 7)); + if (!(group & 1)) + return 0; + return (test_root(group, 7) || test_root(group, 5) || + test_root(group, 3)); } /**