From: "Lorenzo Stoakes (ARM)" <ljs@kernel.org>
To: Yao Yuan <yaoyuan@linux.alibaba.com>
Cc: Wei-Lin Chang <weilin.chang@arm.com>,
Marc Zyngier <maz@kernel.org>, Oliver Upton <oupton@kernel.org>,
Fuad Tabba <tabba@google.com>, Joey Gouly <joey.gouly@arm.com>,
Steffen Eiden <seiden@linux.ibm.com>,
Suzuki K Poulose <suzuki.poulose@arm.com>,
Zenghui Yu <yuzenghui@huawei.com>,
Catalin Marinas <catalin.marinas@arm.com>,
Will Deacon <will@kernel.org>,
Jintack Lim <jintack.lim@linaro.org>,
Christoffer Dall <christoffer.dall@arm.com>,
linux-arm-kernel@lists.infradead.org, kvmarm@lists.linux.dev,
linux-kernel@vger.kernel.org, stable@vger.kernel.org
Subject: Re: [PATCH 1/2] KVM: arm64: Fix spurious warning for benign stage 2 teardown race
Date: Mon, 17 Aug 2026 08:46:02 +0100 [thread overview]
Message-ID: <aoK7vLOD3oKKAxH0@lucifer> (raw)
In-Reply-To: <dlvicg2jykp4icqkpa7xjm6bmim7sbp7vventkzgoihzpombcc@pemvii5d6qfj>
On Mon, Aug 17, 2026 at 08:38:37AM +0800, Yao Yuan wrote:
> On Fri, Aug 14, 2026 at 09:48:39AM +0800, Lorenzo Stoakes (ARM) wrote:
> > OK so - I confused myself here :)
> >
> > The underlying issue here is that I am working back from a situation where
> > I can't quite recall what I did, but am rather reconstructing it based on
> > what was observed.
> >
> > And you're right - this stack makes no sense for an L2 VM being torn down,
> > rather only the L0 being torn down.
> >
> > So clearly this is what I did, and the correction should be to say this at
> > the start of the commit message.
>
> Ah I see. I agree the race is there. Below is just an idea
> in my mind for reproducing this, hope this is helpful to you :-)
>
> migratepages (https://man7.org/linux/man-pages/man8/migratepages.8.html) can
> help to trigger the MMU notifier to qemu/kvmtool easily on 2P system, meanwhile
> kill the qemu/kvmtool on L0 to reprouduce the racing. For 1P system kernel has
> numa=fake parameter to generate more NUMAs there.
>
Ah nice thanks! There's also /proc/sys/vm/compact_memory so you can do:
$ echo 1 | sudo tee /proc/sys/vm/compact_memory
To trigger immediate memory compaction (and thus migration) also :)
--
Cheers, Lorenzo
next prev parent reply other threads:[~2026-08-17 7:46 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-12 13:31 [PATCH 0/2] KVM: arm64: Fix spurious warn, null ptr deref on S2 teardown race Lorenzo Stoakes (ARM)
2026-08-12 13:31 ` [PATCH 1/2] KVM: arm64: Fix spurious warning for benign stage 2 " Lorenzo Stoakes (ARM)
2026-08-12 13:46 ` Lorenzo Stoakes (ARM)
2026-08-12 13:54 ` sashiko-bot
2026-08-13 15:35 ` Lorenzo Stoakes (ARM)
2026-08-12 23:20 ` Wei-Lin Chang
2026-08-13 15:24 ` Lorenzo Stoakes (ARM)
2026-08-14 7:18 ` Yao Yuan
2026-08-14 8:48 ` Lorenzo Stoakes (ARM)
2026-08-17 0:38 ` Yao Yuan
2026-08-17 7:46 ` Lorenzo Stoakes (ARM) [this message]
2026-08-12 13:31 ` [PATCH 2/2] KVM: arm64: nv: Fix null ptr deref in kvm_nested_s2_unmap() on S2 teardown Lorenzo Stoakes (ARM)
2026-08-12 14:01 ` sashiko-bot
2026-08-13 15:56 ` Lorenzo Stoakes (ARM)
2026-08-22 7:28 ` Marc Zyngier
2026-08-22 14:27 ` Lorenzo Stoakes (ARM)
2026-08-22 7:32 ` Marc Zyngier
2026-08-22 14:26 ` Lorenzo Stoakes (ARM)
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=aoK7vLOD3oKKAxH0@lucifer \
--to=ljs@kernel.org \
--cc=catalin.marinas@arm.com \
--cc=christoffer.dall@arm.com \
--cc=jintack.lim@linaro.org \
--cc=joey.gouly@arm.com \
--cc=kvmarm@lists.linux.dev \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=maz@kernel.org \
--cc=oupton@kernel.org \
--cc=seiden@linux.ibm.com \
--cc=stable@vger.kernel.org \
--cc=suzuki.poulose@arm.com \
--cc=tabba@google.com \
--cc=weilin.chang@arm.com \
--cc=will@kernel.org \
--cc=yaoyuan@linux.alibaba.com \
--cc=yuzenghui@huawei.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 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.