Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp1737744pxu; Thu, 8 Oct 2020 20:59:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwsokHVBqq+nhUvBCGPxt5lYOdLjugY2pyPJWFf8Oo5CsNo6d5OreIDeEQeEUBvB6LnLxkV X-Received: by 2002:a50:9dc8:: with SMTP id l8mr12525104edk.58.1602215971688; Thu, 08 Oct 2020 20:59:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1602215971; cv=none; d=google.com; s=arc-20160816; b=q29AjhVPMxZ4bwThm6gbWu8l73j0Azo+hfPpkurSbDfp5lPpS/IT9cOOK9noAOJ+iw PMS0vof+aRWnMawnLc9f+IjgprHm/VEwymT72YgdNZ9ZUD6Yv6gXMPnknF2LbL5qjmMr n7rb4TxjbkdFYc1sJ8zk+q+AYUY3zzw1Lozn4XGLVI+vxWYJkOehKLDOZr/Mg3GP/5nQ tYqsY+J1gp4oecoaxov/pqQ785MjjUNJa9cXQpgkKzDD+z0waLUYwOsA/EXEIPKmjHUz pzAv7y3FDlfRn6GUIguw2C27Xnkhk/DbbVBii4pPvJqdb94MHV+Wzzt6YwdacfkVSd7m 5xsA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:in-reply-to:message-id:date:subject :cc:to:from:dmarc-filter:sender:dkim-signature; bh=+KvRJH1l5j5wBVH8zg1ox9d/VwSBujoK+faJv3zyftQ=; b=Xr4dj/xmvMv3kNc98rIKtisKpLvdnJjx83TtICMGWc77gpwEgg3pSmh0HP7YYNgGGJ U4BJwOPbn43PYFPgXq0WSn0supIW5CVO/u295zC4oOVuuUeTb5eACuA8hhRp7vlmfsWj xns6vF+U+grg8kN6NCbaYDNtRL0a9NSXXQwlR29KcJB5H13Wd9wBkiIpOpMwr91BysBU WoXQKom8NBJdVexUNM59C9jIEjV6NP9+WzL8RfSBd70g0TVyungNUbo5gSHJ/XBRWk4R E9Lz3ebgTOSU2r2JmpuRrLno9we10sXhJDOypSc/ug3DzjEXYZ3Jsd6rzuNW4RKnQDxZ nV8w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mg.codeaurora.org header.s=smtp header.b=AiRyunBU; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id qn3si5352520ejb.655.2020.10.08.20.59.07; Thu, 08 Oct 2020 20:59:31 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@mg.codeaurora.org header.s=smtp header.b=AiRyunBU; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731044AbgJICSW (ORCPT + 99 others); Thu, 8 Oct 2020 22:18:22 -0400 Received: from z5.mailgun.us ([104.130.96.5]:62727 "EHLO z5.mailgun.us" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730598AbgJICSW (ORCPT ); Thu, 8 Oct 2020 22:18:22 -0400 DKIM-Signature: a=rsa-sha256; v=1; c=relaxed/relaxed; d=mg.codeaurora.org; q=dns/txt; s=smtp; t=1602209901; h=References: In-Reply-To: Message-Id: Date: Subject: Cc: To: From: Sender; bh=+KvRJH1l5j5wBVH8zg1ox9d/VwSBujoK+faJv3zyftQ=; b=AiRyunBU7FuxO6ni8W5C9wnASqXPVPQiBmYbHWW63zhrfCq7u6TFUDiW8+8O+JFMG8Bh0u3Y KqfNtvjKA0N3CTxfQQ0mYYdw0SRsYvNq669kCnrPMz9W9WT4kQjX++jOArvJyAL7rj0ZG5+V YX/+uwx3u2c07Y6g7MZ8PUozV/4= X-Mailgun-Sending-Ip: 104.130.96.5 X-Mailgun-Sid: WyI3YTAwOSIsICJsaW51eC13aXJlbGVzc0B2Z2VyLmtlcm5lbC5vcmciLCAiYmU5ZTRhIl0= Received: from smtp.codeaurora.org (ec2-35-166-182-171.us-west-2.compute.amazonaws.com [35.166.182.171]) by smtp-out-n03.prod.us-east-1.postgun.com with SMTP id 5f7fc86d4f8cc67c31d80fbd (version=TLS1.2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256); Fri, 09 Oct 2020 02:18:21 GMT Sender: pradeepc=codeaurora.org@mg.codeaurora.org Received: by smtp.codeaurora.org (Postfix, from userid 1001) id 0FEE4C43385; Fri, 9 Oct 2020 02:18:21 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-caf-mail-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=ALL_TRUSTED,BAYES_00,SPF_FAIL, URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from pradeepc2-linux.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: pradeepc) by smtp.codeaurora.org (Postfix) with ESMTPSA id 63B64C43395; Fri, 9 Oct 2020 02:18:20 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 63B64C43395 Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; spf=fail smtp.mailfrom=pradeepc@codeaurora.org From: Pradeep Kumar Chitrapu To: Johannes Berg , ath11k@lists.infradead.org Cc: linux-wireless@vger.kernel.org, Pradeep Kumar Chitrapu Subject: [PATCH 3/4] ath11k: support TXOP duration based RTS threshold Date: Thu, 8 Oct 2020 19:18:10 -0700 Message-Id: <20201009021811.18584-4-pradeepc@codeaurora.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20201009021811.18584-1-pradeepc@codeaurora.org> References: <20201009021811.18584-1-pradeepc@codeaurora.org> Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org HE operation IE in beacons is constructed based on userspace params, which firmware might not be aware of. This causes firmware not to configure TXOP duration based RTS threshold which could cause mismatch in behaviour with respect to what is being advertised in beacons. This patch sends HE operation IE fetched from beacon to firmware using WMI interface for configuration. Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.1.0.1-01228-QCAHKSWPL_SILICONZ-1 Signed-off-by: Pradeep Kumar Chitrapu --- drivers/net/wireless/ath/ath11k/mac.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/drivers/net/wireless/ath/ath11k/mac.c b/drivers/net/wireless/ath/ath11k/mac.c index 3f63a7bd6b59..77d073054ba2 100644 --- a/drivers/net/wireless/ath/ath11k/mac.c +++ b/drivers/net/wireless/ath/ath11k/mac.c @@ -1948,9 +1948,25 @@ static void ath11k_mac_op_bss_info_changed(struct ieee80211_hw *hw, if (changed & BSS_CHANGED_BSSID && !is_zero_ether_addr(info->bssid)) ether_addr_copy(arvif->bssid, info->bssid); - if (changed & BSS_CHANGED_BEACON_ENABLED) + if (changed & BSS_CHANGED_BEACON_ENABLED) { ath11k_control_beaconing(arvif, info); + if (arvif->is_up && vif->bss_conf.he_support && + vif->bss_conf.he_oper.params) { + param_id = WMI_VDEV_PARAM_HEOPS_0_31; + param_value = vif->bss_conf.he_oper.params; + ret = ath11k_wmi_vdev_set_param_cmd(ar, arvif->vdev_id, + param_id, param_value); + ath11k_dbg(ar->ab, ATH11K_DBG_MAC, + "he oper param: %x set for VDEV: %d\n", + param_value, arvif->vdev_id); + + if (ret) + ath11k_warn(ar->ab, "Failed to set he oper params %x for VDEV %d: %i\n", + param_value, arvif->vdev_id, ret); + } + } + if (changed & BSS_CHANGED_ERP_CTS_PROT) { u32 cts_prot; -- 2.17.1