]> git.karo-electronics.de Git - linux-beck.git/commit
staging: comedi: ni_mio_common: always lock in ni_ai_poll()
authorIan Abbott <abbotti@mev.co.uk>
Mon, 24 Sep 2012 15:27:59 +0000 (16:27 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 26 Sep 2012 17:45:38 +0000 (10:45 -0700)
commit3cd73bc1cf59b2c9232d9889ba2b148e262054b6
tree2284a3ed15ace430a80182ff36798138d39f8246
parentaffdc230d7d328d2b602113e459a57d9de5ded08
staging: comedi: ni_mio_common: always lock in ni_ai_poll()

`ni_ai_poll()` currently acquires (and later releases) the comedi
device's spin-lock iff `in_interrupt()` returns 0.  However, it is only
called during processing of a `COMEDI_POLL` ioctl so `in_interrupt()`
will always return 0 in this case.  Remove this test and acquire/release
the spin-lock unconditionally.  This eliminates a sparse warning about
different lock contexts for basic block.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/comedi/drivers/ni_mio_common.c