]> Pileus Git - ~andy/linux/commitdiff
staging: ft1000: Fix coding style in ft1000_chkcard function.
authorMarek Belisko <marek.belisko@open-nandra.com>
Thu, 10 Mar 2011 10:51:32 +0000 (11:51 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 14 Mar 2011 18:51:20 +0000 (11:51 -0700)
Signed-off-by: Marek Belisko <marek.belisko@open-nandra.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/ft1000/ft1000-usb/ft1000_hw.c

index 8f38b08f096585150332376c3ad3b731896d6d0c..3f70283d6ece558def51f3e2ebc84cdf624814ce 100644 (file)
@@ -1325,40 +1325,41 @@ Jim
 //              TRUE  (device is present)
 //
 //---------------------------------------------------------------------------
-static int ft1000_chkcard (struct ft1000_device *dev) {
-    u16 tempword;
-    u16 status;
+static int ft1000_chkcard(struct ft1000_device *dev)
+{
+       u16 tempword;
+       u16 status;
        struct ft1000_info *info = netdev_priv(dev->net);
 
-    if (info->fCondResetPend)
-    {
-        DEBUG("ft1000_hw:ft1000_chkcard:Card is being reset, return FALSE\n");
-        return TRUE;
-    }
-
-    // Mask register is used to check for device presence since it is never
-    // set to zero.
-    status = ft1000_read_register(dev, &tempword, FT1000_REG_SUP_IMASK);
-    //DEBUG("ft1000_hw:ft1000_chkcard: read FT1000_REG_SUP_IMASK = %x\n", tempword);
-    if (tempword == 0) {
-        DEBUG("ft1000_hw:ft1000_chkcard: IMASK = 0 Card not detected\n");
-        return FALSE;
-    }
-
-    // The system will return the value of 0xffff for the version register
-    // if the device is not present.
-    status = ft1000_read_register(dev, &tempword, FT1000_REG_ASIC_ID);
-    //DEBUG("ft1000_hw:ft1000_chkcard: read FT1000_REG_ASIC_ID = %x\n", tempword);
-    if (tempword != 0x1b01 ){
-       dev->status |= FT1000_STATUS_CLOSING; //mbelian
-        DEBUG("ft1000_hw:ft1000_chkcard: Version = 0xffff Card not detected\n");
-        return FALSE;
-    }
-    return TRUE;
+       if (info->fCondResetPend) {
+               DEBUG
+                   ("ft1000_hw:ft1000_chkcard:Card is being reset, return FALSE\n");
+               return TRUE;
+       }
+       /* Mask register is used to check for device presence since it is never
+        * set to zero.
+        */
+       status = ft1000_read_register(dev, &tempword, FT1000_REG_SUP_IMASK);
+       //DEBUG("ft1000_hw:ft1000_chkcard: read FT1000_REG_SUP_IMASK = %x\n", tempword);
+       if (tempword == 0) {
+               DEBUG
+                   ("ft1000_hw:ft1000_chkcard: IMASK = 0 Card not detected\n");
+               return FALSE;
+       }
+       /* The system will return the value of 0xffff for the version register
+        * if the device is not present.
+        */
+       status = ft1000_read_register(dev, &tempword, FT1000_REG_ASIC_ID);
+       //DEBUG("ft1000_hw:ft1000_chkcard: read FT1000_REG_ASIC_ID = %x\n", tempword);
+       if (tempword != 0x1b01) {
+               dev->status |= FT1000_STATUS_CLOSING;   //mbelian
+               DEBUG
+                   ("ft1000_hw:ft1000_chkcard: Version = 0xffff Card not detected\n");
+               return FALSE;
+       }
+       return TRUE;
 }
 
-
-
 //---------------------------------------------------------------------------
 //
 // Function:   ft1000_receive_cmd