On 14.06.25 19:34, Jason Andryuk wrote:
On Fri, Mar 21, 2025 at 5:32 AM Juergen Gross <jgr...@suse.com> wrote:

Add a kexec_call() macro which will provide the capability to register
a function for being called when doing a kexec() call. The called
functions will be called with a boolean parameter "undo" indicating
whether a previous call needs to be undone due to a failure during
kexec().

The related loop to call all callbacks is added to kexec().

Signed-off-by: Juergen Gross <jgr...@suse.com>

diff --git a/arch/x86/mm.c b/arch/x86/mm.c
index f4419d95..26ede6f4 100644
--- a/arch/x86/mm.c
+++ b/arch/x86/mm.c
@@ -529,7 +529,8 @@ void change_readonly(bool readonly)
  #endif
      }

-    printk("setting %p-%p readonly\n", &_text, &_erodata);
+    printk("setting %p-%p %s\n", &_text, &_erodata,
+           readonly ? "readonly" : "writable");

Oh, I think this belongs in the earlier change.

Indeed.


With that moved, this one (and the earlier one still)

Code wise:
Reviewed-by: Jason Andryuk <jason.andr...@amd.com>

But this kexec_call() macro isn't actually used?  xenstore needs this
to prepare for kexec?

This will be needed to e.g. handle FD_CLOEXEC.


Juergen

Attachment: OpenPGP_0xB0DE9DD628BF132F.asc
Description: OpenPGP public key

Attachment: OpenPGP_signature.asc
Description: OpenPGP digital signature

Reply via email to