linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v9 0/9] liveupdate: Rework KHO for in-kernel users
@ 2025-11-01 14:23 Pasha Tatashin
  2025-11-01 14:23 ` [PATCH v9 1/9] kho: make debugfs interface optional Pasha Tatashin
                   ` (8 more replies)
  0 siblings, 9 replies; 42+ messages in thread
From: Pasha Tatashin @ 2025-11-01 14:23 UTC (permalink / raw)
  To: akpm, brauner, corbet, graf, jgg, linux-kernel, linux-kselftest,
	linux-mm, masahiroy, ojeda, pasha.tatashin, pratyush, rdunlap,
	rppt, tj, yanjun.zhu

Changelog:
v9:
Added review-bys and addressed comments from Mike Rapoport and
Pratyush Yadav.
Dropped patch that moves abort/finalize to public header per Mike's
request.
Added patch from Zhu Yanjun to output errors by name.

This series appliyes against akpm's mm-unstable branch.

This series refactors the KHO framework to better support in-kernel
users like the upcoming LUO. The current design, which relies on a
notifier chain and debugfs for control, is too restrictive for direct
programmatic use.

The core of this rework is the removal of the notifier chain in favor of
a direct registration API. This decouples clients from the shutdown-time
finalization sequence, allowing them to manage their preserved state
more flexibly and at any time.

In support of this new model, this series also:
 - Makes the debugfs interface optional.
 - Introduces APIs to unpreserve memory and fixes a bug in the abort
   path where client state was being incorrectly discarded. Note that
   this is an interim step, as a more comprehensive fix is planned as
   part of the stateless KHO work [1].
 - Moves all KHO code into a new kernel/liveupdate/ directory to
   consolidate live update components.

[1] https://lore.kernel.org/all/20251020100306.2709352-1-jasonmiu@google.com

Mike Rapoport (Microsoft) (1):
  kho: drop notifiers

Pasha Tatashin (7):
  kho: make debugfs interface optional
  kho: add interfaces to unpreserve folios, page ranges, and vmalloc
  memblock: Unpreserve memory in case of error
  test_kho: Unpreserve memory in case of error
  kho: don't unpreserve memory during abort
  liveupdate: kho: move to kernel/liveupdate
  MAINTAINERS: update KHO maintainers

Zhu Yanjun (1):
  liveupdate: kho: Use %pe format specifier for error pointer printing

 Documentation/core-api/kho/concepts.rst       |   2 +-
 MAINTAINERS                                   |   4 +-
 include/linux/kexec_handover.h                |  46 +-
 init/Kconfig                                  |   2 +
 kernel/Kconfig.kexec                          |  24 -
 kernel/Makefile                               |   3 +-
 kernel/kexec_handover_internal.h              |  16 -
 kernel/liveupdate/Kconfig                     |  39 ++
 kernel/liveupdate/Makefile                    |   5 +
 kernel/{ => liveupdate}/kexec_handover.c      | 532 +++++++-----------
 .../{ => liveupdate}/kexec_handover_debug.c   |   0
 kernel/liveupdate/kexec_handover_debugfs.c    | 221 ++++++++
 kernel/liveupdate/kexec_handover_internal.h   |  56 ++
 lib/test_kho.c                                | 128 +++--
 mm/memblock.c                                 |  93 +--
 tools/testing/selftests/kho/vmtest.sh         |   1 +
 16 files changed, 690 insertions(+), 482 deletions(-)
 delete mode 100644 kernel/kexec_handover_internal.h
 create mode 100644 kernel/liveupdate/Kconfig
 create mode 100644 kernel/liveupdate/Makefile
 rename kernel/{ => liveupdate}/kexec_handover.c (80%)
 rename kernel/{ => liveupdate}/kexec_handover_debug.c (100%)
 create mode 100644 kernel/liveupdate/kexec_handover_debugfs.c
 create mode 100644 kernel/liveupdate/kexec_handover_internal.h


base-commit: 9ef7b034116354ee75502d1849280a4d2ff98a7c
-- 
2.51.1.930.gacf6e81ea2-goog



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

end of thread, other threads:[~2025-11-13 20:29 UTC | newest]

Thread overview: 42+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-11-01 14:23 [PATCH v9 0/9] liveupdate: Rework KHO for in-kernel users Pasha Tatashin
2025-11-01 14:23 ` [PATCH v9 1/9] kho: make debugfs interface optional Pasha Tatashin
2025-11-07  6:03   ` Zhu Yanjun
2025-11-07 12:00     ` Pasha Tatashin
2025-11-07 12:02       ` Pasha Tatashin
2025-11-07 23:35         ` Yanjun.Zhu
2025-11-08 18:13           ` Pasha Tatashin
2025-11-10  0:20             ` Zhu Yanjun
2025-11-10 13:16               ` Pratyush Yadav
2025-11-10 15:26                 ` Pasha Tatashin
2025-11-11  4:11                   ` Zhu Yanjun
2025-11-11 15:26                     ` Pasha Tatashin
2025-11-13  1:41                       ` Yanjun.Zhu
2025-11-13  2:11                         ` Yanjun.Zhu
2025-11-13 19:59                           ` Pasha Tatashin
2025-11-13 20:07                             ` Yanjun.Zhu
2025-11-13 19:55                       ` Yanjun.Zhu
2025-11-13 20:10                         ` Pasha Tatashin
2025-11-13 20:13                           ` Pasha Tatashin
2025-11-13 20:28                             ` Yanjun.Zhu
2025-11-01 14:23 ` [PATCH v9 2/9] kho: drop notifiers Pasha Tatashin
2025-11-06  8:41   ` kernel test robot
2025-11-06 21:46     ` Pasha Tatashin
2025-11-06 22:14       ` Pasha Tatashin
2025-11-01 14:23 ` [PATCH v9 3/9] kho: add interfaces to unpreserve folios, page ranges, and vmalloc Pasha Tatashin
2025-11-03 18:05   ` Pratyush Yadav
2025-11-01 14:23 ` [PATCH v9 4/9] memblock: Unpreserve memory in case of error Pasha Tatashin
2025-11-02  6:51   ` Mike Rapoport
2025-11-05 10:26   ` Pratyush Yadav
2025-11-01 14:23 ` [PATCH v9 5/9] test_kho: " Pasha Tatashin
2025-11-01 14:23 ` [PATCH v9 6/9] kho: don't unpreserve memory during abort Pasha Tatashin
2025-11-05 10:28   ` Pratyush Yadav
2025-11-01 14:23 ` [PATCH v9 7/9] liveupdate: kho: move to kernel/liveupdate Pasha Tatashin
2025-11-06  7:21   ` kernel test robot
2025-11-07 22:23   ` Andrew Morton
2025-11-08 18:01     ` Pasha Tatashin
2025-11-01 14:23 ` [PATCH v9 8/9] MAINTAINERS: update KHO maintainers Pasha Tatashin
2025-11-01 16:36   ` Mike Rapoport
2025-11-01 14:23 ` [PATCH v9 9/9] liveupdate: kho: Use %pe format specifier for error pointer printing Pasha Tatashin
2025-11-01 19:45   ` Zhu Yanjun
2025-11-02  6:59   ` Mike Rapoport
2025-11-03 12:59   ` Pratyush Yadav

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).