Received: by 2002:ab2:710b:0:b0:1ef:a325:1205 with SMTP id z11csp1079792lql; Tue, 12 Mar 2024 06:58:01 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUs2B8U9kX/98CPU7PnV3eWjA+u+BwIKn9xqoUtwlF6+wCPqIfReWI/8eVxega/2ZXxiqx5no1uCX85zesuOGIhVHWJDwvKdIz7asupaA== X-Google-Smtp-Source: AGHT+IEvZZ6Y+ZuKdW2UmtlQhEmYOwPnjw5+pLv4uE1/DJ96PQuwIRiGLUJR61fUsi4V3rKZfV7n X-Received: by 2002:a17:902:ea01:b0:1db:cb13:10f1 with SMTP id s1-20020a170902ea0100b001dbcb1310f1mr11547172plg.19.1710251881063; Tue, 12 Mar 2024 06:58:01 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1710251881; cv=pass; d=google.com; s=arc-20160816; b=c31q4ICoDV5Ogb31dAhlyO93wDBMlxZtboZsQX/aOG7XkofofAvj0H8XJcVSWHExF1 +iJOwGnFzh3lJh/ic/9kByUcxumPUf6nAVH9tuaZ8Qm9fZY31ZQbHtZfFCUWXm2DNBNy NvP98SRedPIiv33UrNwHACBnzv41CEAMOrP9p0yF0Cy4tYUBwbDRESa0oHrIMXVf2y45 QNguGZWEpuhiPyeZu6Cinss6tbvlOsHEoPpG9OUgAsoSlGnerUp58zWsP3FrRHGSXTDJ hTKue4IuFpsQbpMaEu+Gvybq6ECXDhyW6/a+yjASOb5HvZk68q/bcAAliMVNSLiWgOFm Mo7Q== 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=2ooT2xNwMhbWwrEQmrl62I+wO7+i9J6o798XT7Cmwm4=; fh=woZAKccQQLpsH+ifgAFl/ubgLBC7CdNtwbjjrWqWXi0=; b=H9+jAzOBOUw1FAeTOB2MUCbIXRvz3skK2avpQuzJ8tHIlEx4niUrOQQy9mZvm/TD8f KULhQao5081/EP5K5nrKaaDYFryFG2EVcXtd5pc8vkkRp2/ekpOIJZMd4yul5A9kY7Wm Q1J9vDXzxNrZ2W5DOVV6rniMbiH7F3ouOOZNLkFC9lSbZ/6tHX9HREYYBdpfKW1IgceU Adq6VuhU39UBlU78ahz8xPr9KpuqdjfPVCn6/3rzoAlVL4emRq9UE/figppgfaLzQm9K DEWcpWzvi/cUa7J6w1fb3uqlUUKTSxhKfohgZyAVbisT9OMT+siGVKVyMh5e5+vFj+ep ZKMA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=VAg2x0X5; 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-4622-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-wireless+bounces-4622-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 q3-20020a17090311c300b001da15580d4bsi7190668plh.90.2024.03.12.06.58.00 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Mar 2024 06:58:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless+bounces-4622-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=VAg2x0X5; 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-4622-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-wireless+bounces-4622-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 71602B237D6 for ; Tue, 12 Mar 2024 13:57:16 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 882BD7AE40; Tue, 12 Mar 2024 13:56:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="VAg2x0X5" 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 1DB607AE76 for ; Tue, 12 Mar 2024 13:56:40 +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=1710251802; cv=none; b=rsRUpfTlmDvqGKgUf9jH9y5Yg0PQf7ANHpiQlGVniRjofdxu6aQUQotVIQ3O4QWyfg4MeGlT3zVaJslKOPoQvnq0gaPpsBCnX4t7z484l5gjLjmbkgHVNyLCbI1Ms3wwR5iNq05c1lHP/F1y5HNre4hB7jadpoZhpgtG4rCYQkg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710251802; c=relaxed/simple; bh=nFpWTN4XYtHR9px+ar1TI87gZMRP0ZR4YizJg/0gSs0=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=maGmLEblk/bPUc0R6rYKSTBxe1RIaA3Ja3Da4IvpyviKyDFzG+9mWx7KQY3G19uIIr5Kkqwgi7N/VS8n7Liwu2sGDRjJGHZY5J+ym9sLMyC2kEA6etrMvB2OEWsT4QbFp/H/gXj2oF8Ao+V5o1YBQ8YWCKv63tbxNBZ0/qO+98s= 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=VAg2x0X5; 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 (m0279866.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.24/8.17.1.24) with ESMTP id 42CDAAqZ006059; Tue, 12 Mar 2024 13:56:38 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=2ooT2xNwMhbWwrEQmrl62I+wO7+i9J6o798XT7Cmwm4=; b=VA g2x0X5HluJWuP0TRhzjILFY5y9yHFs794tSqKoM/vEmgzi3N7nMYILEb5Q61Fvxf t4ve29LSNY9su0f7hTrciBN9Xr521O0ytv3JgSFmf4Dk5YGQpBDSHzhzkhoErURT 2TWlGVqSNi0CgA6/z6E4/WSPLWO3Ziurz2HWvgiuQ2RVlzvTyyD9IWC7VMJ1pmq1 WM5DD2ELpzyvyowUXYXqxousssIzIKpmOd3CbEyzuR36yVkuEOV2+uq/IGHG470N O8RaexYmFiRHstE9qmwvCnAdnZ3h9Th2X4/l4lQw0QqgMlxvnpGupZkvCKPqYlMA ozp3NsakFavRPrFRz4Kg== Received: from nalasppmta01.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3wtgc3h236-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 12 Mar 2024 13:56:38 +0000 (GMT) Received: from nalasex01a.na.qualcomm.com (nalasex01a.na.qualcomm.com [10.47.209.196]) by NALASPPMTA01.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 42CDubDd002785 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 12 Mar 2024 13:56:37 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; Tue, 12 Mar 2024 06:56:35 -0700 From: Rameshkumar Sundaram To: CC: , Sriram R , Rameshkumar Sundaram Subject: [PATCH v4 11/12] wifi: ath12k: Modify rts threshold mac op for single wiphy Date: Tue, 12 Mar 2024 19:25:56 +0530 Message-ID: <20240312135557.1778379-12-quic_ramess@quicinc.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240312135557.1778379-1-quic_ramess@quicinc.com> References: <20240312135557.1778379-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: GWSpKCDEHbr3U66smMW73ArZcEIqX2J9 X-Proofpoint-GUID: GWSpKCDEHbr3U66smMW73ArZcEIqX2J9 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-12_08,2024-03-12_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 clxscore=1015 bulkscore=0 phishscore=0 suspectscore=0 lowpriorityscore=0 spamscore=0 adultscore=0 mlxscore=0 mlxlogscore=909 malwarescore=0 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2402120000 definitions=main-2403120107 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 --- 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 0934abc7995f..6123d7db2edc 100644 --- a/drivers/net/wireless/ath/ath12k/mac.c +++ b/drivers/net/wireless/ath/ath12k/mac.c @@ -7292,11 +7292,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, 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(i, ah, ar) { + 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