lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Mon, 3 Aug 2015 19:04:28 +0200
From:	Oleg Nesterov <oleg@...hat.com>
To:	Nikolay Borisov <kernel@...p.com>
Cc:	"Linux-Kernel@...r. Kernel. Org" <linux-kernel@...r.kernel.org>,
	riel@...hat.com, Peter Zijlstra <peterz@...radead.org>,
	Steven Rostedt <rostedt@...dmis.org>
Subject: Re: HARD LOCKUP: Strange hard lock up on
	spin_lock(&sighand->siglock);

Sorry for delay, vacation.

I'll try to re-read your email later, just one note for now...

On 07/27, Nikolay Borisov wrote:
>
> Based on that I think could be happening is that the sighand itself is
> being freed while we are in the grace period inside __lock_task_sighand
> but the slab page itself is not freed as per the semantics of
> SLAB_DESTROY_BY_RCU. I looked up the source of this function in the
> latest kernels and saw that Oleg had put a comment clarifying the
> semantics but I'm still not convinced that it is safe. What if
> we are trying to lock the spinlock before this particular slab is
> initialised with sighand_ctor?

But this is not possible? ->sighand can never point to the uninitialized
struct sighand_struct.

Just in case... please note that if ->sighand was freed and then
re-allocated while __lock_task_sighand() spins under rcu_read_lock(),
sighand_ctor() won't be called again (due to SLAB_DESTROY_BY_RCU).
Perhaps this was the source of your confusion?

Oleg.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ