diff options
Diffstat (limited to 'kernel')
| -rw-r--r-- | kernel/rcupdate.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/kernel/rcupdate.c b/kernel/rcupdate.c index ccc45d49ce71..05ee48316f70 100644 --- a/kernel/rcupdate.c +++ b/kernel/rcupdate.c | |||
| @@ -236,12 +236,8 @@ static void rcu_do_batch(struct rcu_data *rdp) | |||
| 236 | * active batch and the batch to be registered has not already occurred. | 236 | * active batch and the batch to be registered has not already occurred. |
| 237 | * Caller must hold rcu_state.lock. | 237 | * Caller must hold rcu_state.lock. |
| 238 | */ | 238 | */ |
| 239 | static void rcu_start_batch(struct rcu_ctrlblk *rcp, struct rcu_state *rsp, | 239 | static void rcu_start_batch(struct rcu_ctrlblk *rcp, struct rcu_state *rsp) |
| 240 | int next_pending) | ||
| 241 | { | 240 | { |
| 242 | if (next_pending) | ||
| 243 | rcp->next_pending = 1; | ||
| 244 | |||
| 245 | if (rcp->next_pending && | 241 | if (rcp->next_pending && |
| 246 | rcp->completed == rcp->cur) { | 242 | rcp->completed == rcp->cur) { |
| 247 | rcp->next_pending = 0; | 243 | rcp->next_pending = 0; |
| @@ -275,7 +271,7 @@ static void cpu_quiet(int cpu, struct rcu_ctrlblk *rcp, struct rcu_state *rsp) | |||
| 275 | if (cpus_empty(rsp->cpumask)) { | 271 | if (cpus_empty(rsp->cpumask)) { |
| 276 | /* batch completed ! */ | 272 | /* batch completed ! */ |
| 277 | rcp->completed = rcp->cur; | 273 | rcp->completed = rcp->cur; |
| 278 | rcu_start_batch(rcp, rsp, 0); | 274 | rcu_start_batch(rcp, rsp); |
| 279 | } | 275 | } |
| 280 | } | 276 | } |
| 281 | 277 | ||
| @@ -410,7 +406,8 @@ static void __rcu_process_callbacks(struct rcu_ctrlblk *rcp, | |||
| 410 | if (!rcp->next_pending) { | 406 | if (!rcp->next_pending) { |
| 411 | /* and start it/schedule start if it's a new batch */ | 407 | /* and start it/schedule start if it's a new batch */ |
| 412 | spin_lock(&rsp->lock); | 408 | spin_lock(&rsp->lock); |
| 413 | rcu_start_batch(rcp, rsp, 1); | 409 | rcp->next_pending = 1; |
| 410 | rcu_start_batch(rcp, rsp); | ||
| 414 | spin_unlock(&rsp->lock); | 411 | spin_unlock(&rsp->lock); |
| 415 | } | 412 | } |
| 416 | } else { | 413 | } else { |
