From patchwork Mon Mar 28 04:55:57 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chaehyun Lim X-Patchwork-Id: 8677901 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 963C49F44D for ; Mon, 28 Mar 2016 04:56:16 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id BD1BB2024C for ; Mon, 28 Mar 2016 04:56:15 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id CFF8620253 for ; Mon, 28 Mar 2016 04:56:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753309AbcC1E4N (ORCPT ); Mon, 28 Mar 2016 00:56:13 -0400 Received: from mail-pf0-f193.google.com ([209.85.192.193]:34934 "EHLO mail-pf0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751643AbcC1E4M (ORCPT ); Mon, 28 Mar 2016 00:56:12 -0400 Received: by mail-pf0-f193.google.com with SMTP id u190so19204933pfb.2 for ; Sun, 27 Mar 2016 21:56:12 -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=5+EUK+PC8fdfvPEpROJGu09rLpo07Td6vzp/vmT+7vw=; b=khp/dvXLK36tkPNHT9Fxon5tqcYWgCE4Krc8RcTdhppB2gGaWTA4vTjUZi3HSOG6Ln HfQzK26od5bxwLowVAd4LWr9OM7O58r08ENlSDXzEWPzMmeWMYV5fVefZJpNWew2JI2I 5DU88VIJZeWNIyMDIHQp7UOypA+kpdZV7y65XkB+nWzSjnvWfECnsb6XS6zwao19D+gK DbYImdDqxltlEjlkLAfZBDy0A3or+lU7m7dcBoxXuL3aJd6kUUiNCMDkAiXFgICZcoe/ JKoVVaSeVkaBCaq5KCDOdXSsRVeT/LrXg7A0+KH69WMzhpZyck9fHl1QhLAWeabXRzyK IyFA== 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=5+EUK+PC8fdfvPEpROJGu09rLpo07Td6vzp/vmT+7vw=; b=Iv3AwOTRhDVMuzHu6LlX0Dw7QfMTyo10EoUuiBVpGzIsyId36TRe2AMvUhbSBoJwlY iowl9YJ7uIiZoqV/pQQzUoFo81XhNqE46wGBerEYahImZj6Klu1KUa1yQCWWriGe7h1d IsqMSLAtz5YzRKTcuEmzHF/vpBOAPZWKGQAknsvFyDkP0vXg3NODJbrItqWr963ck1LV yjaIWprcMpfZRo+K0lKo3M1epfF1q4HrFr6avF/IrIkVU341gQcEwHeAkamfTjoTkzMc jcI0CUNabxmPFxMzn2PZ2vx3yJYhZzuNXyy/3u9kH1ylZKaQpgGVeNzpb2l4FiHV+TY1 ewBw== X-Gm-Message-State: AD7BkJKpC39O74ZHHf8v00YiIfydF6hXIZzQorYiRfA55VrpsftwMQyRRMyqdEZPBAA4tA== X-Received: by 10.98.73.221 with SMTP id r90mr39664283pfi.70.1459140972010; Sun, 27 Mar 2016 21:56:12 -0700 (PDT) Received: from localhost.localdomain ([218.233.16.2]) by smtp.gmail.com with ESMTPSA id t78sm13518897pfi.55.2016.03.27.21.56.09 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 27 Mar 2016 21:56:11 -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 2/5] staging: wilc1000: change data type of wid argument in wilc_wlan_cfg_get Date: Mon, 28 Mar 2016 13:55:57 +0900 Message-Id: <1459140960-10645-2-git-send-email-chaehyun.lim@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1459140960-10645-1-git-send-email-chaehyun.lim@gmail.com> References: <1459140960-10645-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 changes data type of wid argument in wilc_wlan_cfg_get from u32 to u16. It is better to change data type of wid because wid has one of enum WID_T that is data type of u16. And, there is no need to use u16 type casting when calling wilc_wlan_cfg_get_wid function. Signed-off-by: Chaehyun Lim --- drivers/staging/wilc1000/wilc_wlan.c | 5 ++--- drivers/staging/wilc1000/wilc_wlan.h | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/staging/wilc1000/wilc_wlan.c b/drivers/staging/wilc1000/wilc_wlan.c index d09aa3b..db79ae2 100644 --- a/drivers/staging/wilc1000/wilc_wlan.c +++ b/drivers/staging/wilc1000/wilc_wlan.c @@ -1239,7 +1239,7 @@ int wilc_wlan_cfg_set(struct wilc_vif *vif, int start, u16 wid, u8 *buffer, return ret_size; } -int wilc_wlan_cfg_get(struct wilc_vif *vif, int start, u32 wid, int commit, +int wilc_wlan_cfg_get(struct wilc_vif *vif, int start, u16 wid, int commit, u32 drv_handler) { u32 offset; @@ -1253,8 +1253,7 @@ int wilc_wlan_cfg_get(struct wilc_vif *vif, int start, u32 wid, int commit, wilc->cfg_frame_offset = 0; offset = wilc->cfg_frame_offset; - ret_size = wilc_wlan_cfg_get_wid(wilc->cfg_frame.frame, offset, - (u16)wid); + ret_size = wilc_wlan_cfg_get_wid(wilc->cfg_frame.frame, offset, wid); offset += ret_size; wilc->cfg_frame_offset = offset; diff --git a/drivers/staging/wilc1000/wilc_wlan.h b/drivers/staging/wilc1000/wilc_wlan.h index ef70642..38edeeb 100644 --- a/drivers/staging/wilc1000/wilc_wlan.h +++ b/drivers/staging/wilc1000/wilc_wlan.h @@ -286,7 +286,7 @@ void wilc_handle_isr(struct wilc *wilc); void wilc_wlan_cleanup(struct net_device *dev); int wilc_wlan_cfg_set(struct wilc_vif *vif, int start, u16 wid, u8 *buffer, u32 buffer_size, int commit, u32 drv_handler); -int wilc_wlan_cfg_get(struct wilc_vif *vif, int start, u32 wid, int commit, +int wilc_wlan_cfg_get(struct wilc_vif *vif, int start, u16 wid, int commit, u32 drv_handler); int wilc_wlan_cfg_get_val(u32 wid, u8 *buffer, u32 buffer_size); int wilc_wlan_txq_add_mgmt_pkt(struct net_device *dev, void *priv, u8 *buffer,