https://github.com/torvalds/linux
Revision 928501344fc645f80390afc12708c81b3595745d authored by Andrey Konovalov on 26 February 2021, 01:19:55 UTC, committed by Linus Torvalds on 26 February 2021, 17:41:02 UTC
Patch series "kasan: optimizations and fixes for HW_TAGS", v4. This patchset makes the HW_TAGS mode more efficient, mostly by reworking poisoning approaches and simplifying/inlining some internal helpers. With this change, the overhead of HW_TAGS annotations excluding setting and checking memory tags is ~3%. The performance impact caused by tags will be unknown until we have hardware that supports MTE. As a side-effect, this patchset speeds up generic KASAN by ~15%. This patch (of 13): Currently KASAN saves allocation stacks in both kasan_slab_alloc() and kasan_kmalloc() annotations. This patch changes KASAN to save allocation stacks for slab objects from kmalloc caches in kasan_kmalloc() only, and stacks for other slab objects in kasan_slab_alloc() only. This change requires ____kasan_kmalloc() knowing whether the object belongs to a kmalloc cache. This is implemented by adding a flag field to the kasan_info structure. That flag is only set for kmalloc caches via a new kasan_cache_create_kmalloc() annotation. Link: https://lkml.kernel.org/r/cover.1612546384.git.andreyknvl@google.com Link: https://lkml.kernel.org/r/7c673ebca8d00f40a7ad6f04ab9a2bddeeae2097.1612546384.git.andreyknvl@google.com Signed-off-by: Andrey Konovalov <andreyknvl@google.com> Reviewed-by: Marco Elver <elver@google.com> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Vincenzo Frascino <vincenzo.frascino@arm.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: Alexander Potapenko <glider@google.com> Cc: Will Deacon <will.deacon@arm.com> Cc: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Peter Collingbourne <pcc@google.com> Cc: Evgenii Stepanov <eugenis@google.com> Cc: Branislav Rankov <Branislav.Rankov@arm.com> Cc: Kevin Brodsky <kevin.brodsky@arm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent d3a61f7
Tip revision: 928501344fc645f80390afc12708c81b3595745d authored by Andrey Konovalov on 26 February 2021, 01:19:55 UTC
kasan, mm: don't save alloc stacks twice
kasan, mm: don't save alloc stacks twice
Tip revision: 9285013
File | Mode | Size |
---|---|---|
Kconfig | -rw-r--r-- | 8.2 KB |
Makefile | -rw-r--r-- | 2.0 KB |
ca0132_regs.h | -rw-r--r-- | 13.4 KB |
hda_auto_parser.c | -rw-r--r-- | 29.3 KB |
hda_auto_parser.h | -rw-r--r-- | 3.3 KB |
hda_beep.c | -rw-r--r-- | 7.9 KB |
hda_beep.h | -rw-r--r-- | 1.2 KB |
hda_bind.c | -rw-r--r-- | 7.6 KB |
hda_codec.c | -rw-r--r-- | 108.7 KB |
hda_controller.c | -rw-r--r-- | 34.9 KB |
hda_controller.h | -rw-r--r-- | 6.4 KB |
hda_controller_trace.h | -rw-r--r-- | 2.2 KB |
hda_eld.c | -rw-r--r-- | 21.4 KB |
hda_generic.c | -rw-r--r-- | 165.8 KB |
hda_generic.h | -rw-r--r-- | 12.4 KB |
hda_hwdep.c | -rw-r--r-- | 2.7 KB |
hda_intel.c | -rw-r--r-- | 79.2 KB |
hda_intel.h | -rw-r--r-- | 779 bytes |
hda_intel_trace.h | -rw-r--r-- | 1.0 KB |
hda_jack.c | -rw-r--r-- | 18.0 KB |
hda_jack.h | -rw-r--r-- | 5.4 KB |
hda_local.h | -rw-r--r-- | 23.7 KB |
hda_proc.c | -rw-r--r-- | 27.2 KB |
hda_sysfs.c | -rw-r--r-- | 18.7 KB |
hda_tegra.c | -rw-r--r-- | 13.6 KB |
hp_x360_helper.c | -rw-r--r-- | 7.9 KB |
patch_analog.c | -rw-r--r-- | 29.7 KB |
patch_ca0110.c | -rw-r--r-- | 1.9 KB |
patch_ca0132.c | -rw-r--r-- | 277.7 KB |
patch_cirrus.c | -rw-r--r-- | 32.1 KB |
patch_cmedia.c | -rw-r--r-- | 2.8 KB |
patch_conexant.c | -rw-r--r-- | 33.2 KB |
patch_hdmi.c | -rw-r--r-- | 117.7 KB |
patch_realtek.c | -rw-r--r-- | 318.8 KB |
patch_si3054.c | -rw-r--r-- | 8.3 KB |
patch_sigmatel.c | -rw-r--r-- | 136.7 KB |
patch_via.c | -rw-r--r-- | 31.7 KB |
thinkpad_helper.c | -rw-r--r-- | 887 bytes |
Computing file changes ...