From: Matt Mackall We weren't merging freed blocks at the beginning of the free list. Fixing this showed a 2.5% efficiency improvement in a userspace test harness. Signed-off-by: Matt Mackall Signed-off-by: Andrew Morton --- mm/slob.c | 4 ++++ 1 file changed, 4 insertions(+) diff -puN mm/slob.c~slob-fix-free-block-merging-at-head-of-subpage mm/slob.c --- a/mm/slob.c~slob-fix-free-block-merging-at-head-of-subpage +++ a/mm/slob.c @@ -398,6 +398,10 @@ static void slob_free(void *block, int s sp->units += units; if (b < sp->free) { + if (b + units == sp->free) { + units += slob_units(sp->free); + sp->free = slob_next(sp->free); + } set_slob(b, units, sp->free); sp->free = b; } else { _