Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1212835
| From | Wanpeng Li <wanpeng.li@hotmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] sched: fix tsk->pi_lock isn't held when do_set_cpus_allowed() |
| Date | 2015-08-25 10:40 +0200 |
| Message-ID | <q1hVV-1br-19@gated-at.bofh.it> (permalink) |
| References | <q1hCx-P0-5@gated-at.bofh.it> <q1hCx-P0-3@gated-at.bofh.it> <q1hMe-10g-9@gated-at.bofh.it> <q1hVV-1br-21@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On 8/25/15 4:30 PM, Ingo Molnar wrote:
> * Wanpeng Li <wanpeng.li@hotmail.com> wrote:
>
>>>> --- a/kernel/cpuset.c
>>>> +++ b/kernel/cpuset.c
>>>> @@ -2376,8 +2376,12 @@ void cpuset_cpus_allowed(struct task_struct *tsk, struct cpumask *pmask)
>>>> void cpuset_cpus_allowed_fallback(struct task_struct *tsk)
>>>> {
>>>> + unsigned long flags;
>>>> +
>>>> rcu_read_lock();
>>>> + raw_spin_lock_irqsave(&tsk->pi_lock, flags);
>>>> do_set_cpus_allowed(tsk, task_cs(tsk)->effective_cpus);
>>>> + raw_spin_lock_irqsave(&tsk->pi_lock, flags);
>>> Just curious, Will introduce deadlock after acquire lock twice? ;)
>> Could you point out where acquires lock twice?
> In the code you quote?
Shame me, sorry for sending out the wrong version. I fix in it soon in v2.
Regards,
Wanpeng Li
>
> Thanks,
>
> Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Re: [PATCH] sched: fix tsk->pi_lock isn't held when do_set_cpus_allowed() Leo Yan <leo.yan@linaro.org> - 2015-08-25 10:20 +0200
Re: [PATCH] sched: fix tsk->pi_lock isn't held when do_set_cpus_allowed() Wanpeng Li <wanpeng.li@hotmail.com> - 2015-08-25 10:30 +0200
Re: [PATCH] sched: fix tsk->pi_lock isn't held when do_set_cpus_allowed() Wanpeng Li <wanpeng.li@hotmail.com> - 2015-08-25 10:40 +0200
Re: [PATCH] sched: fix tsk->pi_lock isn't held when do_set_cpus_allowed() Ingo Molnar <mingo@kernel.org> - 2015-08-25 10:40 +0200
csiph-web