[PATCH 29/31] kasan, arm64: allow KASAN_VMALLOC with HW_TAGS
Marco Elver
elver at google.com
Wed Dec 1 03:35:22 PST 2021
On Tue, Nov 30, 2021 at 11:08PM +0100, andrey.konovalov at linux.dev wrote:
> From: Andrey Konovalov <andreyknvl at google.com>
>
> vmalloc tagging support for HW_TAGS KASAN is now complete.
>
> Allow enabling CONFIG_KASAN_VMALLOC.
This actually doesn't "allow" enabling it, it unconditionally enables it
and a user can't disable CONFIG_KASAN_VMALLOC.
I found some background in acc3042d62cb9 why arm64 wants this.
> Also adjust CONFIG_KASAN_VMALLOC description:
>
> - Mention HW_TAGS support.
> - Remove unneeded internal details: they have no place in Kconfig
> description and are already explained in the documentation.
>
> Signed-off-by: Andrey Konovalov <andreyknvl at google.com>
> ---
> arch/arm64/Kconfig | 3 +--
> lib/Kconfig.kasan | 20 ++++++++++----------
> 2 files changed, 11 insertions(+), 12 deletions(-)
>
> diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig
> index c05d7a06276f..5981e5460c51 100644
> --- a/arch/arm64/Kconfig
> +++ b/arch/arm64/Kconfig
> @@ -205,8 +205,7 @@ config ARM64
> select IOMMU_DMA if IOMMU_SUPPORT
> select IRQ_DOMAIN
> select IRQ_FORCED_THREADING
> - select KASAN_VMALLOC if KASAN_GENERIC
> - select KASAN_VMALLOC if KASAN_SW_TAGS
> + select KASAN_VMALLOC
This produces the following warning when making an arm64 defconfig:
| WARNING: unmet direct dependencies detected for KASAN_VMALLOC
| Depends on [n]: KASAN [=n] && HAVE_ARCH_KASAN_VMALLOC [=y]
| Selected by [y]:
| - ARM64 [=y]
|
| WARNING: unmet direct dependencies detected for KASAN_VMALLOC
| Depends on [n]: KASAN [=n] && HAVE_ARCH_KASAN_VMALLOC [=y]
| Selected by [y]:
| - ARM64 [=y]
To unconditionally select KASAN_VMALLOC, it should probably be
select KASAN_VMALLOC if KASAN
More information about the linux-arm-kernel
mailing list