From: Ryan Roberts <ryan.roberts@arm.com>
To: Fuad Tabba <fuad.tabba@linux.dev>,
Catalin Marinas <catalin.marinas@arm.com>,
Will Deacon <will@kernel.org>
Cc: Mark Rutland <mark.rutland@arm.com>,
Ard Biesheuvel <ardb@kernel.org>,
Yang Shi <yang@os.amperecomputing.com>,
Kevin Brodsky <kevin.brodsky@arm.com>,
Anshuman Khandual <anshuman.khandual@arm.com>,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org, Fuad Tabba <tabba@google.com>,
stable@vger.kernel.org
Subject: Re: [PATCH 2/3] arm64: mm: Add an ISB after remapping the KPTI page-table slot
Date: Sat, 21 Nov 2026 10:48:13 +0000 [thread overview]
Message-ID: <100de3fa-ce00-4dd5-9a50-9182968b5a8b@arm.com> (raw)
In-Reply-To: <20261120121638.194154-3-fuad.tabba@linux.dev>
On 20/11/2026 12:16, Fuad Tabba wrote:
> kpti_map_pgtbl remaps a temporary slot with break-before-make, and
> kpti_mk_tbl_ng then reads the page tables through it. The make ends in
> a DSB alone, so the reads can fault on a translation of the slot made
> speculatively before the new entry was written. With the temporary page
> tables in TTBR1 the kernel's vectors are unmapped, and the boot hangs.
>
> Add an ISB after the DSB.
Reviewed-by: Ryan Roberts <ryan.roberts@arm.com>
>
> Fixes: 47546a1912fc4 ("arm64: mm: install KPTI nG mappings with MMU enabled")
> Cc: stable@vger.kernel.org
> Signed-off-by: Fuad Tabba <fuad.tabba@linux.dev>
> ---
> arch/arm64/mm/proc.S | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/arch/arm64/mm/proc.S b/arch/arm64/mm/proc.S
> index 12aacc74f7647..7ca36d59bf77f 100644
> --- a/arch/arm64/mm/proc.S
> +++ b/arch/arm64/mm/proc.S
> @@ -262,6 +262,7 @@ SYM_FUNC_ALIAS(__pi_idmap_cpu_replace_ttbr1, idmap_cpu_replace_ttbr1)
> orr pte, pte, pte_flags
> str pte, [temp_pte, #8 * (\level + 2)]
> dsb nshst
> + isb
> .endm
>
> /*
next prev parent reply other threads:[~2026-11-21 10:48 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-20 12:16 [PATCH 0/3] arm64: Missing barriers in kernel page-table updates Fuad Tabba
2026-11-20 12:16 ` [PATCH 1/3] arm64: pi: Add an ISB after mapping the FDT in the initial ID map Fuad Tabba
2026-11-21 10:42 ` Ryan Roberts
2026-11-20 12:16 ` [PATCH 2/3] arm64: mm: Add an ISB after remapping the KPTI page-table slot Fuad Tabba
2026-11-21 10:48 ` Ryan Roberts [this message]
2026-11-20 12:16 ` [PATCH 3/3] arm64: mm: Don't defer the barriers when installing a fixmap entry Fuad Tabba
2026-11-21 11:01 ` Ryan Roberts
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=100de3fa-ce00-4dd5-9a50-9182968b5a8b@arm.com \
--to=ryan.roberts@arm.com \
--cc=anshuman.khandual@arm.com \
--cc=ardb@kernel.org \
--cc=catalin.marinas@arm.com \
--cc=fuad.tabba@linux.dev \
--cc=kevin.brodsky@arm.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=stable@vger.kernel.org \
--cc=tabba@google.com \
--cc=will@kernel.org \
--cc=yang@os.amperecomputing.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®