The patch titled Subject: kasan-slub-fix-handling-of-kasan_slab_free-hook-v2 has been removed from the -mm tree. Its filename was kasan-slub-fix-handling-of-kasan_slab_free-hook-v2.patch This patch was dropped because it was folded into kasan-slub-fix-handling-of-kasan_slab_free-hook.patch ------------------------------------------------------ From: Andrey Konovalov <andreyknvl@xxxxxxxxxx> Subject: kasan-slub-fix-handling-of-kasan_slab_free-hook-v2 - Made slab_free_freelist_hook return bool and return true when KASAN is disabled. That should eliminate unnecessary branch in slab_free. Link: http://lkml.kernel.org/r/a62759a2545fddf69b0c034547212ca1eb1b3ce2.1520359686.git.andreyknvl@xxxxxxxxxx Signed-off-by: Andrey Konovalov <andreyknvl@xxxxxxxxxx> Acked-by: Andrey Ryabinin <aryabinin@xxxxxxxxxxxxx> Cc: Christoph Lameter <cl@xxxxxxxxx> Cc: Pekka Enberg <penberg@xxxxxxxxxx> Cc: David Rientjes <rientjes@xxxxxxxxxx> Cc: Joonsoo Kim <iamjoonsoo.kim@xxxxxxx> Cc: Alexander Potapenko <glider@xxxxxxxxxx> Cc: Dmitry Vyukov <dvyukov@xxxxxxxxxx> Cc: Kostya Serebryany <kcc@xxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- diff -puN mm/slub.c~kasan-slub-fix-handling-of-kasan_slab_free-hook-v2 mm/slub.c --- a/mm/slub.c~kasan-slub-fix-handling-of-kasan_slab_free-hook-v2 +++ a/mm/slub.c @@ -1388,7 +1388,7 @@ static __always_inline bool slab_free_ho return kasan_slab_free(s, x, _RET_IP_); } -static inline void slab_free_freelist_hook(struct kmem_cache *s, +static inline bool slab_free_freelist_hook(struct kmem_cache *s, void **head, void **tail) { /* @@ -1423,6 +1423,10 @@ static inline void slab_free_freelist_ho if (*head == *tail) *tail = NULL; + + return *head != NULL; +#else + return true; #endif } @@ -2981,8 +2985,7 @@ static __always_inline void slab_free(st * With KASAN enabled slab_free_freelist_hook modifies the freelist * to remove objects, whose reuse must be delayed. */ - slab_free_freelist_hook(s, &head, &tail); - if (head != NULL) + if (slab_free_freelist_hook(s, &head, &tail)) do_slab_free(s, page, head, tail, cnt, addr); } _ Patches currently in -mm which might be from andreyknvl@xxxxxxxxxx are kasan-slub-fix-handling-of-kasan_slab_free-hook.patch kasan-fix-invalid-free-test-crashing-the-kernel.patch kasan-disallow-compiler-to-optimize-away-memset-in-tests.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html