From: Andrew Morton <akpm@linux-foundation.org>
To: Vivian Wang <wangruikang@iscas.ac.cn>
Cc: "Paul Walmsley" <pjw@kernel.org>,
"Palmer Dabbelt" <palmer@dabbelt.com>,
"Albert Ou" <aou@eecs.berkeley.edu>,
"Alexandre Ghiti" <alex@ghiti.fr>,
"Mike Rapoport (Microsoft)" <rppt@kernel.org>,
linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org,
"Thomas Weißschuh" <thomas.weissschuh@linutronix.de>
Subject: Re: [PATCH] riscv: patch: Avoid early page_to_phys()
Date: Mon, 23 Mar 2026 09:34:03 -0700 [thread overview]
Message-ID: <20260323093403.2ad50dced749e13cd98f01d1@linux-foundation.org> (raw)
In-Reply-To: <347c918e-6682-455c-ba08-096d9b7b89e4@iscas.ac.cn>
On Mon, 23 Mar 2026 09:58:05 +0800 Vivian Wang <wangruikang@iscas.ac.cn> wrote:
> On 3/19/26 01:42, Paul Walmsley wrote:
> > On Tue, 10 Mar 2026, Vivian Wang wrote:
> >
> >> Similarly to commit 8d09e2d569f6 ("arm64: patching: avoid early
> >> page_to_phys()"), avoid using phys_to_page() for the kernel address case
> >> in patch_map().
> >>
> >> Since this is called from apply_boot_alternatives() in setup_arch(), and
> >> commit 4267739cabb8 ("arch, mm: consolidate initialization of SPARSE
> >> memory model") has moved sparse_init() to after setup_arch(),
> >> phys_to_page() is not available there yet, and it panics on boot with
> >> SPARSEMEM on RV32, which does not use SPARSEMEM_VMEMMAP.
> >>
> >> Reported-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
> >> Closes: https://lore.kernel.org/r/20260223144108-dcace0b9-02e8-4b67-a7ce-f263bed36f26@linutronix.de/
> >> Fixes: 4267739cabb8 ("arch, mm: consolidate initialization of SPARSE memory model")
> >> Suggested-by: Mike Rapoport <rppt@kernel.org>
> >> Signed-off-by: Vivian Wang <wangruikang@iscas.ac.cn>
> > Thanks, queued for v7.0-rc.
>
> I have only just noticed that this patch was commited to both
> mm-hotfixes-stable [1] by Andrew and riscv fixes [2] by Paul. Is this
> intended?
It happens - better both than neither!
I'll drop the mm.git copy.
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
prev parent reply other threads:[~2026-03-23 16:34 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-10 8:25 [PATCH] riscv: patch: Avoid early page_to_phys() Vivian Wang
2026-03-10 9:05 ` Thomas Weißschuh
2026-03-10 10:16 ` Mike Rapoport
2026-03-18 17:42 ` Paul Walmsley
2026-03-23 1:58 ` Vivian Wang
2026-03-23 16:34 ` Andrew Morton [this message]
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=20260323093403.2ad50dced749e13cd98f01d1@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=alex@ghiti.fr \
--cc=aou@eecs.berkeley.edu \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=palmer@dabbelt.com \
--cc=pjw@kernel.org \
--cc=rppt@kernel.org \
--cc=thomas.weissschuh@linutronix.de \
--cc=wangruikang@iscas.ac.cn \
/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