]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
staging: comedi: addi_apci_3xxx: checkpatch.pl cleanup (else after return)
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Wed, 16 Jul 2014 17:43:17 +0000 (10:43 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 16 Jul 2014 20:34:21 +0000 (13:34 -0700)
Fix the checkpatch.pl warning in this file:

WARNING: else is not generally useful after a break or return

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

index 0532b6cc40e378010ec7d38b1700aeea30ff1ac2..12096ee584ec4f643e8eb886cc396a5318c2c285 100644 (file)
@@ -389,9 +389,8 @@ static int apci3xxx_ai_started(struct comedi_device *dev)
 
        if ((readl(devpriv->mmio + 8) & 0x80000) == 0x80000)
                return 1;
-       else
-               return 0;
 
+       return 0;
 }
 
 static int apci3xxx_ai_setup(struct comedi_device *dev, unsigned int chanspec)
@@ -696,10 +695,9 @@ static int apci3xxx_dio_insn_config(struct comedi_device *dev,
                /* ignore all other instructions for ports 0 and 1 */
                if (chan < 16)
                        return -EINVAL;
-               else
-                       /* changing any channel in port 2 */
-                       /* changes the entire port        */
-                       mask = 0xff0000;
+
+               /* changing any channel in port 2 changes the entire port */
+               mask = 0xff0000;
        }
 
        ret = comedi_dio_insn_config(dev, s, insn, data, mask);