[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20181206135457.d934354e6c1fb5ab4f5c81cc@linux-foundation.org>
Date: Thu, 6 Dec 2018 13:54:57 -0800
From: Andrew Morton <akpm@...ux-foundation.org>
To: Steven Rostedt <rostedt@...dmis.org>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>,
LKML <linux-kernel@...r.kernel.org>,
Ravi Bangoria <ravi.bangoria@...ux.ibm.com>,
Srikar Dronamraju <srikar@...ux.vnet.ibm.com>,
Oleg Nesterov <oleg@...hat.com>, Ingo Molnar <mingo@...nel.org>
Subject: Re: [GIT PULL] Uprobes: Fix kernel oops with
delayed_uprobe_remove()
On Thu, 6 Dec 2018 12:47:19 -0500 Steven Rostedt <rostedt@...dmis.org> wrote:
>
> Uprobes: Fix kernel oops with delayed_uprobe_remove()
>
> There could be a race between task exit and probe unregister:
>
> exit_mm()
> mmput()
> __mmput() uprobe_unregister()
> uprobe_clear_state() put_uprobe()
> delayed_uprobe_remove() delayed_uprobe_remove()
>
> put_uprobe() is calling delayed_uprobe_remove() without taking
> delayed_uprobe_lock and thus the race sometimes results in a
> kernel crash. Fix this by taking delayed_uprobe_lock before
> calling delayed_uprobe_remove() from put_uprobe().
>
> Detailed crash log can be found at:
> Link: http://lkml.kernel.org/r/000000000000140c370577db5ece@google.com
>
> Link: http://lkml.kernel.org/r/20181205033423.26242-1-ravi.bangoria@linux.ibm.com
>
> Acked-by: Oleg Nesterov <oleg@...hat.com>
> Reviewed-by: Srikar Dronamraju <srikar@...ux.vnet.ibm.com>
> Reported-by: syzbot+cb1fb754b771caca0a88@...kaller.appspotmail.com
> Fixes: 1cc33161a83d ("uprobes: Support SDT markers having reference count (semaphore)")
> Signed-off-by: Ravi Bangoria <ravi.bangoria@...ux.ibm.com>
> Signed-off-by: Steven Rostedt (VMware) <rostedt@...dmis.org>
>
No cc:stable?
Powered by blists - more mailing lists