staging: comedi: pcl816: exit interrupt quick when there is nothing to do
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Tue, 4 Mar 2014 18:29:47 +0000 (11:29 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 7 Mar 2014 01:06:13 +0000 (17:06 -0800)
commitd7a9f769ba0134cbcc55008f167c97227b024798
tree739f82bbd5a08f028350656df3acb6707c0abb67
parent776d5b5c44d7f9c8bb21c7f75b82fb959cc62446
staging: comedi: pcl816: exit interrupt quick when there is nothing to do

If an async ai command is not running or the int816_mode is 0 the
interrupt routine doesn't do anything other than spew some noise and
clear the interrupt request in the hardware.

Because this driver is manually attached, the "premature interrupt"
check in the interrupt handler should never happen. The interrupt is
only hooked up during the attach and it's released during the detach.

Combine these checks so that the interrupt function exits quick if it
has nothing to handle. Remove the noise.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/comedi/drivers/pcl816.c