Received: by 2002:a05:7208:70d5:b0:7f:5597:fa5c with SMTP id q21csp101647rba; Wed, 20 Mar 2024 12:11:13 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCX09BSKlstUajmmLc+1IDulDtIiBrAUcdyQbocI0GK4tV4U27OQHQ/e9ETZ/zgm3vdLzoGVc4PoDnZN/6VBO3myyrn0YuCWPJhfpB9obA== X-Google-Smtp-Source: AGHT+IFwmPlkkb+/WbTnvqxnVDwN2Sp5M9QKExGj4Q499Y86mcqerZ5+Zpu+Ry6NibBazCFMc5dL X-Received: by 2002:a37:e10b:0:b0:789:f058:b261 with SMTP id c11-20020a37e10b000000b00789f058b261mr6261856qkm.77.1710961873152; Wed, 20 Mar 2024 12:11:13 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1710961873; cv=pass; d=google.com; s=arc-20160816; b=cRTDRohuY6s6bFElIL771xIiJN+y3GvendUUmC/t0IiSA9PLeP4oEfLEf0KtVn98Wp xdome2D8vaG1VW7T7/18XnjgPSLqXQPNa4yooJOQT9LWv5cAukzhjEEcimlu3lcHC8Hy dV6vCa9oENSpW/tJ/5k7IIDhgdviI5BoyMsRr3GHbySl/c7XFeOVHojVSqIqFBaAIVfi GAuTPoWeIwKl/OOx8Rxyx2KRNzn6+DTvZQH+YEynWOy51uVTBooTRNBDVFKCLPAum8TC 9SVrmB6bNwaCe+0bXSCh4todm5dC6LcGyqmtEUudF4dzt/NZ0ZuG7hvPXHh7dxTZyCbt myEg== 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=JPp/lnrghgJ+sAtmwgC6VXjLuoIofbbIKkeogD6puEs=; fh=hXmvBwTcrACbulhadJq4aGomw93PvN9px3WarQqqC4o=; b=yPsUgYb25GrMHERx4X7ZR3wTw9yqfCnii4GsElaTrL2y7HEkjMtT++948zbKczPl/N MTl6nfUj2zNk2lYutliUR5xPuQWjJ95JD6LljZm5OSz+Rag+kaYY2ICaWnVxHJcHuioS 2y05MNO7sPrNb79hBpN1lYNSAqUUN48x1eZz/HTUkb/LuknqHi9f490wTQ+uCNt8Vl6F 60XFrasdQOq3V6nTS4ZEgWR9z+qHPyeFd4FNherYSI5wLvM+7XRXC4fs6s2J9/6Mg+YZ iM5TZcvphlT8pgPJzCVJZ2A1fAqBe/9lu42lnkwlUJDAsvf9vDrZ0ayNJvCWGvJ5D7SV bYZA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=mbGknYkJ; 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-5017-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-wireless+bounces-5017-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id u15-20020a05620a120f00b00789e6d19bfcsi11432196qkj.238.2024.03.20.12.11.13 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Mar 2024 12:11:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless+bounces-5017-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=mbGknYkJ; 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-5017-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-wireless+bounces-5017-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 ny.mirrors.kernel.org (Postfix) with ESMTPS id E239B1C213CE for ; Wed, 20 Mar 2024 19:11:12 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id CA8F98592E; Wed, 20 Mar 2024 19:10:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="mbGknYkJ" X-Original-To: linux-wireless@vger.kernel.org Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.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 43CFD84A43 for ; Wed, 20 Mar 2024 19:10:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710961843; cv=none; b=DsQD1yEBQRaW33PDvQ532+q0bE/Dk9aViyDTqlnGd3elc1R7F4SbaJcvQwsD6NwcgVX2vASDqTkmfDt7SncuuV91CB+nXnFdXIjtgS8WEOKmDZS7fthREbsUW2K8Z3r/mkGOxpq0zlvRgo/AdgoPGxX3RkbdKABQHWYhEwp04jY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710961843; c=relaxed/simple; bh=wSTvUOAQ4JzpsZs+9KJXBZNwFkEUYt4i+Noss54DzCk=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=dI4x5iHA42vJ8oO5b4SuiwcJ5fH0NpOdNF5y3JxvXVm2li7E8qJImuEhDl6Pp3VBhBpcCUa6ZIqea9JZmmeh8ZJlcTwiG+DnKa967nBCneD0JebBzL+NKv3tKbSjQKPLy5ks8URg5gb141P5BXIe9/bit/2BtNNMpqkQKAqHltk= 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=mbGknYkJ; arc=none smtp.client-ip=205.220.168.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 (m0279864.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.24/8.17.1.24) with ESMTP id 42KIrOVO009036; Wed, 20 Mar 2024 19:10:24 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=JPp/lnrghgJ+sAtmwgC6VXjLuoIofbbIKkeogD6puEs=; b=mb GknYkJvz6OyARzH/n1+XnXpsd1QdjBgA0HSEctWDiP1UlvQyDq6//k+7lPOwMk6A 6OzHv7wCEPgUK8KCCYsZ6XSBKbE5pvE0+6LoOqCZOSkcOTq0oCq2GSs4o179MrsB M3dgtbCVDBkaUxBQ1dnRyutrXn6x1vQ5GOYhIyjH0OSVHScl/6knS4RkuqPjQI6o owSWdheBHxlTRj6l7ujNofVJHkHM7H3m0RONNBz2TomGk4ONlw7LgUm+kphrtN+J 0rcj7wLT4XJty9Qv9QPNvCF+mWzabwNJPtUFTlTptx0IqaXsWiQqI9xDqChZlNkE huqOISQR42P5S4/EqZeg== Received: from nalasppmta05.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3wyvrmsd5x-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 20 Mar 2024 19:10:23 +0000 (GMT) Received: from nalasex01a.na.qualcomm.com (nalasex01a.na.qualcomm.com [10.47.209.196]) by NALASPPMTA05.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 42KJAN5F005459 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 20 Mar 2024 19:10:23 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; Wed, 20 Mar 2024 12:10:21 -0700 From: Rameshkumar Sundaram To: CC: , Sriram R , Rameshkumar Sundaram , Jeff Johnson Subject: [PATCH v5 11/12] wifi: ath12k: Modify rts threshold mac op for single wiphy Date: Thu, 21 Mar 2024 00:39:42 +0530 Message-ID: <20240320190943.3850106-12-quic_ramess@quicinc.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240320190943.3850106-1-quic_ramess@quicinc.com> References: <20240320190943.3850106-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: 4JiKWqOXYm5SNQjAX-xRliwkZlXe2kB2 X-Proofpoint-GUID: 4JiKWqOXYm5SNQjAX-xRliwkZlXe2kB2 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-03-20_10,2024-03-18_03,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 mlxlogscore=920 mlxscore=0 phishscore=0 clxscore=1015 lowpriorityscore=0 suspectscore=0 bulkscore=0 adultscore=0 impostorscore=0 malwarescore=0 priorityscore=1501 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2403140001 definitions=main-2403200154 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 fffab1f75fc4..08b560157fdc 100644 --- a/drivers/net/wireless/ath/ath12k/mac.c +++ b/drivers/net/wireless/ath/ath12k/mac.c @@ -7323,11 +7323,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