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]
Date:	Tue, 29 May 2012 11:11:08 +0100
From:	David Woodhouse <dwmw2@...radead.org>
To:	Christian Dietrich <christian.dietrich@...ormatik.uni-erlangen.de>
Cc:	Artem Bityutskiy <dedekind1@...il.com>,
	Arnd Bergmann <arnd@...db.de>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Jaroslav Kysela <perex@...ex.cz>, Takashi Iwai <tiwai@...e.de>,
	Dmitry Eremin-Solenikov <dbaryshkov@...il.com>,
	David Howells <dhowells@...hat.com>,
	linux-kernel@...r.kernel.org, linux-mtd@...ts.infradead.org,
	alsa-devel@...a-project.org, vamos-dev@...ts.cs.fau.de
Subject: Re: [PATCH] netwinder: nw_gpio_lock is a raw_spinlock_t

On Tue, 2012-05-29 at 12:06 +0200, Christian Dietrich wrote:
> Since nw_gpio_lock is a raw_spinlock_t it should be used with the
> raw_spinlock_* functions and not the spinlock_* variants. Functionally
> this is equivalent at the moment, because the raw_spinlock_t is the
> first field of spinlock_t, and therefore &nw_gpio_lock ==
> &(nw_gpio_lock->rlock). But when other spinlock_t functions use other
> field they read and write random memory.

Hm, why are we exposing a raw spinlock to drivers? 

Should we export a helper function (or macro, I suppose) which does the
appropriate locking *and* the GPIO operation?

-- 
dwmw2

Download attachment "smime.p7s" of type "application/x-pkcs7-signature" (6171 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ