]> git.karo-electronics.de Git - mv-sheeva.git/commitdiff
Staging: comedi: fix brace coding style issue in daqboard2000.c
authorRavishankar karkala Mallikarjunayya <ravishankar.km@greenturtles.in>
Sat, 19 Nov 2011 04:36:52 +0000 (10:06 +0530)
committerGreg Kroah-Hartman <gregkh@suse.de>
Sun, 27 Nov 2011 02:50:45 +0000 (18:50 -0800)
This is a patch to the daqboard2000.c file that fixes up a brace
warning found by the checkpatch.pl tool.

Signed-off-by: Ravishankar Karkala Mallikarjunayya <ravishankar.km@greenturtles.in>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/comedi/drivers/daqboard2000.c

index 542c76006369a97b855e1733729eec6bc1ea7079..9958bd5044c5d41c096fd3583f98ceeb9d2fc532 100644 (file)
@@ -657,9 +657,8 @@ static void daqboard2000_activateReferenceDacs(struct comedi_device *dev)
        /*  Set the + reference dac value in the FPGA */
        fpga->refDacs = 0x80 | DAQBOARD2000_PosRefDacSelect;
        for (timeout = 0; timeout < 20; timeout++) {
-               if ((fpga->dacControl & DAQBOARD2000_RefBusy) == 0) {
+               if ((fpga->dacControl & DAQBOARD2000_RefBusy) == 0)
                        break;
-               }
                udelay(2);
        }
 /*  printk("DAQBOARD2000_PosRefDacSelect %d\n", timeout);*/
@@ -667,9 +666,8 @@ static void daqboard2000_activateReferenceDacs(struct comedi_device *dev)
        /*  Set the - reference dac value in the FPGA */
        fpga->refDacs = 0x80 | DAQBOARD2000_NegRefDacSelect;
        for (timeout = 0; timeout < 20; timeout++) {
-               if ((fpga->dacControl & DAQBOARD2000_RefBusy) == 0) {
+               if ((fpga->dacControl & DAQBOARD2000_RefBusy) == 0)
                        break;
-               }
                udelay(2);
        }
 /*  printk("DAQBOARD2000_NegRefDacSelect %d\n", timeout);*/
@@ -742,9 +740,9 @@ static int daqboard2000_attach(struct comedi_device *dev,
        slot = it->options[1];
 
        result = alloc_private(dev, sizeof(struct daqboard2000_private));
-       if (result < 0) {
+       if (result < 0)
                return -ENOMEM;
-       }
+
        for (card = pci_get_device(0x1616, 0x0409, NULL);
             card != NULL; card = pci_get_device(0x1616, 0x0409, card)) {
                if (bus || slot) {
@@ -793,9 +791,8 @@ static int daqboard2000_attach(struct comedi_device *dev,
            ioremap(pci_resource_start(card, 0), DAQBOARD2000_PLX_SIZE);
        devpriv->daq =
            ioremap(pci_resource_start(card, 2), DAQBOARD2000_DAQ_SIZE);
-       if (!devpriv->plx || !devpriv->daq) {
+       if (!devpriv->plx || !devpriv->daq)
                return -ENOMEM;
-       }
 
        result = alloc_subdevices(dev, 3);
        if (result < 0)
@@ -868,18 +865,17 @@ static int daqboard2000_detach(struct comedi_device *dev)
        if (dev->subdevices)
                subdev_8255_cleanup(dev, dev->subdevices + 2);
 
-       if (dev->irq) {
+       if (dev->irq)
                free_irq(dev->irq, dev);
-       }
+
        if (devpriv) {
                if (devpriv->daq)
                        iounmap(devpriv->daq);
                if (devpriv->plx)
                        iounmap(devpriv->plx);
                if (devpriv->pci_dev) {
-                       if (devpriv->got_regions) {
+                       if (devpriv->got_regions)
                                comedi_pci_disable(devpriv->pci_dev);
-                       }
                        pci_dev_put(devpriv->pci_dev);
                }
        }