From nobody Sun Dec 28 02:50:01 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D8AFDC4332F for ; Wed, 13 Dec 2023 16:52:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1379325AbjLMQws (ORCPT ); Wed, 13 Dec 2023 11:52:48 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47034 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1379184AbjLMQwo (ORCPT ); Wed, 13 Dec 2023 11:52:44 -0500 Received: from mail-ed1-x52d.google.com (mail-ed1-x52d.google.com [IPv6:2a00:1450:4864:20::52d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4D363D0 for ; Wed, 13 Dec 2023 08:52:50 -0800 (PST) Received: by mail-ed1-x52d.google.com with SMTP id 4fb4d7f45d1cf-5451faa3aa7so1635178a12.0 for ; Wed, 13 Dec 2023 08:52:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1702486369; x=1703091169; 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=QsDC6cnDlhoPFsKvfa+aFC6albQxgKIcluRdn1hA6pw=; b=g4+ZpjuZ2koMAqeky0luxE2LWKELD/4DIonZsw5FCaBMY/ZonRB8K10LmA/g5FvX6W TJpMWX8WIZP2a9eBOu3+yCNqzuGAehAb/2RR6KocVkkJ34tTLxhTX4uC/Alat0ZL+/wL t9PpVJZ2YxrRjPmtGcuT9AABzVozH+ME28WFYW3Pk+sDXBJ267EzymnfpCqAJYQMzxKy ACi3UzrQo2gxiORR735L5eNeN4rCfRv1CK275O5KAa2REeK9unIYswnPzoSu1jA6yhrh s0Z0l0GrPNODn8qZFRK6m+GQiuAfEcbLyZILIFZhUM5gjcBE8glQj8k7iz/mzXEy0qj/ s6OA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702486369; x=1703091169; 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=QsDC6cnDlhoPFsKvfa+aFC6albQxgKIcluRdn1hA6pw=; b=PO/4YOBc4s8TZ6WLr6qyTfz5OSMMyVjn3mMnXB4x12c3QN+XdoBc2XRIQW3ydc/KTB ZHSMaR55R6UDLQdAzhYFkMy3gHN+QDBOVFi6cl/TezNo+/lsqALvvve5x18LzhMjwb0P 9DfodmNkWnVyCHbMuUF+0UkEDFIwp2CJ9qWyvRbt3syCQRqMegJa5VxMA5mQHF2Kwqj4 XY4ktSvcCL2LOv+W49UIcFy9UeZ7EvMskL7FKty+O/JJmo9IDIfwAnjCTygtndfZhIAC zv/VDrS6USxNQG1eiljKvynLQyqcDFCqDKpWOTNpm1t8Gl856K1MqyUNLJgtHuTj6Jpl GlpA== X-Gm-Message-State: AOJu0YypQP5hhGE6DuB6tD05hFUrO3aeC6BK455ii5bGyk00LV1ZjmMw ueZ5RERsQs/iVvUUAfEN3Sw= X-Google-Smtp-Source: AGHT+IGiLZB6J8iZW9hDz38oOTk+lx19cmC2hpUGX8EXkOEEpEKEYPXqrJS9OR/tvG214l7oaDTRuw== X-Received: by 2002:a17:907:d30a:b0:a1d:65d:c1b1 with SMTP id vg10-20020a170907d30a00b00a1d065dc1b1mr8031014ejc.2.1702486368388; Wed, 13 Dec 2023 08:52:48 -0800 (PST) Received: from matrix-ESPRIMO-P710 (p54a07fa0.dip0.t-ipconnect.de. [84.160.127.160]) by smtp.gmail.com with ESMTPSA id cx12-20020a170907168c00b00a1caa9dd507sm8111138ejd.52.2023.12.13.08.52.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Dec 2023 08:52:48 -0800 (PST) Date: Wed, 13 Dec 2023 17:52:46 +0100 From: Philipp Hortmann To: Greg Kroah-Hartman , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH 09/10] staging: rtl8192e: Remove constant variable reg_rt2rt_aggregation Message-ID: <07a0954cc6fd730d9d42054fa36346d1de07cd06.1702406712.git.philipp.g.hortmann@gmail.com> References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" ht_info->reg_rt2rt_aggregation is set to 1 and unchanged. Therefore all equations result accordingly and ht_info->reg_rt2rt_aggregation can be removed. Signed-off-by: Philipp Hortmann --- drivers/staging/rtl8192e/rtl819x_HT.h | 1 - drivers/staging/rtl8192e/rtl819x_HTProc.c | 37 +++++++---------------- 2 files changed, 11 insertions(+), 27 deletions(-) diff --git a/drivers/staging/rtl8192e/rtl819x_HT.h b/drivers/staging/rtl819= 2e/rtl819x_HT.h index 315905fa4b2c..514ac9e1f3f8 100644 --- a/drivers/staging/rtl8192e/rtl819x_HT.h +++ b/drivers/staging/rtl8192e/rtl819x_HT.h @@ -112,7 +112,6 @@ struct rt_hi_throughput { enum ht_extchnl_offset CurSTAExtChnlOffset; u8 cur_tx_bw40mhz; u8 sw_bw_in_progress; - u8 reg_rt2rt_aggregation; u8 current_rt2rt_aggregation; u8 current_rt2rt_long_slot_time; u8 sz_rt2rt_agg_buf[10]; diff --git a/drivers/staging/rtl8192e/rtl819x_HTProc.c b/drivers/staging/rt= l8192e/rtl819x_HTProc.c index 6bd4afe32f61..d9561e3a76d6 100644 --- a/drivers/staging/rtl8192e/rtl819x_HTProc.c +++ b/drivers/staging/rtl8192e/rtl819x_HTProc.c @@ -79,8 +79,6 @@ void ht_update_default_setting(struct rtllib_device *ieee) =20 ieee->tx_enable_fw_calc_dur =3D 1; =20 - ht_info->reg_rt2rt_aggregation =3D 1; - ht_info->reg_rx_reorder_enable =3D 1; ht_info->rx_reorder_win_size =3D 64; ht_info->rx_reorder_pending_time =3D 30; @@ -471,25 +469,17 @@ void HTOnAssocRsp(struct rtllib_device *ieee) ht_info->current_ampdu_enable =3D false; } =20 - if (!ht_info->reg_rt2rt_aggregation) { - if (ht_info->ampdu_factor > pPeerHTCap->MaxRxAMPDUFactor) + if (ieee->current_network.bssht.bd_rt2rt_aggregation) { + if (ieee->pairwise_key_type !=3D KEY_TYPE_NA) ht_info->CurrentAMPDUFactor =3D - pPeerHTCap->MaxRxAMPDUFactor; + pPeerHTCap->MaxRxAMPDUFactor; else - ht_info->CurrentAMPDUFactor =3D ht_info->ampdu_factor; - + ht_info->CurrentAMPDUFactor =3D HT_AGG_SIZE_64K; } else { - if (ieee->current_network.bssht.bd_rt2rt_aggregation) { - if (ieee->pairwise_key_type !=3D KEY_TYPE_NA) - ht_info->CurrentAMPDUFactor =3D - pPeerHTCap->MaxRxAMPDUFactor; - else - ht_info->CurrentAMPDUFactor =3D HT_AGG_SIZE_64K; - } else { - ht_info->CurrentAMPDUFactor =3D min_t(u32, pPeerHTCap->MaxRxAMPDUFactor, - HT_AGG_SIZE_32K); - } + ht_info->CurrentAMPDUFactor =3D min_t(u32, pPeerHTCap->MaxRxAMPDUFactor, + HT_AGG_SIZE_32K); } + ht_info->current_mpdu_density =3D pPeerHTCap->MPDUDensity; if (ht_info->iot_action & HT_IOT_ACT_TX_USE_AMSDU_8K) { ht_info->current_ampdu_enable =3D false; @@ -595,15 +585,10 @@ void HTResetSelfAndSavePeerSetting(struct rtllib_devi= ce *ieee, pNetwork->bssht.bd_ht_info_buf, pNetwork->bssht.bd_ht_info_len); =20 - if (ht_info->reg_rt2rt_aggregation) { - ht_info->current_rt2rt_aggregation =3D - pNetwork->bssht.bd_rt2rt_aggregation; - ht_info->current_rt2rt_long_slot_time =3D - pNetwork->bssht.bd_rt2rt_long_slot_time; - } else { - ht_info->current_rt2rt_aggregation =3D false; - ht_info->current_rt2rt_long_slot_time =3D false; - } + ht_info->current_rt2rt_aggregation =3D + pNetwork->bssht.bd_rt2rt_aggregation; + ht_info->current_rt2rt_long_slot_time =3D + pNetwork->bssht.bd_rt2rt_long_slot_time; =20 ht_iot_peer_determine(ieee); =20 --=20 2.43.0