From patchwork Tue Feb 20 14:57:52 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ajay Singh X-Patchwork-Id: 10230187 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 5AA44602B1 for ; Tue, 20 Feb 2018 14:58:22 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4A200205F6 for ; Tue, 20 Feb 2018 14:58:22 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3EB562833E; Tue, 20 Feb 2018 14:58:22 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BB753205F6 for ; Tue, 20 Feb 2018 14:58:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752160AbeBTO6U (ORCPT ); Tue, 20 Feb 2018 09:58:20 -0500 Received: from esa5.microchip.iphmx.com ([216.71.150.166]:3080 "EHLO esa5.microchip.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751763AbeBTO6T (ORCPT ); Tue, 20 Feb 2018 09:58:19 -0500 X-IronPort-AV: E=Sophos;i="5.46,539,1511852400"; d="scan'208";a="9401451" Received: from exsmtp03.microchip.com (HELO email.microchip.com) ([198.175.253.49]) by esa5.microchip.iphmx.com with ESMTP/TLS/DHE-RSA-AES256-SHA; 20 Feb 2018 07:58:20 -0700 Received: from ajaysk-VirtualBox.mchp-main.com (10.10.76.4) by chn-sv-exch03.mchp-main.com (10.10.76.49) with Microsoft SMTP Server id 14.3.352.0; Tue, 20 Feb 2018 07:58:18 -0700 From: Ajay Singh To: CC: , , , , , , , Ajay Singh Subject: [PATCH 03/12] staging: wilc1000: rename variables using camelCase in handle_rcvd_ntwrk_info() Date: Tue, 20 Feb 2018 20:27:52 +0530 Message-ID: <1519138681-1982-4-git-send-email-ajay.kathat@microchip.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1519138681-1982-1-git-send-email-ajay.kathat@microchip.com> References: <1519138681-1982-1-git-send-email-ajay.kathat@microchip.com> MIME-Version: 1.0 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Fix "Avoid camelCase" issue found by checkpatch.pl script. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/host_interface.c | 45 +++++++++++++++---------------- 1 file changed, 22 insertions(+), 23 deletions(-) diff --git a/drivers/staging/wilc1000/host_interface.c b/drivers/staging/wilc1000/host_interface.c index 0f1eb17..f79618a 100644 --- a/drivers/staging/wilc1000/host_interface.c +++ b/drivers/staging/wilc1000/host_interface.c @@ -1248,18 +1248,17 @@ static s32 handle_rcvd_ntwrk_info(struct wilc_vif *vif, struct rcvd_net_info *rcvd_info) { u32 i; - bool bNewNtwrkFound; + bool found; s32 result = 0; - struct network_info *pstrNetworkInfo = NULL; - void *pJoinParams = NULL; + struct network_info *info = NULL; + void *params = NULL; struct host_if_drv *hif_drv = vif->hif_drv; - bNewNtwrkFound = true; + found = true; if (hif_drv->usr_scan_req.scan_result) { - wilc_parse_network_info(rcvd_info->buffer, &pstrNetworkInfo); - if (!pstrNetworkInfo || - !hif_drv->usr_scan_req.scan_result) { + wilc_parse_network_info(rcvd_info->buffer, &info); + if (!info || !hif_drv->usr_scan_req.scan_result) { netdev_err(vif->ndev, "driver is null\n"); result = -EINVAL; goto done; @@ -1267,36 +1266,36 @@ static s32 handle_rcvd_ntwrk_info(struct wilc_vif *vif, for (i = 0; i < hif_drv->usr_scan_req.rcvd_ch_cnt; i++) { if (memcmp(hif_drv->usr_scan_req.net_info[i].bssid, - pstrNetworkInfo->bssid, 6) == 0) { - if (pstrNetworkInfo->rssi <= hif_drv->usr_scan_req.net_info[i].rssi) { + info->bssid, 6) == 0) { + if (info->rssi <= hif_drv->usr_scan_req.net_info[i].rssi) { goto done; } else { - hif_drv->usr_scan_req.net_info[i].rssi = pstrNetworkInfo->rssi; - bNewNtwrkFound = false; + hif_drv->usr_scan_req.net_info[i].rssi = info->rssi; + found = false; break; } } } - if (bNewNtwrkFound) { + if (found) { if (hif_drv->usr_scan_req.rcvd_ch_cnt < MAX_NUM_SCANNED_NETWORKS) { - hif_drv->usr_scan_req.net_info[hif_drv->usr_scan_req.rcvd_ch_cnt].rssi = pstrNetworkInfo->rssi; + hif_drv->usr_scan_req.net_info[hif_drv->usr_scan_req.rcvd_ch_cnt].rssi = info->rssi; memcpy(hif_drv->usr_scan_req.net_info[hif_drv->usr_scan_req.rcvd_ch_cnt].bssid, - pstrNetworkInfo->bssid, 6); + info->bssid, 6); hif_drv->usr_scan_req.rcvd_ch_cnt++; - pstrNetworkInfo->new_network = true; - pJoinParams = host_int_parse_join_bss_param(pstrNetworkInfo); + info->new_network = true; + params = host_int_parse_join_bss_param(info); - hif_drv->usr_scan_req.scan_result(SCAN_EVENT_NETWORK_FOUND, pstrNetworkInfo, + hif_drv->usr_scan_req.scan_result(SCAN_EVENT_NETWORK_FOUND, info, hif_drv->usr_scan_req.arg, - pJoinParams); + params); } } else { - pstrNetworkInfo->new_network = false; - hif_drv->usr_scan_req.scan_result(SCAN_EVENT_NETWORK_FOUND, pstrNetworkInfo, + info->new_network = false; + hif_drv->usr_scan_req.scan_result(SCAN_EVENT_NETWORK_FOUND, info, hif_drv->usr_scan_req.arg, NULL); } } @@ -1305,9 +1304,9 @@ static s32 handle_rcvd_ntwrk_info(struct wilc_vif *vif, kfree(rcvd_info->buffer); rcvd_info->buffer = NULL; - if (pstrNetworkInfo) { - kfree(pstrNetworkInfo->ies); - kfree(pstrNetworkInfo); + if (info) { + kfree(info->ies); + kfree(info); } return result;