From patchwork Mon Apr 4 11:04:47 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chaehyun Lim X-Patchwork-Id: 8739981 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 88368C0553 for ; Mon, 4 Apr 2016 11:05:47 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 8C85420204 for ; Mon, 4 Apr 2016 11:05:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 7FC7C20270 for ; Mon, 4 Apr 2016 11:05:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754821AbcDDLFV (ORCPT ); Mon, 4 Apr 2016 07:05:21 -0400 Received: from mail-pf0-f194.google.com ([209.85.192.194]:33981 "EHLO mail-pf0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754075AbcDDLFR (ORCPT ); Mon, 4 Apr 2016 07:05:17 -0400 Received: by mail-pf0-f194.google.com with SMTP id d184so5244216pfc.1 for ; Mon, 04 Apr 2016 04:05:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=pgQ2vika1ddHedMmtrKqVBusc7e7fpthIwTjD//b2nM=; b=suqC2brR9vpeKtY5ppHiy9l9nAxh5jbJZhtdJhB6VrOGTm3RBZuugZZ/MJVlLELbY7 1npq/g/K2QWtltUGjH+ZzaGOmkm8dcmTV8eOBd/2M8OaTlHQbLcZZEVzjt8hoWhWnRPH qfEcHZ6UzxXfdJjGmmxJKpgRG8xOY8gKy7LO/sbszCAKsiyOJDIQG0mzweCUvEoLbtUb IcN2CuW91TSWl2DjIDTELj1ppPdLq53uYE1pJomxZnCJKo5UsSkXkgGVqp6Gb5Hqrmar EiNA2cko/TUm2UjmHmz3mtyjxQePpvdrryMCX6U90YOjl+m8cTJO8ui+zjmP/Y0eNZAe 9DWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=pgQ2vika1ddHedMmtrKqVBusc7e7fpthIwTjD//b2nM=; b=mntAY4zFwFp7fqS7wvXL1UYoSWgibBIeWI4nMvkvo+tH/cBSM/ZTUXzSjzkn014H8l YMdSd8hlIQ5VGq6cTJrFkBHMTPpSZWqANEgfdYD4kUXS6L1Q6PSiMocohO+kZARwsOQh 7Na2oRTETfl+OF3vlaFSt75somiIKrX5QMH7Rbon51NvsvZMOPH2gdcj5LQoVKis0ZBj Dot9V1+jXsE09k6OYnUqFpYfCEfGten8LgucvT16j2UIcfqVTaynLjLD2J0v781KBS0W YriL8xQDISOArxkAFLCYxFObtTCjnqjSKjsI6kxSWpE8c/46YsCnK/Ni8GwhPh7FB8xd qmaw== X-Gm-Message-State: AD7BkJLZZ9LYNsJeZQe3ALFkCaOrU5uT+OqkIUMBsZlWghaiqgDqcRBj2A7x5kVDuPTdmg== X-Received: by 10.98.13.130 with SMTP id 2mr19877266pfn.97.1459767916936; Mon, 04 Apr 2016 04:05:16 -0700 (PDT) Received: from localhost.localdomain ([218.233.16.2]) by smtp.gmail.com with ESMTPSA id 85sm38721469pfl.18.2016.04.04.04.05.14 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 04 Apr 2016 04:05:16 -0700 (PDT) From: Chaehyun Lim To: gregkh@linuxfoundation.org Cc: johnny.kim@atmel.com, austin.shin@atmel.com, chris.park@atmel.com, tony.cho@atmel.com, glen.lee@atmel.com, leo.kim@atmel.com, linux-wireless@vger.kernel.org, devel@driverdev.osuosl.org, Chaehyun Lim Subject: [PATCH 5/8] staging: wilc1000: rename pstrHostIFscanAttr in handle_scan Date: Mon, 4 Apr 2016 20:04:47 +0900 Message-Id: <1459767890-9709-5-git-send-email-chaehyun.lim@gmail.com> X-Mailer: git-send-email 2.8.0 In-Reply-To: <1459767890-9709-1-git-send-email-chaehyun.lim@gmail.com> References: <1459767890-9709-1-git-send-email-chaehyun.lim@gmail.com> Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Spam-Status: No, score=-7.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This patch renames pstrHostIFscanAttr to scan_info to avoid camelcase. Signed-off-by: Chaehyun Lim --- drivers/staging/wilc1000/host_interface.c | 55 +++++++++++++++---------------- 1 file changed, 27 insertions(+), 28 deletions(-) diff --git a/drivers/staging/wilc1000/host_interface.c b/drivers/staging/wilc1000/host_interface.c index 053e6f1..23080ff 100644 --- a/drivers/staging/wilc1000/host_interface.c +++ b/drivers/staging/wilc1000/host_interface.c @@ -731,8 +731,7 @@ unlock: return result; } -static s32 handle_scan(struct wilc_vif *vif, - struct scan_attr *pstrHostIFscanAttr) +static s32 handle_scan(struct wilc_vif *vif, struct scan_attr *scan_info) { s32 result = 0; struct wid strWIDList[5]; @@ -743,8 +742,8 @@ static s32 handle_scan(struct wilc_vif *vif, u8 *pu8HdnNtwrksWidVal = NULL; struct host_if_drv *hif_drv = vif->hif_drv; - hif_drv->usr_scan_req.scan_result = pstrHostIFscanAttr->result; - hif_drv->usr_scan_req.arg = pstrHostIFscanAttr->arg; + hif_drv->usr_scan_req.scan_result = scan_info->result; + hif_drv->usr_scan_req.arg = scan_info->arg; if ((hif_drv->hif_state >= HOST_IF_SCANNING) && (hif_drv->hif_state < HOST_IF_CONNECTED)) { @@ -764,19 +763,19 @@ static s32 handle_scan(struct wilc_vif *vif, strWIDList[u32WidsCount].id = (u16)WID_SSID_PROBE_REQ; strWIDList[u32WidsCount].type = WID_STR; - for (i = 0; i < pstrHostIFscanAttr->hidden_network.n_ssids; i++) - valuesize += ((pstrHostIFscanAttr->hidden_network.net_info[i].ssid_len) + 1); + for (i = 0; i < scan_info->hidden_network.n_ssids; i++) + valuesize += ((scan_info->hidden_network.net_info[i].ssid_len) + 1); pu8HdnNtwrksWidVal = kmalloc(valuesize + 1, GFP_KERNEL); strWIDList[u32WidsCount].val = pu8HdnNtwrksWidVal; if (strWIDList[u32WidsCount].val) { pu8Buffer = strWIDList[u32WidsCount].val; - *pu8Buffer++ = pstrHostIFscanAttr->hidden_network.n_ssids; + *pu8Buffer++ = scan_info->hidden_network.n_ssids; - for (i = 0; i < pstrHostIFscanAttr->hidden_network.n_ssids; i++) { - *pu8Buffer++ = pstrHostIFscanAttr->hidden_network.net_info[i].ssid_len; - memcpy(pu8Buffer, pstrHostIFscanAttr->hidden_network.net_info[i].ssid, pstrHostIFscanAttr->hidden_network.net_info[i].ssid_len); - pu8Buffer += pstrHostIFscanAttr->hidden_network.net_info[i].ssid_len; + for (i = 0; i < scan_info->hidden_network.n_ssids; i++) { + *pu8Buffer++ = scan_info->hidden_network.net_info[i].ssid_len; + memcpy(pu8Buffer, scan_info->hidden_network.net_info[i].ssid, scan_info->hidden_network.net_info[i].ssid_len); + pu8Buffer += scan_info->hidden_network.net_info[i].ssid_len; } strWIDList[u32WidsCount].size = (s32)(valuesize + 1); @@ -785,37 +784,37 @@ static s32 handle_scan(struct wilc_vif *vif, strWIDList[u32WidsCount].id = WID_INFO_ELEMENT_PROBE; strWIDList[u32WidsCount].type = WID_BIN_DATA; - strWIDList[u32WidsCount].val = pstrHostIFscanAttr->ies; - strWIDList[u32WidsCount].size = pstrHostIFscanAttr->ies_len; + strWIDList[u32WidsCount].val = scan_info->ies; + strWIDList[u32WidsCount].size = scan_info->ies_len; u32WidsCount++; strWIDList[u32WidsCount].id = WID_SCAN_TYPE; strWIDList[u32WidsCount].type = WID_CHAR; strWIDList[u32WidsCount].size = sizeof(char); - strWIDList[u32WidsCount].val = (s8 *)&pstrHostIFscanAttr->type; + strWIDList[u32WidsCount].val = (s8 *)&scan_info->type; u32WidsCount++; strWIDList[u32WidsCount].id = WID_SCAN_CHANNEL_LIST; strWIDList[u32WidsCount].type = WID_BIN_DATA; - if (pstrHostIFscanAttr->ch_freq_list && - pstrHostIFscanAttr->ch_list_len > 0) { + if (scan_info->ch_freq_list && + scan_info->ch_list_len > 0) { int i; - for (i = 0; i < pstrHostIFscanAttr->ch_list_len; i++) { - if (pstrHostIFscanAttr->ch_freq_list[i] > 0) - pstrHostIFscanAttr->ch_freq_list[i] = pstrHostIFscanAttr->ch_freq_list[i] - 1; + for (i = 0; i < scan_info->ch_list_len; i++) { + if (scan_info->ch_freq_list[i] > 0) + scan_info->ch_freq_list[i] = scan_info->ch_freq_list[i] - 1; } } - strWIDList[u32WidsCount].val = pstrHostIFscanAttr->ch_freq_list; - strWIDList[u32WidsCount].size = pstrHostIFscanAttr->ch_list_len; + strWIDList[u32WidsCount].val = scan_info->ch_freq_list; + strWIDList[u32WidsCount].size = scan_info->ch_list_len; u32WidsCount++; strWIDList[u32WidsCount].id = WID_START_SCAN_REQ; strWIDList[u32WidsCount].type = WID_CHAR; strWIDList[u32WidsCount].size = sizeof(char); - strWIDList[u32WidsCount].val = (s8 *)&pstrHostIFscanAttr->src; + strWIDList[u32WidsCount].val = (s8 *)&scan_info->src; u32WidsCount++; if (hif_drv->hif_state == HOST_IF_CONNECTED) @@ -836,13 +835,13 @@ ERRORHANDLER: Handle_ScanDone(vif, SCAN_EVENT_ABORTED); } - kfree(pstrHostIFscanAttr->ch_freq_list); - pstrHostIFscanAttr->ch_freq_list = NULL; + kfree(scan_info->ch_freq_list); + scan_info->ch_freq_list = NULL; - kfree(pstrHostIFscanAttr->ies); - pstrHostIFscanAttr->ies = NULL; - kfree(pstrHostIFscanAttr->hidden_network.net_info); - pstrHostIFscanAttr->hidden_network.net_info = NULL; + kfree(scan_info->ies); + scan_info->ies = NULL; + kfree(scan_info->hidden_network.net_info); + scan_info->hidden_network.net_info = NULL; kfree(pu8HdnNtwrksWidVal);