Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp2252685rwd; Tue, 13 Jun 2023 23:32:30 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5yPrf4zP3k0JvlVonpwMy4SQhg3PZk88lNQY9odhmBCGLjEaKFSzdyAOc1cnq0ozJ+jEpm X-Received: by 2002:a05:6358:9db0:b0:129:be5b:fff with SMTP id d48-20020a0563589db000b00129be5b0fffmr8244151rwo.9.1686724350337; Tue, 13 Jun 2023 23:32:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686724350; cv=none; d=google.com; s=arc-20160816; b=LEC3rTfdvF02/Htt1G8+D71KCCqIRSqV/lHfiwO0GMvHdyPWChVQjfyDkKCpZbLqJ6 MdNbR/B2/Byj+F7D+Y86Eesd4lqKv2q4tWPcQ/mVmSL7m26TZHGsUpgg7fZxWzqiv2sG MyWuvemMklPkQ2KFnzDhmDtW9xhCv3HOaWZqXDuF9BkDCiHicjo1+ArxdDpdMmc5ysqP llAJ6Efr/B+lBWMx4GlR93ysKUZGFu1cNVmaMvcNKRzJuOAPJZzl9E7SphdFwBE7Rx16 Zc2a78qZwKaetpHiWltlHI/4z6j8cCa9KRwVLcnEr6DMWbKmrAJ70FwhZ28flLgpqFBp tryQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:message-id:user-agent :references:in-reply-to:subject:cc:to:from:date:mime-version :dkim-signature; bh=LsRX6ZXhErv+qCY6K93bir94OwPhwSnBXBd8FACMN9g=; b=mS7BWo39GCzoel4Bn8ITT9fE0+PFl22j/iI33Z+GJY9AjwhLWDBxvj0b1baMHlxr9B zLQ1VUfKzFpqIpBkeSqYxQY8y/Cn0QBmCOLH00AG8812VCKZxeZVTGT9jEalglKRJmC4 VMX6EnDmp+GdoSM2I6m439WWyfyN5lu7NCoTfYw2IcbZeA5su5rAreNKBNpbIBPstJuP 98yzf7OrLj8aPvD+Y+oI0PS3PcsEAi30jdTT8cdmHP2cGSOtjP7uO0KbGq0wBlrElVT7 ILubFTKEKZNNMhhRZM98AS12vZ9aI0q9gnF0e5v4kLYqnJ3nuBgA6NXWwrYygBcZivJi lSLw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (bad version) header.i=@208.org header.s=dkim header.b=OEMPUrdH; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-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 z16-20020a634c10000000b005348202cac1si9166947pga.5.2023.06.13.23.32.21; Tue, 13 Jun 2023 23:32:30 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-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=neutral (bad version) header.i=@208.org header.s=dkim header.b=OEMPUrdH; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242677AbjFNG2d (ORCPT + 62 others); Wed, 14 Jun 2023 02:28:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42746 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234691AbjFNG2c (ORCPT ); Wed, 14 Jun 2023 02:28:32 -0400 Received: from mail.208.org (unknown [183.242.55.162]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B2B92199 for ; Tue, 13 Jun 2023 23:28:30 -0700 (PDT) Received: from mail.208.org (email.208.org [127.0.0.1]) by mail.208.org (Postfix) with ESMTP id 4QgwV41cNtzBQgpD for ; Wed, 14 Jun 2023 14:28:28 +0800 (CST) Authentication-Results: mail.208.org (amavisd-new); dkim=pass reason="pass (just generated, assumed good)" header.d=208.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=208.org; h= content-transfer-encoding:content-type:message-id:user-agent :references:in-reply-to:subject:to:from:date:mime-version; s= dkim; t=1686724108; x=1689316109; bh=uzV5IRMvn+xjooRI4ST/VUkNmJE 0mM4D/yBYv59E2J4=; b=OEMPUrdH+ElMTwD2vHZWY4u1D16Vyz9lew1NmE97VQT BPrKK3SeywTLBuWEFUijFPcs/5tFhE8gck3rt/3FbWXIXQ/inKkb8IdcaDDhTBJZ UVl5iTacfGd7dMGPjtRm5avZWcMIhUOa3k7VO9Y9ibjhn7irMo1sbShaQZS63Ii6 vTWQ1TI5dPaua4b3JA/p4rHUDyPVzMFekEqu4t9thOtNrlii9i2xbNVf1B9Osl4y AkWdQLxH3lRXkbLYpciy+EEFp28oNYkYLuq8TSO0sIYGq5OkULtJH35F4dJkMSGe G6zkgkRxf5aWuIlCWyWF7FpsBEkTVU9sltgtlipk8FQ== X-Virus-Scanned: amavisd-new at mail.208.org Received: from mail.208.org ([127.0.0.1]) by mail.208.org (mail.208.org [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id I5-MmUHcWlR0 for ; Wed, 14 Jun 2023 14:28:28 +0800 (CST) Received: from localhost (email.208.org [127.0.0.1]) by mail.208.org (Postfix) with ESMTPSA id 4QgwV36l4GzBQgpC; Wed, 14 Jun 2023 14:28:27 +0800 (CST) MIME-Version: 1.0 Date: Wed, 14 Jun 2023 14:28:27 +0800 From: xuanzhenggang001@208suo.com To: pkshih@realtek.com, kvalo@kernel.org Cc: linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] wifi: rtw89: Remove unneeded variable In-Reply-To: References: <20230610131734.21134-1-denghuilong@cdjrlc.com> User-Agent: Roundcube Webmail Message-ID: X-Sender: xuanzhenggang001@208suo.com Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-0.9 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,RDNS_NONE,SPF_HELO_FAIL,SPF_PASS,T_SCC_BODY_TEXT_LINE, URIBL_BLOCKED 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-wireless@vger.kernel.org Fix the following coccicheck warning: drivers/net/wireless/realtek/rtw89/pci.c:239:5-8: Unneeded variable: "cnt". Signed-off-by: Zhenggang Xuan --- drivers/net/wireless/realtek/rtw89/pci.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/net/wireless/realtek/rtw89/pci.c b/drivers/net/wireless/realtek/rtw89/pci.c index 9402f1a0caea..591b7b9a6eca 100644 --- a/drivers/net/wireless/realtek/rtw89/pci.c +++ b/drivers/net/wireless/realtek/rtw89/pci.c @@ -236,7 +236,6 @@ static u32 rtw89_pci_rxbd_deliver_skbs(struct rtw89_dev *rtwdev, struct sk_buff *skb; u32 rxinfo_size = sizeof(struct rtw89_pci_rxbd_info); u32 offset; - u32 cnt = 1; bool fs, ls; int ret; @@ -297,7 +296,7 @@ static u32 rtw89_pci_rxbd_deliver_skbs(struct rtw89_dev *rtwdev, desc_info->ready = false; } - return cnt; + return 1; err_sync_device: rtw89_pci_sync_skb_for_device(rtwdev, skb); @@ -308,7 +307,7 @@ static u32 rtw89_pci_rxbd_deliver_skbs(struct rtw89_dev *rtwdev, rx_ring->diliver_skb = NULL; desc_info->ready = false; - return cnt; + return 1; } static void rtw89_pci_rxbd_deliver(struct rtw89_dev *rtwdev,