From: sashiko-bot@kernel.org
To: "Alexander Gordeev" <agordeev@linux.ibm.com>
Cc: "Alexander Gordeev" <agordeev@linux.ibm.com>,
"Vasily Gorbik" <gor@linux.ibm.com>,
linux-s390@vger.kernel.org, "Heiko Carstens" <hca@linux.ibm.com>
Subject: Re: [PATCH v6 3/4] mm/kasan: Introduce helpers for lazy MMU mode sanitizer
Date: Wed, 15 Jul 2026 13:53:49 +0000 [thread overview]
Message-ID: <20260715135350.3B9F61F000E9@smtp.kernel.org> (raw)
In-Reply-To: <a5bf7ac327864193bb7c95d8575d6ce1f6a9576c.1784121418.git.agordeev@linux.ibm.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] Use of undeclared architecture-specific type `pte_t` in unconditionally compiled function prototypes causes a build failure when KASAN is disabled or HW tags are used.
--
--- Patch [3]: [PATCH v6 3/4] mm/kasan: Introduce helpers for lazy MMU mode sanitizer ---
commit 347acc32deb780b8050b3a731ff67d7198bd0478
Author: Alexander Gordeev <agordeev@linux.ibm.com>
mm/kasan: Introduce helpers for lazy MMU mode sanitizer
This patch provides new KASAN helpers that allow architectures to implement
and sanitize direct PTE accesses while lazy MMU mode is enabled. It is
specifically intended to address direct PTE accesses on s390.
> diff --git a/include/linux/kasan.h b/include/linux/kasan.h
> index bf233bde68c7e..deadf566b84ad 100644
> --- a/include/linux/kasan.h
> +++ b/include/linux/kasan.h
> @@ -134,6 +134,20 @@ static __always_inline void kasan_poison_slab(struct slab *slab)
> __kasan_poison_slab(slab);
> }
>
> +void __kasan_poison_pte(pte_t *pte, int nr);
> +static __always_inline void kasan_poison_pte(pte_t *pte, int nr)
> +{
> + if (kasan_enabled())
> + __kasan_poison_pte(pte, nr);
> +}
[Severity: Low]
Does this introduce a build failure when CONFIG_KASAN is disabled or when
hardware tags are used?
include/linux/kasan.h uses pte_t in the prototypes for kasan_poison_pte()
and kasan_unpoison_pte(), but it does not appear to include
<linux/pgtable.h> or <asm/page.h> beforehand.
If a C file includes <linux/kasan.h> (for example, indirectly via
<linux/ioremap.h>) before the page table headers, the compiler will fail
with an undeclared type error for pte_t. This will affect both these
declarations and the dummy stubs defined further down in the file.
[ ... ]
--
Sashiko AI review · https://sashiko.dev/#/patchset/cover.1784121418.git.agordeev@linux.ibm.com?part=3
next prev parent reply other threads:[~2026-07-15 13:53 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-15 13:22 [PATCH v6 0/4] s390/mm: Batch PTE updates in lazy MMU mode Alexander Gordeev
2026-07-15 13:22 ` [PATCH v6 1/4] mm: Make lazy MMU mode context-aware Alexander Gordeev
2026-07-15 13:22 ` [PATCH v6 2/4] s390/mm: Batch PTE updates in lazy MMU mode Alexander Gordeev
2026-07-15 13:22 ` [PATCH v6 3/4] mm/kasan: Introduce helpers for lazy MMU mode sanitizer Alexander Gordeev
2026-07-15 13:53 ` sashiko-bot [this message]
2026-07-15 13:22 ` [PATCH v6 4/4] s390/mm: Lazy " Alexander Gordeev
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260715135350.3B9F61F000E9@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=agordeev@linux.ibm.com \
--cc=gor@linux.ibm.com \
--cc=hca@linux.ibm.com \
--cc=linux-s390@vger.kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.