From: Long Wei <longwei27@huawei.com>
To: <rppt@kernel.org>, <pasha.tatashin@soleen.com>,
<pratyush@kernel.org>, <akpm@linux-foundation.org>
Cc: <graf@amazon.com>, <leitao@debian.org>, <corbet@lwn.net>,
<rdunlap@infradead.org>, <linux-mm@kvack.org>,
<kexec@lists.infradead.org>, <linux-doc@vger.kernel.org>,
<linux-kernel@vger.kernel.org>, <hewenliang4@huawei.com>,
Long Wei <longwei27@huawei.com>
Subject: [PATCH 0/2] kho: expose incoming sub-blob metadata instead of contents
Date: Tue, 17 Nov 2026 17:29:49 +0800 [thread overview]
Message-ID: <20261117092951.4017931-1-longwei27@huawei.com> (raw)
Incoming sub-blob pages under kho/in/sub_fdts are owned by their consumers
and have independent lifetimes. Consumers restore and free them at their own
initcall level, which is always earlier than kho_init() (fs_initcall) where
the debugfs view is built. LUO, for example, frees its state in
early_initcall, so in/sub_fdts/LUO ends up pointing at a page that has
already been returned to the page allocator. Reading the file then triggers
a KASAN use-after-free in _copy_to_user(), with the backing page already
marked page_type: f0(buddy).
KHO does not own these pages, so it cannot safely expose their contents at
any point. Instead of trying to track which blobs are still alive, replace
the raw blob nodes with a read-only in/blobs file that reports the name,
physical address and size of every sub-blob referenced by the incoming FDT.
The FDT itself is reserved by KHO and remains available as in/fdt.
The first patch does the change, the second updates the documentation.
Long Wei (2):
kho: expose incoming sub-blob metadata instead of contents
docs: kho: describe the in/blobs debugfs file
Documentation/admin-guide/mm/kho.rst | 6 +--
kernel/liveupdate/kexec_handover_debugfs.c | 83 +++++++++++++++---------------
2 files changed, 45 insertions(+), 44 deletions(-)
--
2.43.0
next reply other threads:[~2026-11-17 9:32 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-17 9:29 Long Wei [this message]
2026-11-17 9:29 ` [PATCH 1/2] " Long Wei
2026-11-17 9:29 ` [PATCH 2/2] docs: kho: describe the in/blobs debugfs file Long Wei
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=20261117092951.4017931-1-longwei27@huawei.com \
--to=longwei27@huawei.com \
--cc=akpm@linux-foundation.org \
--cc=corbet@lwn.net \
--cc=graf@amazon.com \
--cc=hewenliang4@huawei.com \
--cc=kexec@lists.infradead.org \
--cc=leitao@debian.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=pasha.tatashin@soleen.com \
--cc=pratyush@kernel.org \
--cc=rdunlap@infradead.org \
--cc=rppt@kernel.org \
/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®