Received: by 2002:ab2:1149:0:b0:1f3:1f8c:d0c6 with SMTP id z9csp1633770lqz; Mon, 1 Apr 2024 12:06:01 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXF0MqnCNQe1MOsXFItcWcpLcDCLn2JjzOMNK234q4bnQEatUcXQWqdWqc/3eal6YYNUHgVNRbADfuqYJVTu5PWNdfn1TrPzPZKYJnYCQ== X-Google-Smtp-Source: AGHT+IGu8aPeWoRaGoo9lnw/DvpuxXPMYVIYwDdGRXmGtFnT8PaRaj2eG2xMk6JDmTaZV1Lzo9DU X-Received: by 2002:a05:6e02:3206:b0:365:bff:adfa with SMTP id cd6-20020a056e02320600b003650bffadfamr12220975ilb.17.1711998361358; Mon, 01 Apr 2024 12:06:01 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711998361; cv=pass; d=google.com; s=arc-20160816; b=tNdJnXPPbr2ENXznEq8T9uSKzd6iUNWdGmIg6M997Q2o23T74pI0Xpoo+rMNtdEiEH 4IEYb91pguWy7X2gVXtf77XXa7oWwkKqvgoo7JSXVKoD7juLkD2FPqtn6cOtS7JLD1KM NVTCC4YqxkNgoXJtpmbMi1O7eHniSai9KZZ1VKBAUiAaMO2WGL74Q/X2s7GtA1q85kjV NKEDbCCI7lq8F2Pe80ypxnVehqnScyXTaL8NQDiuazuGM1bdyHNxIttg7Ig3S0omOTBZ RinVzNaN6tb6NaaOCcoDgYVJd7eaHd0NrIJ479/2iCcId7CvsZh/igyP+UTsNfWDMl3b cLSA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=yOEa7ls97muzeJvwTJXe8HdQsVkZ9ZklfSjgBNl89oc=; fh=hXmvBwTcrACbulhadJq4aGomw93PvN9px3WarQqqC4o=; b=CNmXa0w4pJQvPntcvkUuYvArbtul1O6gH9gy7A9DS/VgpShHbozIfTsZ05er5kqUKu cr5rKul/+g7/4AoLnhQOSxC1P7dFg61435M1v0v2NsG2HoRTfGMICZ0qk8z3MiOF1dBK 6eNj/zxv9TphG4rpls+crhyu68uBJG7jtJvxujg5mkK4Ak2yzX2mPDRni27I3y2dcEJb ZzFa4ezecOmih4ZRXFzEczw7BYBEBbEVJOUSU93hc3SyQ4cr5JyD9xcngF4UuiR6aVJg i+nHXvoylpdD8/IMEuAVgnv4aJnqxVz3VseeAg8h4b0Jui5Lpbf+Hj+BOd5URE5lIc1M QIew==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b="UzGD7/+z"; arc=pass (i=1 spf=pass spfdomain=quicinc.com dkim=pass dkdomain=quicinc.com dmarc=pass fromdomain=quicinc.com); spf=pass (google.com: domain of linux-wireless+bounces-5732-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-wireless+bounces-5732-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id e3-20020a637443000000b005e4901151ddsi10154598pgn.92.2024.04.01.12.06.00 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 Apr 2024 12:06:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless+bounces-5732-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b="UzGD7/+z"; arc=pass (i=1 spf=pass spfdomain=quicinc.com dkim=pass dkdomain=quicinc.com dmarc=pass fromdomain=quicinc.com); spf=pass (google.com: domain of linux-wireless+bounces-5732-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-wireless+bounces-5732-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 4195AB2176F for ; Mon, 1 Apr 2024 19:06:00 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 15CC75336D; Mon, 1 Apr 2024 19:05:28 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="UzGD7/+z" X-Original-To: linux-wireless@vger.kernel.org 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 79959524DF for ; Mon, 1 Apr 2024 19:05:26 +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=1711998328; cv=none; b=o+khV1TPuMdfSKPoLCLIeDb6p+yH/CaprBSvWzmaiF/J0n8j0k9akSJeDd4IOkF7soNo3uKwAjdGft1k3ItVrtyN8EJ6v5LxF1b+hrAfejE2JHHVZskgwTd26NRfrpNRqa85pZ+76oiap3j5M4n7/NOklCRMjotzdwULGSh9O60= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711998328; c=relaxed/simple; bh=PTQYjnHT17rDSPbg3yN5mRNbiHQ807M5P779H3qQqEA=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=d0xRmn07zRV1+8/Dw74fyo3DE279hBuV3+GoUQQO01dWy6B9vbkXS0IMW4uGP894ceniz4aWTLQn+BF4qPtN5wi8AVIJ3tO2dHabbaxS0YzEAmc2Y0rt+a3vvHVb7tz9j0rfOKgbn+E4B4nojIzyQPJwhakK2RuwcwFqQRc/j4k= 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=UzGD7/+z; 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 Received: from pps.filterd (m0279871.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.24/8.17.1.24) with ESMTP id 431FQDm7030389; Mon, 1 Apr 2024 19:05:23 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s= qcppdkim1; bh=yOEa7ls97muzeJvwTJXe8HdQsVkZ9ZklfSjgBNl89oc=; b=Uz GD7/+zMiygo4JV2Hcht3uG45gds8OR/k1r27tPEz1p5+x5V06nYlPgRSrfYMinkF 1NrcQ4xvVSqhfxJPYHYitnU0N3MJHD5Qj8/lunqXSGPxeSW4EN3CyI08r2evaSPM lVWb/nK3RSB/dC/M7xEY8tptzK3+/q5jneIJ6A/OKtMhRkGER8/XBFsq6mNXNd4Z Se4oWdFht0l5mk6vXf/aSFODNmxZ+Hls968JD9q8Dv5UFa4QCvfHv0NjmSpffrrV UiprmF60KK+O4FvjRdcWj/Yv/fJvlJhAPIOiloZVQhy0zRJW2QvyUcwHOwCo4FCh JZxcTD87seylBRFH5sHw== Received: from nalasppmta03.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3x7qgw9kt2-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 01 Apr 2024 19:05:23 +0000 (GMT) Received: from nalasex01a.na.qualcomm.com (nalasex01a.na.qualcomm.com [10.47.209.196]) by NALASPPMTA03.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 431J5MQI005602 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 1 Apr 2024 19:05:22 GMT Received: from hu-ramess-blr.qualcomm.com (10.80.80.8) by nalasex01a.na.qualcomm.com (10.47.209.196) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.40; Mon, 1 Apr 2024 12:05:20 -0700 From: Rameshkumar Sundaram To: CC: , Sriram R , Rameshkumar Sundaram , Jeff Johnson Subject: [PATCH v6 11/12] wifi: ath12k: Modify rts threshold mac op for single wiphy Date: Tue, 2 Apr 2024 00:34:08 +0530 Message-ID: <20240401190409.2461819-12-quic_ramess@quicinc.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240401190409.2461819-1-quic_ramess@quicinc.com> References: <20240401190409.2461819-1-quic_ramess@quicinc.com> Precedence: bulk X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nalasex01a.na.qualcomm.com (10.47.209.196) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-ORIG-GUID: fHKGqfhcqbHckFhgS9DRHQr0U69UvY9N X-Proofpoint-GUID: fHKGqfhcqbHckFhgS9DRHQr0U69UvY9N X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.1011,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2024-04-01_13,2024-04-01_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxlogscore=922 clxscore=1015 priorityscore=1501 bulkscore=0 adultscore=0 suspectscore=0 impostorscore=0 spamscore=0 lowpriorityscore=0 malwarescore=0 mlxscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2403210001 definitions=main-2404010134 From: Sriram R Since multiple radios are abstracted under a single wiphy, apply the rts threshold value to all the vdevs of the radios combined under single wiphy. This also implies that vif specific rts threshold support needs to be added in future from cfg80211/mac80211. Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.0.1-00029-QCAHKSWPL_SILICONZ-1 Tested-on: WCN7850 hw2.0 PCI WLAN.HMT.1.0.c5-00481-QCAHMTSWPL_V1.0_V2.0_SILICONZ-3 Signed-off-by: Sriram R Signed-off-by: Rameshkumar Sundaram Acked-by: Jeff Johnson --- drivers/net/wireless/ath/ath12k/mac.c | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/drivers/net/wireless/ath/ath12k/mac.c b/drivers/net/wireless/ath/ath12k/mac.c index 76c3cd6f0bcc..2b70e4394923 100644 --- a/drivers/net/wireless/ath/ath12k/mac.c +++ b/drivers/net/wireless/ath/ath12k/mac.c @@ -7319,11 +7319,21 @@ static int ath12k_mac_op_set_rts_threshold(struct ieee80211_hw *hw, u32 value) { struct ath12k_hw *ah = ath12k_hw_to_ah(hw); struct ath12k *ar; - int param_id = WMI_VDEV_PARAM_RTS_THRESHOLD, ret; + int param_id = WMI_VDEV_PARAM_RTS_THRESHOLD, ret = 0, i; - ar = ath12k_ah_to_ar(ah, 0); - - ret = ath12k_set_vdev_param_to_all_vifs(ar, param_id, value); + /* Currently we set the rts threshold value to all the vifs across + * all radios of the single wiphy. + * TODO Once support for vif specific RTS threshold in mac80211 is + * available, ath12k can make use of it. + */ + for_each_ar(ah, ar, i) { + ret = ath12k_set_vdev_param_to_all_vifs(ar, param_id, value); + if (ret) { + ath12k_warn(ar->ab, "failed to set RTS config for all vdevs of pdev %d", + ar->pdev->pdev_id); + break; + } + } return ret; } -- 2.25.1