Message ID | 20200411115420.038161644@linuxfoundation.org |
---|---|
State | Superseded |
Headers | show |
Series | None | expand |
--- a/kernel/padata.c +++ b/kernel/padata.c @@ -614,8 +614,8 @@ int padata_set_cpumask(struct padata_ins struct cpumask *serial_mask, *parallel_mask; int err = -EINVAL; - mutex_lock(&pinst->lock); get_online_cpus(); + mutex_lock(&pinst->lock); switch (cpumask_type) { case PADATA_CPU_PARALLEL: @@ -633,8 +633,8 @@ int padata_set_cpumask(struct padata_ins err = __padata_set_cpumasks(pinst, parallel_mask, serial_mask); out: - put_online_cpus(); mutex_unlock(&pinst->lock); + put_online_cpus(); return err; }