Staging: comedi: Remove parentheses around right side assignment
authorHaneen Mohammed <hamohammed.sa@gmail.com>
Fri, 13 Mar 2015 11:29:30 +0000 (14:29 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 15 Mar 2015 17:41:15 +0000 (18:41 +0100)
Parentheses are not needed around the right hand side of an assignment.
This patch remove parenthese of such occurences. Issue was detected and
solved using the following coccinelle script:

@rule1@
identifier x, y, z;
expression E1, E2;
@@

(
x = (y == z);
|
x = (E1 == E2);
|
 x =
-(
...
-)
 ;
)

Signed-off-by: Haneen Mohammed <hamohammed.sa@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/comedi/drivers/addi_apci_3501.c
drivers/staging/comedi/drivers/ni_mio_common.c
drivers/staging/comedi/drivers/serial2002.c

index b8f3366..babbdff 100644 (file)
@@ -270,7 +270,7 @@ static irqreturn_t apci3501_interrupt(int irq, void *d)
 
        /*  Disable Interrupt */
        ul_Command1 = inl(dev->iobase + APCI3501_TIMER_CTRL_REG);
-       ul_Command1 = (ul_Command1 & 0xFFFFF9FDul);
+       ul_Command1 = ul_Command1 & 0xFFFFF9FDul;
        outl(ul_Command1, dev->iobase + APCI3501_TIMER_CTRL_REG);
 
        ui_Timer_AOWatchdog = inl(dev->iobase + APCI3501_TIMER_IRQ_REG) & 0x1;
@@ -282,7 +282,7 @@ static irqreturn_t apci3501_interrupt(int irq, void *d)
        /* Enable Interrupt Send a signal to from kernel to user space */
        send_sig(SIGIO, devpriv->tsk_Current, 0);
        ul_Command1 = inl(dev->iobase + APCI3501_TIMER_CTRL_REG);
-       ul_Command1 = ((ul_Command1 & 0xFFFFF9FDul) | 1 << 1);
+       ul_Command1 = (ul_Command1 & 0xFFFFF9FDul) | 1 << 1;
        outl(ul_Command1, dev->iobase + APCI3501_TIMER_CTRL_REG);
        inl(dev->iobase + APCI3501_TIMER_STATUS_REG);