- sched_exit-fix-parent-time_slice-calculation.patch removed from -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled

     sched_exit: fix parent->time_slice calculation

has been removed from the -mm tree.  Its filename is

     sched_exit-fix-parent-time_slice-calculation.patch

This patch was dropped because it had testing failures

------------------------------------------------------
Subject: sched_exit: fix parent->time_slice calculation
From: Oleg Nesterov <oleg@xxxxxxxxxx>


sched_exit:

	if (parent->time_slice > task_timeslice(p)))
		parent->time_slice = task_timeslice(p)

I think it should use task_timeslice(parent) instead.

The patch looks complicated, but it is not. It just caches the value
of 'p->parent'.

Signed-off-by: Oleg Nesterov <oleg@xxxxxxxxxx>
Cc: Ingo Molnar <mingo@xxxxxxx>
Cc: Nick Piggin <nickpiggin@xxxxxxxxxxxx>
Cc: Con Kolivas <kernel@xxxxxxxxxxx>
Cc: Peter Williams <pwil3058@xxxxxxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxx>
---

 kernel/sched.c |   15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)

diff -puN kernel/sched.c~sched_exit-fix-parent-time_slice-calculation kernel/sched.c
--- a/kernel/sched.c~sched_exit-fix-parent-time_slice-calculation
+++ a/kernel/sched.c
@@ -1606,6 +1606,7 @@ void fastcall wake_up_new_task(task_t *p
  */
 void fastcall sched_exit(task_t *p)
 {
+	task_t *parent = p->parent;
 	unsigned long flags;
 	runqueue_t *rq;
 
@@ -1613,14 +1614,14 @@ void fastcall sched_exit(task_t *p)
 	 * If the child was a (relative-) CPU hog then decrease
 	 * the sleep_avg of the parent as well.
 	 */
-	rq = task_rq_lock(p->parent, &flags);
-	if (p->first_time_slice && task_cpu(p) == task_cpu(p->parent)) {
-		p->parent->time_slice += p->time_slice;
-		if (unlikely(p->parent->time_slice > task_timeslice(p)))
-			p->parent->time_slice = task_timeslice(p);
+	rq = task_rq_lock(parent, &flags);
+	if (p->first_time_slice && task_cpu(p) == task_cpu(parent)) {
+		parent->time_slice += p->time_slice;
+		if (unlikely(parent->time_slice > task_timeslice(parent)))
+			parent->time_slice = task_timeslice(parent);
 	}
-	if (p->sleep_avg < p->parent->sleep_avg)
-		p->parent->sleep_avg = p->parent->sleep_avg /
+	if (p->sleep_avg < parent->sleep_avg)
+		parent->sleep_avg = parent->sleep_avg /
 		(EXIT_WEIGHT + 1) * EXIT_WEIGHT + p->sleep_avg /
 		(EXIT_WEIGHT + 1);
 	task_rq_unlock(rq, &flags);
_

Patches currently in -mm which might be from oleg@xxxxxxxxxx are

origin.patch
sched_exit-fix-parent-time_slice-calculation.patch
sched_exit-move-the-callsite-to-do_exit.patch
sched-uninline-task_rq_lock.patch
proc-remove-tasklist_lock-from-proc_pid_readdir-simply-fix-first_tgid.patch
proc-dont-lock-task_structs-indefinitely.patch
proc-dont-lock-task_structs-indefinitely-task_mmu-small-fixes.patch
simplify-fix-first_tid.patch
cleanup-next_tid.patch
de_thread-fix-lockless-do_each_thread.patch
coredump-optimize-mm-users-traversal.patch
coredump-speedup-sigkill-sending.patch
coredump-kill-ptrace-related-stuff.patch
coredump-kill-ptrace-related-stuff-fix.patch
coredump-dont-take-tasklist_lock.patch
coredump-some-code-relocations.patch
coredump-shutdown-current-process-first.patch
coredump-copy_process-dont-check-signal_group_exit.patch

-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux