Received: by 2002:a05:6a10:87d6:0:0:0:0 with SMTP id g22csp662740pxr; Mon, 11 Apr 2022 04:06:57 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxTa8fXlyxosx+Q3MuGYFJaOmU+qS1MNJ5CQVmWMe/FFo8t3mUAYoGw3RmgAMYQUeCpNyRn X-Received: by 2002:a17:902:8490:b0:156:9846:240 with SMTP id c16-20020a170902849000b0015698460240mr31256027plo.141.1649675217403; Mon, 11 Apr 2022 04:06:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649675217; cv=none; d=google.com; s=arc-20160816; b=AFbdOVS2590oVLN4w/LTs9B4v98+oSslE4exoMXPiuKGAaK+YAPz1c+RFgaDyXKiEf SgrkFIWkB3hNgtInv0njOs1DKj+t4koAoiXhbVKyqsGnT1S9a3o1wAc+2+ghOwU5VKHD MIt/yAfBQfR1e5SVMVEdo1rAUrZRX70vedODk9UnRSn9PWuMFzAtEOc9GU7wmuwbqbdn QWgT6a4mEC0rAW6px/QwmIwQa9NKLq1dqUVQ6FRy0BxglIjeWxAQv9nC8q8FToQkQmCX XIYQqtMTihctHPPPc51A0RqnOPpTN7rd+u56rvMRm8ctnMkz782QW0USSnFivC8+i1sS uXNQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=QN6xP3dvTt8eDyyxi0GOR7k7xaEfRxM7p59jD419ae4=; b=JW6JxlwN07LFTLu5jGMek/HIRIVUWXjpwBnGnLIkiQUnOfKMPtEofNg9gxHCcNGr6X wH27KCzDX12V4XUBfLC8dB09mzT8pO+d6QGojLTRftbd6UWr1bCJZ5m8nXvwyVRulmG+ qkqZr/OetBH8BnnMFehvTs9DtqJOq9Ae5aZA6kH7GKFpAwMcruyVt6lofTaIljL4plDh cfjU5cmzHDx4EFi+DaNWlPUykgzEWxlCGCXdRsrXUdtmuUo6JyjAz3AoI39NlBTdPykQ iWkW4pGm8eCUC8rze06fi3UOSRUatrbsuZCctXW8KCVp4QPgxF31oq+Z0+BeIUMGoSq6 RqfA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=h9NPejbZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id t17-20020a170902e85100b00153b2d164cdsi9357932plg.213.2022.04.11.04.06.43; Mon, 11 Apr 2022 04:06:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=h9NPejbZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243632AbiDJQeY (ORCPT + 99 others); Sun, 10 Apr 2022 12:34:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46302 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243614AbiDJQeR (ORCPT ); Sun, 10 Apr 2022 12:34:17 -0400 Received: from mail-pg1-x535.google.com (mail-pg1-x535.google.com [IPv6:2607:f8b0:4864:20::535]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7A14515835 for ; Sun, 10 Apr 2022 09:32:06 -0700 (PDT) Received: by mail-pg1-x535.google.com with SMTP id r66so12127259pgr.3 for ; Sun, 10 Apr 2022 09:32:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=QN6xP3dvTt8eDyyxi0GOR7k7xaEfRxM7p59jD419ae4=; b=h9NPejbZZiVsyzDuJB41AHo0EZuxX1138V+yJNlXFfy50OodXO0hQP+E/YgUDwPv/e NBEaq+RvL7ZBwasX+sSSXA+IGct0dw4A4fI43uBRInPJYk58MJrWy5wGyJ3LvNfzFmQB fqDI1DDoidIKsZo9P6Wokl0ThG07WfVGrMSP7J7ONujW05Bz38wWC49tOUkaJXHRfFhF UVZ6+EroYgo6rntyOfW90xgj7684lZBWUsrutg9yBLiYIp1TmDYtwSa4nMeLF51flP7T TMk1XFhyxpFT330mI5ZuCedwWlEkfZjMfylRsBqcH9rIOP4LjrINcYZkonlx2tXcl/5l KS5A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=QN6xP3dvTt8eDyyxi0GOR7k7xaEfRxM7p59jD419ae4=; b=mBUVoEMSZJ/PBFFhq4ritcDS9IK5v7wDwpuX4ApRYSbM+MFOrcUdyUrh9lqqXCxxxC 5rm0Wg8DrVAKkoBX3DkT1SPh91J9huxyzDZ8OceNYQTpY7tPPPKu5mw9mfOfYRgtaX6s 0MR/VK4l0eCZl3vasx7Oh9/eQL/VjHV6PSJr2f+9zBRdgloGtFb1eIEBVqph79aY8tmc V5B0f6NT/6j6BRyP6m1deoFMJt0rPpN/6GQAnM+iL4D3yFXnc2wvyKiBqZP/1INuhAnX e37QwcS6Zu39iT1IFHDwBY82Qtlu4+5s/R/OfRYLrKsDd3wyB9L1uQ7fAjIuyCk58xBS qhIg== X-Gm-Message-State: AOAM530WFsSolGmz36fsuLe2B/gW3dpcsVfH93bXwJHYU8iZTwHAZ0GM 503uC476yhojDO5Yc/dUgAI= X-Received: by 2002:a65:6951:0:b0:381:f10:ccaa with SMTP id w17-20020a656951000000b003810f10ccaamr22824522pgq.587.1649608325970; Sun, 10 Apr 2022 09:32:05 -0700 (PDT) Received: from makvihas.localhost.com ([2405:201:202b:15:606b:10e4:2085:6825]) by smtp.gmail.com with ESMTPSA id f12-20020a056a001acc00b004fb37ecc6b2sm31940021pfv.29.2022.04.10.09.32.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 10 Apr 2022 09:32:05 -0700 (PDT) From: Vihas Makwana To: Larry Finger , Phillip Potter , Greg Kroah-Hartman , Michael Straube Cc: linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, Dan Carpenter , Pavel Skripkin , Vihas Makwana Subject: [PATCH 5/6] staging: r8188eu: drop unnecessary wrapper rtw_init_mlme_priv Date: Sun, 10 Apr 2022 22:01:16 +0530 Message-Id: <20220410163117.3964-6-makvihas@gmail.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220410163117.3964-1-makvihas@gmail.com> References: <20220410163117.3964-1-makvihas@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, NO_RDNS_DOTCOM_HELO,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Remove the unnecessary wrapper. The logic of rtw_init_mlme_priv can be moved to _rtw_init_mlme_priv. Signed-off-by: Vihas Makwana --- drivers/staging/r8188eu/core/rtw_mlme.c | 11 +---------- drivers/staging/r8188eu/include/rtw_mlme.h | 2 +- drivers/staging/r8188eu/os_dep/os_intfs.c | 2 +- 3 files changed, 3 insertions(+), 12 deletions(-) diff --git a/drivers/staging/r8188eu/core/rtw_mlme.c b/drivers/staging/r8188eu/core/rtw_mlme.c index c90f36dee..f2a61c162 100644 --- a/drivers/staging/r8188eu/core/rtw_mlme.c +++ b/drivers/staging/r8188eu/core/rtw_mlme.c @@ -30,7 +30,7 @@ u8 rtw_to_roaming(struct adapter *adapter) return adapter->mlmepriv.to_roaming; } -static int _rtw_init_mlme_priv(struct adapter *padapter) +int _rtw_init_mlme_priv(struct adapter *padapter) { int i; u8 *pbuf; @@ -288,15 +288,6 @@ u8 *rtw_get_beacon_interval_from_ie(u8 *ie) return ie + 8; } -int rtw_init_mlme_priv(struct adapter *padapter)/* struct mlme_priv *pmlmepriv) */ -{ - int res; - - res = _rtw_init_mlme_priv(padapter);/* (pmlmepriv); */ - - return res; -} - void rtw_free_mlme_priv(struct mlme_priv *pmlmepriv) { _rtw_free_mlme_priv(pmlmepriv); diff --git a/drivers/staging/r8188eu/include/rtw_mlme.h b/drivers/staging/r8188eu/include/rtw_mlme.h index 1dc1fbf04..b5b1a0e10 100644 --- a/drivers/staging/r8188eu/include/rtw_mlme.h +++ b/drivers/staging/r8188eu/include/rtw_mlme.h @@ -438,7 +438,7 @@ int event_thread(void *context); void rtw_join_timeout_handler (struct timer_list *t); void _rtw_scan_timeout_handler (struct timer_list *t); void rtw_free_network_queue(struct adapter *adapter, u8 isfreeall); -int rtw_init_mlme_priv(struct adapter *adapter); +int _rtw_init_mlme_priv(struct adapter *adapter); void rtw_free_mlme_priv (struct mlme_priv *pmlmepriv); int rtw_select_and_join_from_scanned_queue(struct mlme_priv *pmlmepriv); int rtw_set_key(struct adapter *adapter, struct security_priv *psecuritypriv, diff --git a/drivers/staging/r8188eu/os_dep/os_intfs.c b/drivers/staging/r8188eu/os_dep/os_intfs.c index f041c3d87..448ea9533 100644 --- a/drivers/staging/r8188eu/os_dep/os_intfs.c +++ b/drivers/staging/r8188eu/os_dep/os_intfs.c @@ -478,7 +478,7 @@ u8 rtw_init_drv_sw(struct adapter *padapter) goto free_cmd_priv; } - if (rtw_init_mlme_priv(padapter) == _FAIL) { + if (_rtw_init_mlme_priv(padapter) == _FAIL) { dev_err(dvobj_to_dev(padapter->dvobj), "rtw_init_mlme_priv failed\n"); goto free_evt_priv; } -- 2.30.2