[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <aWEF_eJ9Bnn5-8dZ@willie-the-truck>
Date: Fri, 9 Jan 2026 13:43:25 +0000
From: Will Deacon <will@...nel.org>
To: Maciej Wieczor-Retman <m.wieczorretman@...me>
Cc: Andrey Ryabinin <ryabinin.a.a@...il.com>,
Alexander Potapenko <glider@...gle.com>,
Andrey Konovalov <andreyknvl@...il.com>,
Dmitry Vyukov <dvyukov@...gle.com>,
Vincenzo Frascino <vincenzo.frascino@....com>,
Catalin Marinas <catalin.marinas@....com>,
Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...hat.com>, Borislav Petkov <bp@...en8.de>,
Dave Hansen <dave.hansen@...ux.intel.com>, x86@...nel.org,
"H. Peter Anvin" <hpa@...or.com>,
Andrew Morton <akpm@...ux-foundation.org>,
David Hildenbrand <david@...hat.com>,
Lorenzo Stoakes <lorenzo.stoakes@...cle.com>,
"Liam R. Howlett" <Liam.Howlett@...cle.com>,
Vlastimil Babka <vbabka@...e.cz>, Mike Rapoport <rppt@...nel.org>,
Suren Baghdasaryan <surenb@...gle.com>,
Michal Hocko <mhocko@...e.com>,
Samuel Holland <samuel.holland@...ive.com>,
Maciej Wieczor-Retman <maciej.wieczor-retman@...el.com>,
linux-kernel@...r.kernel.org, kasan-dev@...glegroups.com,
linux-arm-kernel@...ts.infradead.org, linux-mm@...ck.org
Subject: Re: [PATCH v7 02/15] kasan: arm64: x86: Make special tags arch
specific
On Fri, Jan 09, 2026 at 01:37:49PM +0000, Maciej Wieczor-Retman wrote:
> Hi, and thanks for looking at the patches!
>
> On 2026-01-08 at 17:56:39 +0000, Will Deacon wrote:
> >On Wed, Dec 10, 2025 at 05:28:43PM +0000, Maciej Wieczor-Retman wrote:
> >> From: Samuel Holland <samuel.holland@...ive.com>
> ...
> >> +#ifdef CONFIG_KASAN_HW_TAGS
> >> +#define KASAN_TAG_MIN 0xF0 /* minimum value for random tags */
> >> +#define KASAN_TAG_WIDTH 4
> >> +#else
> >> +#define KASAN_TAG_WIDTH 8
> >> +#endif
> >
> >Shouldn't this be 0 when KASAN is not in use at all?
> >
> >Will
>
> This file (as well as the x86 version) gets included in
> include/linux/kasan-tags.h:
>
> #if defined(CONFIG_KASAN_SW_TAGS) || defined(CONFIG_KASAN_HW_TAGS)
> #include <asm/kasan-tags.h>
> #endif
>
> #ifndef KASAN_TAG_WIDTH
> #define KASAN_TAG_WIDTH 0
> #endif
>
> So the 8 or 4 value is only assigned if SW_TAGS or HW_TAGS are enabled.
> Otherwise it's set to zero.
Thanks for the explanation, I'd missed the conditional inclusion of the
arch header.
In which case, the arm64 side looks fine to me:
Acked-by: Will Deacon <will@...nel.org>
Cheers,
Will
Powered by blists - more mailing lists