diff options
author | Paul Gortmaker <paul.gortmaker@windriver.com> | 2011-01-30 12:48:12 -0500 |
---|---|---|
committer | Paul Gortmaker <paul.gortmaker@windriver.com> | 2011-01-30 12:48:12 -0500 |
commit | f3044ddbb82e64a8a10bf0d2d93d9e6ded04cc00 (patch) | |
tree | 8b512a83ebda763045c7b32ba1f5fdf9b0dbefab | |
parent | eec7ecc3189a2f500b2e6cc674fcf0c629bf95da (diff) | |
download | rt-patches-f3044ddbb82e64a8a10bf0d2d93d9e6ded04cc00.tar.gz |
refresh sched-Fix-TASK_WAKING-vs-fork-deadlock.patchv2.6.33-1752-gf66ffde
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
-rw-r--r-- | sched-Fix-TASK_WAKING-vs-fork-deadlock.patch | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/sched-Fix-TASK_WAKING-vs-fork-deadlock.patch b/sched-Fix-TASK_WAKING-vs-fork-deadlock.patch index 482fd11..bfc6ef0 100644 --- a/sched-Fix-TASK_WAKING-vs-fork-deadlock.patch +++ b/sched-Fix-TASK_WAKING-vs-fork-deadlock.patch @@ -1,4 +1,4 @@ -From f406c449254cedddfdd649bc292231627584c7b1 Mon Sep 17 00:00:00 2001 +From 7b94ba84bd232df5b682f079b1a095b0adff904f Mon Sep 17 00:00:00 2001 From: Peter Zijlstra <a.p.zijlstra@chello.nl> Date: Tue, 20 Jul 2010 19:11:55 +0200 Subject: [PATCH] sched: Fix TASK_WAKING vs fork deadlock @@ -31,10 +31,10 @@ LKML-Reference: <new-submission> Signed-off-by: Ingo Molnar <mingo@elte.hu> diff --git a/include/linux/sched.h b/include/linux/sched.h -index 01d8b97..b4f912f 100644 +index 8b724c5..6160322 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h -@@ -1165,7 +1165,8 @@ struct sched_class { +@@ -1160,7 +1160,8 @@ struct sched_class { void (*put_prev_task) (struct rq *rq, struct task_struct *p); #ifdef CONFIG_SMP @@ -42,13 +42,13 @@ index 01d8b97..b4f912f 100644 + int (*select_task_rq)(struct rq *rq, struct task_struct *p, + int sd_flag, int flags); - unsigned long (*load_balance) (struct rq *this_rq, int this_cpu, - struct rq *busiest, unsigned long max_load_move, + void (*pre_schedule) (struct rq *this_rq, struct task_struct *task); + void (*post_schedule) (struct rq *this_rq); diff --git a/kernel/sched.c b/kernel/sched.c -index c36457d..f03f1d2 100644 +index 76380b2..fa3f4e4 100644 --- a/kernel/sched.c +++ b/kernel/sched.c -@@ -1020,14 +1020,10 @@ static inline void finish_lock_switch(struct rq *rq, struct task_struct *prev) +@@ -982,14 +982,10 @@ static inline void finish_lock_switch(struct rq *rq, struct task_struct *prev) /* * Check whether the task is waking, we use this to synchronize against * ttwu() so that task_cpu() reports a stable number. @@ -64,7 +64,7 @@ index c36457d..f03f1d2 100644 } /* -@@ -2419,9 +2415,9 @@ static int select_fallback_rq(int cpu, struct task_struct *p) +@@ -2388,9 +2384,9 @@ static int select_fallback_rq(int cpu, struct task_struct *p) * The caller (fork, wakeup) owns TASK_WAKING, ->cpus_allowed is stable. */ static inline @@ -76,7 +76,7 @@ index c36457d..f03f1d2 100644 /* * In order not to call set_task_cpu() on a blocking task we need -@@ -2492,17 +2488,10 @@ static int try_to_wake_up(struct task_struct *p, unsigned int state, +@@ -2461,17 +2457,10 @@ static int try_to_wake_up(struct task_struct *p, unsigned int state, if (p->sched_class->task_waking) p->sched_class->task_waking(rq, p); @@ -97,7 +97,7 @@ index c36457d..f03f1d2 100644 rq = cpu_rq(cpu); raw_spin_lock(&rq->lock); -@@ -2710,11 +2699,11 @@ void sched_fork(struct task_struct *p, int clone_flags) +@@ -2679,11 +2668,11 @@ void sched_fork(struct task_struct *p, int clone_flags) __sched_fork(p); /* @@ -111,7 +111,7 @@ index c36457d..f03f1d2 100644 /* * Revert to default priority/policy on fork if requested. -@@ -2787,28 +2776,23 @@ void wake_up_new_task(struct task_struct *p, unsigned long clone_flags) +@@ -2756,28 +2745,23 @@ void wake_up_new_task(struct task_struct *p, unsigned long clone_flags) int cpu = get_cpu(); #ifdef CONFIG_SMP @@ -148,7 +148,7 @@ index c36457d..f03f1d2 100644 update_rq_clock(rq); activate_task(rq, p, 0, false); trace_sched_wakeup_new(rq, p, 1); -@@ -3330,19 +3314,15 @@ void sched_exec(void) +@@ -3261,19 +3245,15 @@ void sched_exec(void) { struct task_struct *p = current; struct migration_req req; @@ -173,7 +173,7 @@ index c36457d..f03f1d2 100644 /* * select_task_rq() can race against ->cpus_allowed */ -@@ -3360,6 +3340,7 @@ void sched_exec(void) +@@ -3291,6 +3271,7 @@ void sched_exec(void) return; } @@ -182,7 +182,7 @@ index c36457d..f03f1d2 100644 } diff --git a/kernel/sched_fair.c b/kernel/sched_fair.c -index b49cf96..f3ab738 100644 +index 1693baf..f6ebcd6 100644 --- a/kernel/sched_fair.c +++ b/kernel/sched_fair.c @@ -1458,7 +1458,8 @@ select_idle_sibling(struct task_struct *p, struct sched_domain *sd, int target) @@ -209,7 +209,7 @@ index b49cf96..f3ab738 100644 if (affine_sd && wake_affine(affine_sd, p, sync)) diff --git a/kernel/sched_idletask.c b/kernel/sched_idletask.c -index 5f93b57..d7a576d 100644 +index a8a6d8a..5af709f 100644 --- a/kernel/sched_idletask.c +++ b/kernel/sched_idletask.c @@ -6,7 +6,8 @@ @@ -223,10 +223,10 @@ index 5f93b57..d7a576d 100644 return task_cpu(p); /* IDLE tasks as never migrated */ } diff --git a/kernel/sched_rt.c b/kernel/sched_rt.c -index 0e4b15d..a61505d 100644 +index ca2b89f..7b589ee 100644 --- a/kernel/sched_rt.c +++ b/kernel/sched_rt.c -@@ -999,10 +999,9 @@ static void yield_task_rt(struct rq *rq) +@@ -1005,10 +1005,9 @@ static void yield_task_rt(struct rq *rq) #ifdef CONFIG_SMP static int find_lowest_rq(struct task_struct *task); |