kpatch/test/integration/rhel-8.9/gcc-static-local-var-3.patch

20 lines
437 B
Diff
Raw Normal View History

diff -Nupr src.orig/kernel/reboot.c src/kernel/reboot.c
--- src.orig/kernel/reboot.c 2023-05-18 13:26:13.457170617 -0400
+++ src/kernel/reboot.c 2023-05-18 13:26:57.125119162 -0400
@@ -393,8 +393,15 @@ SYSCALL_DEFINE4(reboot, int, magic1, int
return ret;
}
+void kpatch_bar(void)
+{
+ if (!jiffies)
+ printk("kpatch_foo\n");
+}
+
static void deferred_cad(struct work_struct *dummy)
{
+ kpatch_bar();
kernel_restart(NULL);
}