From patchwork Thu Apr 17 04:57:07 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sarika Sharma X-Patchwork-Id: 882283 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9C5B81DE8B9 for ; Thu, 17 Apr 2025 04:57:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.180.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1744865862; cv=none; b=rh+UMupdu3Om78LHGiTt2fHXVrr7s24ZiJ4HNfM9PnitFXFLqyv73WnSECI1FpYvazixShkTorifmqtiDLfRnx07FJCtxAUevMK02R+qFgaKGJiKy9DN5qH2HrgWHP/egp7Fxk3F+zDTxsRiOT/tZjJ03yPv3zPMjRCxDqVmPtM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1744865862; c=relaxed/simple; bh=n0QvlO4MrFfPuVZZF8XbGVQWQ0bDmrB2yU/TbbUbedY=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=Oa7rm2/UtFJxa+H7RxSH7BcLkHrLVnUmqILQKO/aKIakHzB6idYkXAI/0fVDTXp+mizw7Gs6F+YrCKxt5ZGoreBhcALvyvh84c3ekab+cY2sqzgZdwo7ohA9kWAEGFIZSAAd7SszgYpTWfTgiJB2xDw953e7yQA0KGB/zvHCyoI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com; spf=pass smtp.mailfrom=quicinc.com; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b=m0xs69Qs; arc=none smtp.client-ip=205.220.180.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=quicinc.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="m0xs69Qs" Received: from pps.filterd (m0279871.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 53GLViNE026237; Thu, 17 Apr 2025 04:57:37 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= TfVUVH9OHe212Bq7gN4wScGbw4nbwKZ+q7iQr86nr40=; b=m0xs69QsEFSZTBRZ iIwtPd1ustlAATcRWQbLi6Wq45ClmQFK/fWOo2LpcK3YUZyY9/1u6MHtyPOFCekc TI+5lOpvTNUprXRG5R3JaFBHj7Wa+jK6yrPWIT11Wshmo4keFknJb83Dtft5zio7 BjkwedGhJGT/S7Q+NmRSZ0C+dvndiI9diogY+ZC8nG0Sfxhzycw9q2kaN165/YjJ j6fnFX3cLxlFgRDM8JW6TGdH26uwsw30ebpY/dUYznahRMOoP/EG2z4/N831I2GD paEN0iy7oAJbDPWgAbmYfpqcV5tP0n9vCe/KVkjTc6227lpst0bOlMLfcRmH6+13 3yHM9Q== Received: from nasanppmta03.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 45yfs1dkkw-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 17 Apr 2025 04:57:37 +0000 (GMT) Received: from nasanex01c.na.qualcomm.com (nasanex01c.na.qualcomm.com [10.45.79.139]) by NASANPPMTA03.qualcomm.com (8.18.1.2/8.18.1.2) with ESMTPS id 53H4vanK015200 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 17 Apr 2025 04:57:36 GMT Received: from hu-sarishar-blr.qualcomm.com (10.80.80.8) by nasanex01c.na.qualcomm.com (10.45.79.139) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.9; Wed, 16 Apr 2025 21:57:34 -0700 From: Sarika Sharma To: CC: , Sarika Sharma Subject: [PATCH ath-next v5 4/6] wifi: ath12k: add EHT support for TX rate Date: Thu, 17 Apr 2025 10:27:07 +0530 Message-ID: <20250417045709.770219-5-quic_sarishar@quicinc.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20250417045709.770219-1-quic_sarishar@quicinc.com> References: <20250417045709.770219-1-quic_sarishar@quicinc.com> Precedence: bulk X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nasanex01c.na.qualcomm.com (10.45.79.139) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Authority-Analysis: v=2.4 cv=P9I6hjAu c=1 sm=1 tr=0 ts=68008a41 cx=c_pps a=JYp8KDb2vCoCEuGobkYCKw==:117 a=JYp8KDb2vCoCEuGobkYCKw==:17 a=GEpy-HfZoHoA:10 a=XR8D0OoHHMoA:10 a=COk6AnOGAAAA:8 a=nwLLUvrA-SLCDLgIScsA:9 a=TjNXssC_j7lpFel5tvFf:22 X-Proofpoint-GUID: PAaRv5RCdDC4A_yYtr84hSJI0x58fQ2Y X-Proofpoint-ORIG-GUID: PAaRv5RCdDC4A_yYtr84hSJI0x58fQ2Y X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1095,Hydra:6.0.680,FMLib:17.12.68.34 definitions=2025-04-17_01,2025-04-15_01,2024-11-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 lowpriorityscore=0 clxscore=1015 bulkscore=0 impostorscore=0 phishscore=0 suspectscore=0 mlxscore=0 spamscore=0 malwarescore=0 adultscore=0 priorityscore=1501 mlxlogscore=813 classifier=spam authscore=0 authtc=n/a authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.19.0-2502280000 definitions=main-2504170036 Currently, TX rates are not supported for EHT. Hence, add EHT handling for TX rates and update the EHT-specific fields in arsta accordingly. Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.4.1-00199-QCAHKSWPL_SILICONZ-1 Signed-off-by: Sarika Sharma --- drivers/net/wireless/ath/ath12k/dp_rx.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/drivers/net/wireless/ath/ath12k/dp_rx.c b/drivers/net/wireless/ath/ath12k/dp_rx.c index c2568d02c42e..edd3452d659f 100644 --- a/drivers/net/wireless/ath/ath12k/dp_rx.c +++ b/drivers/net/wireless/ath/ath12k/dp_rx.c @@ -1474,6 +1474,16 @@ ath12k_update_per_peer_tx_stats(struct ath12k *ar, v = ath12k_he_ru_tones_to_nl80211_he_ru_alloc(tones); arsta->txrate.he_ru_alloc = v; break; + case WMI_RATE_PREAMBLE_EHT: + arsta->txrate.mcs = mcs; + arsta->txrate.flags = RATE_INFO_FLAGS_EHT_MCS; + arsta->txrate.he_dcm = dcm; + arsta->txrate.eht_gi = ath12k_mac_eht_gi_to_nl80211_eht_gi(sgi); + tones = le16_to_cpu(user_rate->ru_end) - + le16_to_cpu(user_rate->ru_start) + 1; + v = ath12k_mac_eht_ru_tones_to_nl80211_eht_ru_alloc(tones); + arsta->txrate.eht_ru_alloc = v; + break; } arsta->txrate.nss = nss;