[PW_SID:1057600] mm/kasan: make kasan=on|off work for all three modes#1497
[PW_SID:1057600] mm/kasan: make kasan=on|off work for all three modes#1497linux-riscv-bot wants to merge 15 commits intoworkflow__riscv__fixesfrom
Conversation
…asan is disabled The current codes only check if kasan is disabled for hw_tags mode. Here add the conditional checks for functional functions of generic mode and sw_tags mode. And also add a helper __kasan_cache_shrink() in mm/kasan/generic.c so that the conditional check is done in include/linux/kasan.h. This is prepared for later adding kernel parameter kasan=on|off for all three kasan modes. Signed-off-by: Baoquan He <bhe@redhat.com> Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
And change it to be a bool variable. This is prepared for later usage. Signed-off-by: Baoquan He <bhe@redhat.com> Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
This allows generic and sw_tags to be set in kernel cmdline too. Signed-off-by: Baoquan He <bhe@redhat.com> Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Now everything is ready, setting kasan=off can disable kasan for all three modes. Signed-off-by: Baoquan He <bhe@redhat.com> Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Here, kasan is disabled if specified 'kasan=off' in kernel cmdline. Signed-off-by: Baoquan He <bhe@redhat.com> Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Here, kasan is disabled if specified 'kasan=off' in kernel cmdline. And also call jump_label_init() early in setup_arch() so that later kasan_init() can enable static key kasan_flag_enabled. Put jump_label_init() beofre parse_early_param() as other architectures do. Signed-off-by: Baoquan He <bhe@redhat.com> Cc: linux-arm-kernel@lists.infradead.org Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Here, kasan is disabled if specified 'kasan=off' in kernel cmdline. And also need skip kasan_populate_early_vm_area_shadow() if kasan is disabled. Signed-off-by: Baoquan He <bhe@redhat.com> Cc: linux-arm-kernel@lists.infradead.org Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Here, kasan is disabled if specified 'kasan=off' in kernel cmdline. Signed-off-by: Baoquan He <bhe@redhat.com> Cc: loongarch@lists.linux.dev Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Here, kasan is disabled if specified 'kasan=off' in kernel cmdline. This includes 32bit, book3s/64 and book3e/64. Signed-off-by: Baoquan He <bhe@redhat.com> Cc: linuxppc-dev@lists.ozlabs.org Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Here, kasan is disabled if specified 'kasan=off' in kernel cmdline. Signed-off-by: Baoquan He <bhe@redhat.com> Cc: linux-riscv@lists.infradead.org Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Here, kasan is disabled if specified 'kasan=off' in kernel cmdline. Signed-off-by: Baoquan He <bhe@redhat.com> Cc: x86@kernel.org Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Here, kasan is disabled if specified 'kasan=off' in kernel cmdline. And also call jump_label_init() early in setup_arch() so that later kasan_init() can enable static key kasan_flag_enabled. Put jump_label_init() beofre parse_early_param() as other architectures do. Signed-off-by: Baoquan He <bhe@redhat.com> Cc: Chris Zankel <chris@zankel.net> Cc: Max Filippov <jcmvbkbc@gmail.com> Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Here, kasan is disabled if specified 'kasan=off' in kernel cmdline. And also wrap up the kasan code into CONFIG_KASAN ifdeffery scope. Signed-off-by: Baoquan He <bhe@redhat.com> Cc: linux-um@lists.infradead.org Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
And also remove the relevant description in dev-tools/kasan.rst which is hw_tags specificially. Signed-off-by: Baoquan He <bhe@redhat.com> Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Since commit 1e338f4 ("kasan: introduce ARCH_DEFER_KASAN and unify static key across modes"), kasan_arch_is_ready() has been dead code. And up to now, ARCH_DEFER_KASAN is useless too because of code change for 'kasan=on|off'. Here clean them up. Signed-off-by: Baoquan He <bhe@redhat.com> Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
|
Patch 1: "[v5,01/15] mm/kasan: add conditional checks in functions to return directly if kasan is disabled" |
|
Patch 1: "[v5,01/15] mm/kasan: add conditional checks in functions to return directly if kasan is disabled" |
|
Patch 1: "[v5,01/15] mm/kasan: add conditional checks in functions to return directly if kasan is disabled" |
|
Patch 1: "[v5,01/15] mm/kasan: add conditional checks in functions to return directly if kasan is disabled" |
|
Patch 1: "[v5,01/15] mm/kasan: add conditional checks in functions to return directly if kasan is disabled" |
|
Patch 1: "[v5,01/15] mm/kasan: add conditional checks in functions to return directly if kasan is disabled" |
|
Patch 1: "[v5,01/15] mm/kasan: add conditional checks in functions to return directly if kasan is disabled" |
|
Patch 1: "[v5,01/15] mm/kasan: add conditional checks in functions to return directly if kasan is disabled" |
|
Patch 1: "[v5,01/15] mm/kasan: add conditional checks in functions to return directly if kasan is disabled" |
|
Patch 1: "[v5,01/15] mm/kasan: add conditional checks in functions to return directly if kasan is disabled" |
|
Patch 1: "[v5,01/15] mm/kasan: add conditional checks in functions to return directly if kasan is disabled" |
|
Patch 1: "[v5,01/15] mm/kasan: add conditional checks in functions to return directly if kasan is disabled" |
|
Patch 2: "[v5,02/15] mm/kasan: rename 'kasan_arg' to 'kasan_arg_disabled'" |
|
Patch 2: "[v5,02/15] mm/kasan: rename 'kasan_arg' to 'kasan_arg_disabled'" |
|
Patch 2: "[v5,02/15] mm/kasan: rename 'kasan_arg' to 'kasan_arg_disabled'" |
|
Patch 9: "[v5,09/15] arch/powerpc: don't initialize kasan if it's disabled" |
|
Patch 9: "[v5,09/15] arch/powerpc: don't initialize kasan if it's disabled" |
|
Patch 9: "[v5,09/15] arch/powerpc: don't initialize kasan if it's disabled" |
|
Patch 9: "[v5,09/15] arch/powerpc: don't initialize kasan if it's disabled" |
|
Patch 9: "[v5,09/15] arch/powerpc: don't initialize kasan if it's disabled" |
|
Patch 10: "[v5,10/15] arch/riscv: don't initialize kasan if it's disabled" |
|
Patch 10: "[v5,10/15] arch/riscv: don't initialize kasan if it's disabled" |
|
Patch 10: "[v5,10/15] arch/riscv: don't initialize kasan if it's disabled" |
|
Patch 10: "[v5,10/15] arch/riscv: don't initialize kasan if it's disabled" |
|
Patch 10: "[v5,10/15] arch/riscv: don't initialize kasan if it's disabled" |
|
Patch 10: "[v5,10/15] arch/riscv: don't initialize kasan if it's disabled" |
|
Patch 10: "[v5,10/15] arch/riscv: don't initialize kasan if it's disabled" |
|
Patch 10: "[v5,10/15] arch/riscv: don't initialize kasan if it's disabled" |
|
Patch 10: "[v5,10/15] arch/riscv: don't initialize kasan if it's disabled" |
|
Patch 10: "[v5,10/15] arch/riscv: don't initialize kasan if it's disabled" |
|
Patch 10: "[v5,10/15] arch/riscv: don't initialize kasan if it's disabled" |
|
Patch 10: "[v5,10/15] arch/riscv: don't initialize kasan if it's disabled" |
|
Patch 11: "[v5,11/15] arch/x86: don't initialize kasan if it's disabled" |
|
Patch 11: "[v5,11/15] arch/x86: don't initialize kasan if it's disabled" |
|
Patch 11: "[v5,11/15] arch/x86: don't initialize kasan if it's disabled" |
|
Patch 11: "[v5,11/15] arch/x86: don't initialize kasan if it's disabled" |
|
Patch 11: "[v5,11/15] arch/x86: don't initialize kasan if it's disabled" |
|
Patch 11: "[v5,11/15] arch/x86: don't initialize kasan if it's disabled" |
|
Patch 11: "[v5,11/15] arch/x86: don't initialize kasan if it's disabled" |
|
Patch 11: "[v5,11/15] arch/x86: don't initialize kasan if it's disabled" |
|
Patch 11: "[v5,11/15] arch/x86: don't initialize kasan if it's disabled" |
|
Patch 11: "[v5,11/15] arch/x86: don't initialize kasan if it's disabled" |
|
Patch 11: "[v5,11/15] arch/x86: don't initialize kasan if it's disabled" |
|
Patch 11: "[v5,11/15] arch/x86: don't initialize kasan if it's disabled" |
|
Patch 12: "[v5,12/15] arch/xtensa: don't initialize kasan if it's disabled" |
PR for series 1057600 applied to workflow__riscv__fixes
Name: mm/kasan: make kasan=on|off work for all three modes
URL: https://patchwork.kernel.org/project/linux-riscv/list/?series=1057600
Version: 5