[PATCH v9 25/44] kasan: introduce CONFIG_KASAN_HW_TAGS

Alexander Potapenko glider at google.com
Wed Nov 11 10:58:16 EST 2020


On Tue, Nov 10, 2020 at 11:12 PM Andrey Konovalov <andreyknvl at google.com> wrote:
>
> This patch adds a configuration option for a new KASAN mode called
> hardware tag-based KASAN. This mode uses the memory tagging approach
> like the software tag-based mode, but relies on arm64 Memory Tagging
> Extension feature for tag management and access checking.
>
> Signed-off-by: Andrey Konovalov <andreyknvl at google.com>
> Co-developed-by: Vincenzo Frascino <vincenzo.frascino at arm.com>
> Signed-off-by: Vincenzo Frascino <vincenzo.frascino at arm.com>
> Reviewed-by: Marco Elver <elver at google.com>
> ---
> Change-Id: I246c2def9fffa6563278db1bddfbe742ca7bdefe
> ---
>  lib/Kconfig.kasan | 58 +++++++++++++++++++++++++++++++++--------------
>  1 file changed, 41 insertions(+), 17 deletions(-)
>
> diff --git a/lib/Kconfig.kasan b/lib/Kconfig.kasan
> index ec59a0e26d09..e5f27ec8b254 100644
> --- a/lib/Kconfig.kasan
> +++ b/lib/Kconfig.kasan
> @@ -6,7 +6,10 @@ config HAVE_ARCH_KASAN
>  config HAVE_ARCH_KASAN_SW_TAGS
>         bool
>
> -config HAVE_ARCH_KASAN_VMALLOC
> +config HAVE_ARCH_KASAN_HW_TAGS
> +       bool
> +
> +config HAVE_ARCH_KASAN_VMALLOC
>         bool
>
>  config CC_HAS_KASAN_GENERIC
> @@ -20,11 +23,11 @@ config CC_HAS_WORKING_NOSANITIZE_ADDRESS
It might make sense to add a comment to
CC_HAS_WORKING_NOSANITIZE_ADDRESS describing which modes need it (and
why).



More information about the linux-arm-kernel mailing list