From patchwork Sun Dec 10 15:26:38 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Philipp Hortmann X-Patchwork-Id: 176359 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:bcd1:0:b0:403:3b70:6f57 with SMTP id r17csp6570415vqy; Sun, 10 Dec 2023 07:27:46 -0800 (PST) X-Google-Smtp-Source: AGHT+IGqNwisbW0VHyU2xUCC+OEm/t1hWyReRYgAiRx9CNr3mNLzIPSlH2lLG8P8eqwkv4JZOe+4 X-Received: by 2002:a17:902:7e8f:b0:1d1:cd7f:5424 with SMTP id z15-20020a1709027e8f00b001d1cd7f5424mr3163751pla.19.1702222065785; Sun, 10 Dec 2023 07:27:45 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702222065; cv=none; d=google.com; s=arc-20160816; b=0bE19xR6uJVb3wkQAD1ir2nAf0m2xcKUZ6sAYBf2/DQg1Zc28mhLqhE4SpGKbJKO/b p0Tr7m5FZKOBy9R4/7EIHBUXspWnv1qTu4ng7nPeV2qA5bGKAHQkLtIEeNU52HJJ4GBD XvB1FfhjTrDK2LOITVupAC9H27TIeBIhJBO+JThfGjPNJp/K+VJrPhVkCpOVULL3tZlM BGSYF53/eZs+z9tteEc5chOsOlsYDmXvjWIlErBQ+OZ2l1P5Xkad0odaOl5LeyAqFAQQ hmzRC12RZdH5x64ymXCnbB7Ybd0+/BQWG9HkTtTg4bgPQ91GunTN5HKtRdv3c9jPCly4 JiWg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:to:from:date:dkim-signature; bh=x27vCUpD2eYMWgYKl63p6rruFTypQyGCnQHgn4PVIcE=; fh=Sw1rtAM+hKyOoOQVYiiLzcdjc4spg79Z/tN6UmWUAKs=; b=KX6BGT/K5q0tBhCsujED6T2B+ugtJS3d6i36bjL7HNVbiplpTqfiZlXeC+ZGttCegz 6ALDG4DorqS3dB3WwBJ432AmAPxLeMP5cx9tdCOoO/oiTjptXVvLJaxx5biKhiowN4C8 CM0i0ia2lzMTRM0xEnCDpi63EuaezKe9wrUfFnV3Hx+8MZl5NQ8iVXf/NlZGni0o3D2J T8vIjnxaOl4MRUpG0QUNGfsdjfsQLJweYj2UHikrOxLDmO+9Cyt0VmKRpCMSazDn297h WRL/MGNlkRG1PG55fyhqQljrIK1UZWaMzmSd97MQG4uArvGRY1WoCY30OIjDcInI917Q FF9A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=eO7wJzrP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from groat.vger.email (groat.vger.email. [2620:137:e000::3:5]) by mx.google.com with ESMTPS id r2-20020a170902be0200b001d0cbef2eeesi4697783pls.71.2023.12.10.07.27.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 10 Dec 2023 07:27:45 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) client-ip=2620:137:e000::3:5; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=eO7wJzrP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id A4C06807C55B; Sun, 10 Dec 2023 07:27:07 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232986AbjLJP0x (ORCPT + 99 others); Sun, 10 Dec 2023 10:26:53 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58550 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233038AbjLJP0i (ORCPT ); Sun, 10 Dec 2023 10:26:38 -0500 Received: from mail-wm1-x32e.google.com (mail-wm1-x32e.google.com [IPv6:2a00:1450:4864:20::32e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 98E6C106 for ; Sun, 10 Dec 2023 07:26:41 -0800 (PST) Received: by mail-wm1-x32e.google.com with SMTP id 5b1f17b1804b1-40c2d50c0adso6103485e9.1 for ; Sun, 10 Dec 2023 07:26:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1702222000; x=1702826800; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=x27vCUpD2eYMWgYKl63p6rruFTypQyGCnQHgn4PVIcE=; b=eO7wJzrPDX0s6bLCjO0+wCr0LEqwKFUoqohd6qD3mcaB3jinTLWbGPoiDVIc5X2TNw XUn7ugqqP75Yv4C2euChXFB///cr6SnPJWp12vd35z2joZ3y+U8wvFiLF+kDVgJfLDhk PlWZipQQyQn203ORovJ7hr1VPBonKIwbjj+tGNjshbldW45VQ0EzWd7jE/40Gow/SJDm qUpEOjyO0s8wj/vzc/Zpz6HcZ9GKHrvkyPeoopySW+0yppDtS/E1E2TwWeK0eaFMmhJ7 lfLgosEnkMTDOSg09TObXNHtAvwC6+7tSSnaL57zS7+w4jD16P90zrqyuGPVTLbrBAfw WwOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702222000; x=1702826800; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=x27vCUpD2eYMWgYKl63p6rruFTypQyGCnQHgn4PVIcE=; b=Rsk9PXtQHL9LkDTS6XT93ydWTcQbKsn3w61Fi7so/Wmzeq68mnusOKm6mmKQnFjqKv 8P3YOaUouR2/cr3wtdRaj8jTwC0/spJUqvEOpBYAr3QrW2t5YwrT7hDgzFAo/Zl4uyUr dXVr+2Vh35Ly3+LU/xpU8J+OAqzCcFaTImam/6ED/LItIcPDONsq/aZ4xZUabXDE41QL Igv28cvQN//4+QPEPNhRVNmrVcHd4SfucifLePYBv6unxUceAn+TQidvd5Z3VEzRFj0z VvSeX+kupN1x/vfxBDUUNOH04KHzUwtV8Xw2aadiW8hjejXCztENIU7PE3U5kLDS76sd CbNQ== X-Gm-Message-State: AOJu0Yz1r/y8lCEWjr4HB7SVD2XmktMBv7daDmCsPA8C/KY7Z6M+Ki7+ e5nfzt3QfxS/sKzh0ILfiaig7bkMiDc= X-Received: by 2002:a05:6000:4026:b0:333:50f2:5757 with SMTP id cp38-20020a056000402600b0033350f25757mr3500662wrb.5.1702221999797; Sun, 10 Dec 2023 07:26:39 -0800 (PST) Received: from matrix-ESPRIMO-P710 (p54a07fa0.dip0.t-ipconnect.de. [84.160.127.160]) by smtp.gmail.com with ESMTPSA id g9-20020a5d4889000000b0033609584b9dsm6265939wrq.74.2023.12.10.07.26.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 10 Dec 2023 07:26:39 -0800 (PST) Date: Sun, 10 Dec 2023 16:26:38 +0100 From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH 06/10] staging: rtl8192e: Remove variable ForcedAMPDUMode Message-ID: <5bf740a2da78ec3b54249a30cbee70301b37e7eb.1702212003.git.philipp.g.hortmann@gmail.com> References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.6 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Sun, 10 Dec 2023 07:27:07 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1784909205218104496 X-GMAIL-MSGID: 1784909205218104496 ForcedAMPDUMode is set to 0 and unchanged. Therefore all equations result accordingly and ForcedAMPDUMode can be removed. As a result label FORCED_AGG_SETTING is unused and can be removed as well. Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8192e/rtl819x_HT.h | 1 - drivers/staging/rtl8192e/rtllib_tx.c | 21 ++------------------- 2 files changed, 2 insertions(+), 20 deletions(-) diff --git a/drivers/staging/rtl8192e/rtl819x_HT.h b/drivers/staging/rtl8192e/rtl819x_HT.h index 0664eb86bada..d249062e7b66 100644 --- a/drivers/staging/rtl8192e/rtl819x_HT.h +++ b/drivers/staging/rtl8192e/rtl819x_HT.h @@ -113,7 +113,6 @@ struct rt_hi_throughput { u8 CurrentAMPDUFactor; u8 mpdu_density; u8 current_mpdu_density; - enum ht_aggre_mode ForcedAMPDUMode; u8 forced_ampdu_factor; u8 forced_mpdu_density; enum ht_aggre_mode ForcedAMSDUMode; diff --git a/drivers/staging/rtl8192e/rtllib_tx.c b/drivers/staging/rtl8192e/rtllib_tx.c index a2ae68cc13f5..0fa6f674a844 100644 --- a/drivers/staging/rtl8192e/rtllib_tx.c +++ b/drivers/staging/rtl8192e/rtllib_tx.c @@ -303,13 +303,13 @@ static void rtllib_tx_query_agg_cap(struct rtllib_device *ieee, } else if (!ts->disable_add_ba) { TsStartAddBaProcess(ieee, ts); } - goto FORCED_AGG_SETTING; + return; } else if (!ts->using_ba) { if (SN_LESS(ts->tx_admitted_ba_record.ba_start_seq_ctrl.field.seq_num, (ts->tx_cur_seq + 1) % 4096)) ts->using_ba = true; else - goto FORCED_AGG_SETTING; + return; } if (ieee->iw_mode == IW_MODE_INFRA) { tcb_desc->ampdu_enable = true; @@ -317,23 +317,6 @@ static void rtllib_tx_query_agg_cap(struct rtllib_device *ieee, tcb_desc->ampdu_density = ht_info->current_mpdu_density; } } -FORCED_AGG_SETTING: - switch (ht_info->ForcedAMPDUMode) { - case HT_AGG_AUTO: - break; - - case HT_AGG_FORCE_ENABLE: - tcb_desc->ampdu_enable = true; - tcb_desc->ampdu_density = ht_info->forced_mpdu_density; - tcb_desc->ampdu_factor = ht_info->forced_ampdu_factor; - break; - - case HT_AGG_FORCE_DISABLE: - tcb_desc->ampdu_enable = false; - tcb_desc->ampdu_density = 0; - tcb_desc->ampdu_factor = 0; - break; - } } static void rtllib_query_ShortPreambleMode(struct rtllib_device *ieee,