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] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.LFD.2.00.0911302328350.24119@localhost.localdomain>
Date:	Mon, 30 Nov 2009 23:37:16 +0100 (CET)
From:	Thomas Gleixner <tglx@...utronix.de>
To:	Linus Torvalds <torvalds@...ux-foundation.org>
cc:	Peter Zijlstra <peterz@...radead.org>, Ingo Molnar <mingo@...e.hu>,
	Christoph Hellwig <hch@...radead.org>,
	Nick Piggin <npiggin@...e.de>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [rfc] "fair" rw spinlocks

On Mon, 30 Nov 2009, Linus Torvalds wrote:
> On Mon, 30 Nov 2009, Thomas Gleixner wrote:
> > 
> > Yeah, forgot to mention sched.c, but that's solvable
> 
> It should be fairly easy to add a few 'spin_lock(&tasklist_lock)' around 
> stuff that really depended on exclusion from writers. That should 
> _hopefully_ be the rare case.
> 
> The biggest problem is that there will almost inevitably be things that 
> get missed, and any races exposed by lacking locking will be _very_ hard 
> to debug and trigger. So what I'd be worried about is not getting to a 
> "practically working" state, but any really subtle cases that nobody 
> really hits in practice.

I'm aware of that. The number of places where we read_lock
tasklist_lock is 79 in 36 files right now. That's not a horrible task
to go through them one by one and do a case by case conversion with a
proper changelog. That would only leave the write_lock sites. 

We can then either do the rw_lock to spin_lock conversion or keep the
rw_lock which has no readers anymore and behaves like a spinlock for a
transition time so reverts of one of the read_lock -> rcu patches
could be done to debug stuff.

Thanks,

	tglx
--
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