From: Peter Zijlstra <peterz@infradead.org>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: LKML <linux-kernel@vger.kernel.org>,
Thomas Gleixner <tglx@linutronix.de>,
Mike Galbraith <umgwanakikbuti@gmail.com>,
Eric Dumazet <eric.dumazet@gmail.com>
Subject: Re: [PATCH v2] sched/numa: Fix use of spin_{un}lock_irq() when interrupts are disabled
Date: Wed, 28 May 2014 08:57:08 +0200 [thread overview]
Message-ID: <20140528065708.GK11096@twins.programming.kicks-ass.net> (raw)
In-Reply-To: <20140527170204.2968e4fd@gandalf.local.home>
[-- Attachment #1: Type: text/plain, Size: 761 bytes --]
On Tue, May 27, 2014 at 05:02:04PM -0400, Steven Rostedt wrote:
> As Peter Zijlstra told me, we have the following path:
>
> do_exit()
> exit_itimers()
> itimer_delete()
> spin_lock_irqsave(&timer->it_lock, &flags);
> timer_delete_hook(timer);
> kc->timer_del(timer) := posix_cpu_timer_del()
> put_task_struct()
> __put_task_struct()
> task_numa_free()
> spin_lock(&grp->lock);
>
>
> Which means that task_numa_free() can be called with interrupts
> disabled, which means that we should not be using spin_lock_irq() but
> spin_lock_irqsave() instead. Otherwise we are enabling interrupts while
> holding an interrupt unsafe lock!
>
Duh, yes. Thanks Steve!
[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]
prev parent reply other threads:[~2014-05-28 6:57 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-27 21:02 Steven Rostedt
2014-05-28 6:57 ` Peter Zijlstra [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140528065708.GK11096@twins.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=eric.dumazet@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=rostedt@goodmis.org \
--cc=tglx@linutronix.de \
--cc=umgwanakikbuti@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®