[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20130312191029.GC19942@opensource.wolfsonmicro.com>
Date: Tue, 12 Mar 2013 19:10:29 +0000
From: Mark Brown <broonie@...nsource.wolfsonmicro.com>
To: Bryan Wu <cooloney@...il.com>
Cc: Ian Lartey <ian@...mlogic.co.uk>, linux-kernel@...r.kernel.org,
linux-leds@...r.kernel.org, devicetree-discuss@...ts.ozlabs.org,
ldewangan@...dia.com, j-keerthy@...com, gg@...mlogic.co.uk,
rpurdie@...ys.net, grant.likely@...retlab.ca,
rob.herring@...xeda.com, sameo@...ux.intel.com
Subject: Re: [PATCH v2 1/2] leds: Add support for Palmas LEDs
On Tue, Mar 12, 2013 at 11:57:50AM -0700, Bryan Wu wrote:
> On Thu, Feb 28, 2013 at 7:21 AM, Ian Lartey <ian@...mlogic.co.uk> wrote:
> > + spinlock_t value_lock;
> I think you don't need this spinlock to protect the value, the mutex is enough.
You need to use a spinlock because values can be set from hard IRQ
context so you can't take a mutex there. Someone should really factor
this out into the framework in their copious free time, the set and
schedule pattern is very common in drivers.
Download attachment "signature.asc" of type "application/pgp-signature" (837 bytes)
Powered by blists - more mailing lists