Thread (41 messages) 41 messages, 8 authors, 2018-01-25

Re: [PATCH v5 13/15] livepatch: change to a per-task consistency model

flat view

From: Peter Zijlstra <peterz@infradead.org>
Date: 2018-01-25 09:05:06
Also in: linux-s390, lkml

On Mon, Feb 13, 2017 at 07:42:40PM -0600, Josh Poimboeuf wrote:
quoted hunk ↗ jump to hunk
diff --git a/kernel/sched/idle.c b/kernel/sched/idle.c
index 6a4bae0..a8b3f1a 100644
--- a/kernel/sched/idle.c
+++ b/kernel/sched/idle.c
@@ -9,6 +9,7 @@
 #include <linux/mm.h>
 #include <linux/stackprotector.h>
 #include <linux/suspend.h>
+#include <linux/livepatch.h>
 
 #include <asm/tlb.h>
 
@@ -264,6 +265,9 @@ static void do_idle(void)
 
 	sched_ttwu_pending();
 	schedule_preempt_disabled();
+
+	if (unlikely(klp_patch_pending(current)))
+		klp_update_patch_state(current);
 }
Can someone explain this one? This is a very weird place to add things.
What was the expectation?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help