DBG_FUNC("wvlan_uil");
        DBG_ENTER(DbgInfo);
 
-       switch(urq->command) {
+       switch (urq->command) {
          case UIL_FUN_CONNECT:
                DBG_TRACE(DbgInfo, "IOCTL: WVLAN2_IOCTL_UIL -- WVLAN2_UIL_CONNECT\n");
                ioctl_ret = wvlan_uil_connect(urq, lp);
        DBG_ENTER(DbgInfo);
 
 
-       if(!(lp->flags & WVLAN2_UIL_CONNECTED)) {
+       if (!(lp->flags & WVLAN2_UIL_CONNECTED)) {
                lp->flags |= WVLAN2_UIL_CONNECTED;
                urq->hcfCtx = &(lp->hcfCtx);
                urq->result = UIL_SUCCESS;
        DBG_ENTER(DbgInfo);
 
 
-       if(urq->hcfCtx == &(lp->hcfCtx)) {
+       if (urq->hcfCtx == &(lp->hcfCtx)) {
                if (lp->flags & WVLAN2_UIL_CONNECTED) {
                        lp->flags &= ~WVLAN2_UIL_CONNECTED;
                        /*
        DBG_ENTER(DbgInfo);
 
 
-       if(urq->hcfCtx == &(lp->hcfCtx)) {
+       if (urq->hcfCtx == &(lp->hcfCtx)) {
                /* Make sure there's an LTV in the request buffer */
                ltv = (ltv_t *)urq->data;
-               if(ltv != NULL) {
+               if (ltv != NULL) {
                        /* Switch on the Type field of the LTV contained in the request
                           buffer */
-                       switch(ltv->typ) {
+                       switch (ltv->typ) {
                        case UIL_ACT_BLOCK:
                                DBG_TRACE(DbgInfo, "UIL_ACT_BLOCK\n");
                                result = wvlan_uil_block(urq, lp);
        DBG_FUNC("wvlan_uil_block");
        DBG_ENTER(DbgInfo);
 
-       if(urq->hcfCtx == &(lp->hcfCtx)) {
-               if(capable(CAP_NET_ADMIN)) {
+       if (urq->hcfCtx == &(lp->hcfCtx)) {
+               if (capable(CAP_NET_ADMIN)) {
                        lp->flags |= WVLAN2_UIL_BUSY;
                        netif_stop_queue(lp->dev);
                        WL_WDS_NETIF_STOP_QUEUE(lp);
        DBG_FUNC("wvlan_uil_unblock");
        DBG_ENTER(DbgInfo);
 
-       if(urq->hcfCtx == &(lp->hcfCtx)) {
-               if(capable(CAP_NET_ADMIN)) {
+       if (urq->hcfCtx == &(lp->hcfCtx)) {
+               if (capable(CAP_NET_ADMIN)) {
                        if (lp->flags & WVLAN2_UIL_BUSY) {
                                lp->flags &= ~WVLAN2_UIL_BUSY;
                                netif_wake_queue(lp->dev);
        DBG_FUNC("wvlan_uil_send_diag_msg");
        DBG_ENTER(DbgInfo);
 
-       if(urq->hcfCtx == &(lp->hcfCtx)) {
-               if(capable(CAP_NET_ADMIN)) {
+       if (urq->hcfCtx == &(lp->hcfCtx)) {
+               if (capable(CAP_NET_ADMIN)) {
                        if ((urq->data != NULL) && (urq->len != 0)) {
                                if (lp->hcfCtx.IFB_RscInd != 0) {
                                        u_char *data;
        DBG_ENTER(DbgInfo);
 
 
-       if(urq->hcfCtx == &(lp->hcfCtx)) {
-               if(capable(CAP_NET_ADMIN)) {
-                       if((urq->data != NULL) && (urq->len != 0)) {
+       if (urq->hcfCtx == &(lp->hcfCtx)) {
+               if (capable(CAP_NET_ADMIN)) {
+                       if ((urq->data != NULL) && (urq->len != 0)) {
                                /* Make sure that we have at least a command and length to send. */
-                               if(urq->len < (sizeof(hcf_16) * 2)) {
+                               if (urq->len < (sizeof(hcf_16) * 2)) {
                                        urq->len = sizeof(lp->ltvRecord);
                                        urq->result = UIL_ERR_LEN;
                                        DBG_ERROR(DbgInfo, "No Length/Type in LTV!!!\n");
 
                                /* Verify the user buffer */
                                result = verify_area(VERIFY_READ, urq->data, urq->len);
-                               if(result != 0) {
+                               if (result != 0) {
                                        urq->result = UIL_FAILURE;
                                        DBG_ERROR(DbgInfo, "verify_area(), VERIFY_READ FAILED\n");
                                        DBG_LEAVE(DbgInfo);
 
                                /* Make sure the incoming LTV record length is within the bounds of the
                                   IOCTL length */
-                               if(((lp->ltvRecord.len + 1) * sizeof(hcf_16)) > urq->len) {
+                               if (((lp->ltvRecord.len + 1) * sizeof(hcf_16)) > urq->len) {
                                        urq->len = sizeof(lp->ltvRecord);
                                        urq->result = UIL_ERR_LEN;
                                        DBG_ERROR(DbgInfo, "UIL_ERR_LEN\n");
                                /* If the requested length is greater than the size of our local
                                   LTV record, try to allocate it from the kernel stack.
                                   Otherwise, we just use our local LTV record. */
-                               if(urq->len > sizeof(lp->ltvRecord)) {
+                               if (urq->len > sizeof(lp->ltvRecord)) {
                                        pLtv = kmalloc(urq->len, GFP_KERNEL);
                                        if (pLtv != NULL) {
                                                ltvAllocated = TRUE;
                                /* We need to snoop the commands to see if there is anything we
                                   need to store for the purposes of a reset or start/stop
                                   sequence. Perform endian translation as needed */
-                               switch(pLtv->typ) {
+                               switch (pLtv->typ) {
                                case CFG_CNF_PORT_TYPE:
                                        lp->PortType    = pLtv->u.u16[0];
                                        pLtv->u.u16[0]  = CNV_INT_TO_LITTLE(pLtv->u.u16[0]);
                                        pLtv->u.u16[0] = CNV_INT_TO_LITTLE(pLtv->u.u16[0]);
 
                                        /* take care of the special network name "ANY" case */
-                                       if((strlen(&pLtv->u.u8[2]       ) == 0) ||
+                                       if ((strlen(&pLtv->u.u8[2]) == 0) ||
                                           (strcmp(&pLtv->u.u8[2], "ANY") == 0) ||
                                           (strcmp(&pLtv->u.u8[2], "any") == 0)) {
                                                /* set the SSID_STRCT llen field (u16[0]) to zero, and the
                                   being sent to the card, as they require a call to
                                   UIL_ACT_APPLY to take effect. Dynamic Entities will be sent
                                   immediately */
-                               switch(pLtv->typ) {
+                               switch (pLtv->typ) {
                                case CFG_CNF_PORT_TYPE:
                                case CFG_CNF_OWN_MAC_ADDR:
                                case CFG_CNF_OWN_CHANNEL:
                                        break;
                                /* Deal with this dynamic MSF RID, as it's required for WPA */
                                case CFG_DRIVER_ENABLE:
-                                       if(lp->driverEnable) {
+                                       if (lp->driverEnable) {
                                                //hcf_cntl_port(&(lp->hcfCtx),
                                                //               HCF_PORT_ENABLE | HCF_PORT_0);
                                                // //hcf_cntl(&(lp->hcfCtx),
                                        break;
                                }
 
-                               if(ltvAllocated) {
+                               if (ltvAllocated) {
                                        kfree(pLtv);
                                }
                        } else {
        DBG_FUNC("wvlan_uil_get_info");
        DBG_ENTER(DbgInfo);
 
-       if(urq->hcfCtx == &(lp->hcfCtx)) {
-               if((urq->data != NULL) && (urq->len != 0)) {
+       if (urq->hcfCtx == &(lp->hcfCtx)) {
+               if ((urq->data != NULL) && (urq->len != 0)) {
                        ltv_t      *pLtv;
                        bool_t      ltvAllocated = FALSE;
 
                        /* Make sure that we have at least a command and length */
-                       if(urq->len < (sizeof(hcf_16) * 2)) {
+                       if (urq->len < (sizeof(hcf_16) * 2)) {
                                urq->len = sizeof(lp->ltvRecord);
                                DBG_ERROR(DbgInfo, "No Length/Type in LTV!!!\n");
                                DBG_ERROR(DbgInfo, "UIL_ERR_LEN\n");
 
                        /* Verify the user's LTV record header. */
                        result = verify_area(VERIFY_READ, urq->data, sizeof(hcf_16) * 2);
-                       if(result != 0) {
+                       if (result != 0) {
                                DBG_ERROR(DbgInfo, "verify_area(), VERIFY_READ FAILED\n");
                                urq->result = UIL_FAILURE;
                                DBG_LEAVE(DbgInfo);
 
                        /* Make sure the incoming LTV record length is within the bounds of
                           the IOCTL length. */
-                       if(((lp->ltvRecord.len + 1) * sizeof(hcf_16)) > urq->len) {
+                       if (((lp->ltvRecord.len + 1) * sizeof(hcf_16)) > urq->len) {
                                DBG_ERROR(DbgInfo, "Incoming LTV too big\n");
                                urq->len = sizeof(lp->ltvRecord);
                                urq->result = UIL_ERR_LEN;
                                break;
                        case CFG_IFB:
                                /* IFB can be a security hole */
-                               if(!capable(CAP_NET_ADMIN)) {
+                               if (!capable(CAP_NET_ADMIN)) {
                                        result = -EPERM;
                                        break;
                                }
 
                                /* Verify the user buffer */
                                result = verify_area(VERIFY_WRITE, urq->data, urq->len);
-                               if(result != 0) {
+                               if (result != 0) {
                                        DBG_ERROR(DbgInfo, "verify_area(), VERIFY_WRITE FAILED\n");
                                        urq->result = UIL_FAILURE;
                                        break;
                                /* If the requested length is greater than the size of our local
                                   LTV record, try to allocate it from the kernel stack.
                                   Otherwise, we just use our local LTV record. */
-                               if(urq->len > sizeof(lp->ltvRecord)) {
+                               if (urq->len > sizeof(lp->ltvRecord)) {
                                        pLtv = kmalloc(urq->len, GFP_KERNEL);
                                        if (pLtv != NULL) {
                                                ltvAllocated = TRUE;
                        }
 
                        /* Handle endian conversion of special fields */
-                       switch(lp->ltvRecord.typ) {
+                       switch (lp->ltvRecord.typ) {
                        /* simple int gets just need the first hcf_16 byte flipped */
                        case CFG_CNF_PORT_TYPE:
                        case CFG_CNF_OWN_CHANNEL:
                        case CFG_CFI_ACT_RANGES_STA:
                        case CFG_CUR_SCALE_THRH:
                        case CFG_AUTHENTICATION_ALGORITHMS:
-                               for(i = 0; i < (lp->ltvRecord.len - 1); i++) {
+                               for (i = 0; i < (lp->ltvRecord.len - 1); i++) {
                                        lp->ltvRecord.u.u16[i] = CNV_INT_TO_LITTLE(lp->ltvRecord.u.u16[i]);
                                }
                                break;
                        // Copy the LTV into the user's buffer.
                        copy_to_user(urq->data, &(lp->ltvRecord), urq->len);
 
-                       if(ltvAllocated) {
+                       if (ltvAllocated) {
                                kfree(&(lp->ltvRecord));
                        }
 
 
 
        /* Make sure that user buffer can handle the driver information buffer */
-       if(urq->len < sizeof(lp->driverInfo)) {
+       if (urq->len < sizeof(lp->driverInfo)) {
                urq->len = sizeof(lp->driverInfo);
                urq->result = UIL_ERR_LEN;
                DBG_LEAVE(DbgInfo);
 
        /* Verify the user buffer. */
        result = verify_area(VERIFY_WRITE, urq->data, sizeof(lp->driverInfo));
-       if(result != 0) {
+       if (result != 0) {
                urq->result = UIL_FAILURE;
                DBG_LEAVE(DbgInfo);
                return result;
 
 
        /* Make sure that user buffer can handle the driver identity structure. */
-       if(urq->len < sizeof(lp->driverIdentity)) {
+       if (urq->len < sizeof(lp->driverIdentity)) {
                urq->len = sizeof(lp->driverIdentity);
                urq->result = UIL_ERR_LEN;
                DBG_LEAVE(DbgInfo);
 
        /* Verify the user buffer. */
        result = verify_area(VERIFY_WRITE, urq->data, sizeof(lp->driverIdentity));
-       if(result != 0) {
+       if (result != 0) {
                urq->result = UIL_FAILURE;
                DBG_LEAVE(DbgInfo);
                return result;
 
         status = hcf_get_info(&(lp->hcfCtx), (LTVP)&(lp->ltvRecord));
 
-        if(status == HCF_SUCCESS) {
+        if (status == HCF_SUCCESS) {
                 pName = (wvName_t *)&(lp->ltvRecord.u.u32);
 
                memset(extra, '\0', HCF_MAX_NAME_LEN);
 
         status = hcf_get_info(&(lp->hcfCtx), (LTVP)&(lp->ltvRecord));
 
-        if(status == HCF_SUCCESS) {
+        if (status == HCF_SUCCESS) {
                 pName = (wvName_t *)&(lp->ltvRecord.u.u32);
 
                memset(extra, '\0', HCF_MAX_NAME_LEN);
         /* Validate the new value */
         portType = *((__u32 *)extra);
 
-        if(!((portType == 1) || (portType == 3))) {
+        if (!((portType == 1) || (portType == 3))) {
                 ret = -EINVAL;
                goto out_unlock;
         }
 
         status = hcf_get_info(&(lp->hcfCtx), (LTVP)&(lp->ltvRecord));
 
-        if(status == HCF_SUCCESS) {
+        if (status == HCF_SUCCESS) {
                 pPortType = (hcf_16 *)&(lp->ltvRecord.u.u32);
 
                 *pData = CNV_LITTLE_TO_INT(*pPortType);
 
        DBG_PRINT("io_base: 0x%08x\n", io_base);
 
-       switch(rrq->typ) {
+       switch (rrq->typ) {
          case WL_IOCTL_RTS_READ:
                DBG_TRACE(DbgInfo, "IOCTL: WVLAN2_IOCTL_RTS -- WL_IOCTL_RTS_READ\n");
                rrq->data[0] = IN_PORT_WORD(io_base + rrq->reg);
          case WL_IOCTL_RTS_BATCH_READ:
                DBG_TRACE(DbgInfo, "IOCTL: WVLAN2_IOCTL_RTS -- WL_IOCTL_RTS_BATCH_READ\n");
                IN_PORT_STRING_16(io_base + rrq->reg, rrq->data, rrq->len);
-               DBG_TRACE(DbgInfo, "  reg 0x%04x ==> %d bytes\n", rrq->reg, rrq->len * sizeof (__u16));
+               DBG_TRACE(DbgInfo, "  reg 0x%04x ==> %d bytes\n", rrq->reg, rrq->len * sizeof(__u16));
                break;
          case WL_IOCTL_RTS_BATCH_WRITE:
                DBG_TRACE(DbgInfo, "IOCTL: WVLAN2_IOCTL_RTS -- WL_IOCTL_RTS_BATCH_WRITE\n");
                OUT_PORT_STRING_16(io_base + rrq->reg, rrq->data, rrq->len);
-               DBG_TRACE(DbgInfo, "  reg 0x%04x <== %d bytes\n", rrq->reg, rrq->len * sizeof (__u16));
+               DBG_TRACE(DbgInfo, "  reg 0x%04x <== %d bytes\n", rrq->reg, rrq->len * sizeof(__u16));
                break;
        default: