Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp12476210rwb; Sat, 26 Nov 2022 09:36:16 -0800 (PST) X-Google-Smtp-Source: AA0mqf7EeHfAZeBTidvC//Tmtj/XkEqIQ94cFs6B1Grwj4x0hizNlNWSLz1dMs5GGyTbbHCs8lV6 X-Received: by 2002:a17:906:c303:b0:7ad:95d2:9df2 with SMTP id s3-20020a170906c30300b007ad95d29df2mr36244735ejz.607.1669484176039; Sat, 26 Nov 2022 09:36:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669484176; cv=none; d=google.com; s=arc-20160816; b=VUMUpNtdQ9MFsAvi5L7qWFhtoVmZzIajqRWD7HIcjzftsGk1zNw1o4E8zaAOYkF970 0khI5yXYa6mmSFHhZ3rsage3y7g+ODJ6dYFa0AdaXfL82rvWL41h+5lFQpBD5MBIsGMo 6xLC3Xost62CI0NTDcog5EWtEZJSlpzGYnNgguRkxBFd8SyRmoiurrV8m9XmLkBfmJES Px9n/mxTyPXFvDq2AYyKSPbX1LigG6078WFbdt1fn/hX9QBtiJSn6+t50ANScWvdibI0 kb5LYAD86p5QR36pK8K6bOdJ9tRsZiBM7Vk35y8ky8A9IMtlH7pKCaLEHVi6uT4dw9+B Peiw== 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; bh=kEJ/Eto1jkEe3z/2uFBgrwi3wSk7Uh+sVn1GH7LWE/4=; b=sR+DJ+8DVX3lJnzHrGB+7SCcFRhQJHOVSosvlTy2mozK6NC9ceBYYbyjZiFy/6u3LA jRC8lWviRaXIckQ0fM9tcmUSwrPh1n2pUN/B9QG5ZyNRijbsWorRRzcZtpxvQiWnerAd riPSB7LpBdX4E7i6mlkNJtqtG3n46b/NSdX+RTBx6zQAfDQlryg3m6h0pcONhQ/R232z 08m3kQgcAm13hFPKa9qOcDzR/oibvuHnvQmnj/gmbm0Qtr9Goav63079aVZn7d+ltmsb i9JCiVKddTWyoZ35l3vAsLLi3QHM0DJ01jSbembupwBA7DIaEKzzpN4Ic5BhtGHVeoZ0 Rzzw== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id gb15-20020a170907960f00b00792e39c31dcsi6343965ejc.988.2022.11.26.09.35.55; Sat, 26 Nov 2022 09:36:16 -0800 (PST) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229763AbiKZQCP (ORCPT + 84 others); Sat, 26 Nov 2022 11:02:15 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52338 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229661AbiKZQBs (ORCPT ); Sat, 26 Nov 2022 11:01:48 -0500 Received: from viti.kaiser.cx (viti.kaiser.cx [IPv6:2a01:238:43fe:e600:cd0c:bd4a:7a3:8e9f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B81D5193FB for ; Sat, 26 Nov 2022 08:01:47 -0800 (PST) Received: from dslb-188-096-151-149.188.096.pools.vodafone-ip.de ([188.96.151.149] helo=martin-debian-2.paytec.ch) by viti.kaiser.cx with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.89) (envelope-from ) id 1oyxcb-0000Ub-K2; Sat, 26 Nov 2022 17:01:41 +0100 From: Martin Kaiser To: Greg Kroah-Hartman Cc: Larry Finger , Phillip Potter , Michael Straube , Pavel Skripkin , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, Martin Kaiser Subject: [PATCH 10/10] staging: r8188eu: remove a variable Date: Sat, 26 Nov 2022 17:01:29 +0100 Message-Id: <20221126160129.178697-11-martin@kaiser.cx> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20221126160129.178697-1-martin@kaiser.cx> References: <20221126160129.178697-1-martin@kaiser.cx> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_NONE autolearn=ham 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 Check the result of rtw_check_bcn_info directly and remove the ret variable. Signed-off-by: Martin Kaiser --- drivers/staging/r8188eu/core/rtw_mlme_ext.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/staging/r8188eu/core/rtw_mlme_ext.c b/drivers/staging/r8188eu/core/rtw_mlme_ext.c index 362313c49c52..d32b2d569e23 100644 --- a/drivers/staging/r8188eu/core/rtw_mlme_ext.c +++ b/drivers/staging/r8188eu/core/rtw_mlme_ext.c @@ -555,7 +555,6 @@ static void OnBeacon(struct adapter *padapter, struct recv_frame *precv_frame) u8 *pframe = precv_frame->rx_data; uint len = precv_frame->len; struct wlan_bssid_ex *pbss; - int ret = _SUCCESS; u8 *ie_ptr; u32 ie_len; @@ -600,8 +599,7 @@ static void OnBeacon(struct adapter *padapter, struct recv_frame *precv_frame) if (!psta) return; - ret = rtw_check_bcn_info(padapter, pframe, len); - if (!ret) { + if (rtw_check_bcn_info(padapter, pframe, len) != _SUCCESS) { receive_disconnect(padapter, pmlmeinfo->network.MacAddress, 0); return; } -- 2.30.2