mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 0/2] kho: expose incoming sub-blob metadata instead of contents
@ 2026-11-17  9:29 Long Wei
  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
  0 siblings, 2 replies; 3+ messages in thread
From: Long Wei @ 2026-11-17  9:29 UTC (permalink / raw)
  To: rppt, pasha.tatashin, pratyush, akpm
  Cc: graf, leitao, corbet, rdunlap, linux-mm, kexec, linux-doc,
	linux-kernel, hewenliang4, Long Wei

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


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-11-17  9:32 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-17  9:29 [PATCH 0/2] kho: expose incoming sub-blob metadata instead of contents Long Wei
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

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®