[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.DEB.2.11.1606010839260.3629@nanos>
Date: Wed, 1 Jun 2016 08:40:59 +0200 (CEST)
From: Thomas Gleixner <tglx@...utronix.de>
To: David Kershner <david.kershner@...sys.com>
cc: corbet@....net, mingo@...hat.com, hpa@...or.com,
gregkh@...uxfoundation.org, erik.arfvidson@...sys.com,
Tim Sell <timothy.sell@...sys.com>, hofrat@...dl.org,
dzickus@...hat.com, jes.sorensen@...hat.com,
alexander.curtin@...sys.com, janani.rvchndrn@...il.com,
sudipm.mukherjee@...il.com, prarit@...hat.com,
david.binder@...sys.com, nhorman@...hat.com,
dan.j.williams@...el.com, linux-kernel@...r.kernel.org,
linux-doc@...r.kernel.org, driverdev-devel@...uxdriverproject.org,
sparmaintainer@...sys.com
Subject: Re: [PATCH v2 10/27] staging: unisys: visorinput: remove unnecessary
locking
On Tue, 31 May 2016, David Kershner wrote:
> + /*
> + * If we're not paused, really enable interrupts.
> + * Regardless of whether we are paused, set a flag indicating
> + * interrupts should be enabled so when we resume, interrupts
> + * will really be enabled.
> + */
> + down_write(&devdata->lock_visor_dev);
Why is this a rw_semaphore? It's only ever taken with down_write() and it's
always the same context. Should be a mutex, right?
While at it, please convert the notifier_lock to a mutex as well.
Thanks,
tglx
Powered by blists - more mailing lists