Commit 1e35eaa2 authored by Oleg Nesterov's avatar Oleg Nesterov Committed by Linus Torvalds

cleanup_workqueue_thread: remove the unneeded "cpu" parameter

cleanup_workqueue_thread() doesn't need the second argument, remove it.
Signed-off-by: default avatarOleg Nesterov <oleg@tv-sign.ru>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 00dfcaf7
...@@ -772,7 +772,7 @@ struct workqueue_struct *__create_workqueue_key(const char *name, ...@@ -772,7 +772,7 @@ struct workqueue_struct *__create_workqueue_key(const char *name,
} }
EXPORT_SYMBOL_GPL(__create_workqueue_key); EXPORT_SYMBOL_GPL(__create_workqueue_key);
static void cleanup_workqueue_thread(struct cpu_workqueue_struct *cwq, int cpu) static void cleanup_workqueue_thread(struct cpu_workqueue_struct *cwq)
{ {
/* /*
* Our caller is either destroy_workqueue() or CPU_DEAD, * Our caller is either destroy_workqueue() or CPU_DEAD,
...@@ -808,7 +808,6 @@ static void cleanup_workqueue_thread(struct cpu_workqueue_struct *cwq, int cpu) ...@@ -808,7 +808,6 @@ static void cleanup_workqueue_thread(struct cpu_workqueue_struct *cwq, int cpu)
void destroy_workqueue(struct workqueue_struct *wq) void destroy_workqueue(struct workqueue_struct *wq)
{ {
const cpumask_t *cpu_map = wq_cpu_map(wq); const cpumask_t *cpu_map = wq_cpu_map(wq);
struct cpu_workqueue_struct *cwq;
int cpu; int cpu;
get_online_cpus(); get_online_cpus();
...@@ -816,10 +815,8 @@ void destroy_workqueue(struct workqueue_struct *wq) ...@@ -816,10 +815,8 @@ void destroy_workqueue(struct workqueue_struct *wq)
list_del(&wq->list); list_del(&wq->list);
spin_unlock(&workqueue_lock); spin_unlock(&workqueue_lock);
for_each_cpu_mask(cpu, *cpu_map) { for_each_cpu_mask(cpu, *cpu_map)
cwq = per_cpu_ptr(wq->cpu_wq, cpu); cleanup_workqueue_thread(per_cpu_ptr(wq->cpu_wq, cpu));
cleanup_workqueue_thread(cwq, cpu);
}
put_online_cpus(); put_online_cpus();
free_percpu(wq->cpu_wq); free_percpu(wq->cpu_wq);
...@@ -860,7 +857,7 @@ static int __devinit workqueue_cpu_callback(struct notifier_block *nfb, ...@@ -860,7 +857,7 @@ static int __devinit workqueue_cpu_callback(struct notifier_block *nfb,
case CPU_UP_CANCELED: case CPU_UP_CANCELED:
start_workqueue_thread(cwq, -1); start_workqueue_thread(cwq, -1);
case CPU_DEAD: case CPU_DEAD:
cleanup_workqueue_thread(cwq, cpu); cleanup_workqueue_thread(cwq);
break; break;
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment