Received: by 2002:a05:7412:3b8b:b0:fc:a2b0:25d7 with SMTP id nd11csp748692rdb; Thu, 8 Feb 2024 22:54:59 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCU2pWMvPzAFtpykf7m9Q93LeRXIH7MeYGPGPP/6pIzFZ96V2e1oGBkeA5XF7AcnkMi6HZpcDk1UHsXEG4W+D9J+8hZVBVVNXufarGR9Aw== X-Google-Smtp-Source: AGHT+IGzds1GftD0xyI9bWmzxk7g/EieW1Chda8+7zX3uxmYw4OcSGj452TXdSqxwrM8JaNnXyt8 X-Received: by 2002:a17:903:2285:b0:1d9:7782:316f with SMTP id b5-20020a170903228500b001d97782316fmr746920plh.39.1707461699515; Thu, 08 Feb 2024 22:54:59 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707461699; cv=pass; d=google.com; s=arc-20160816; b=DZMBICVW3IcB/xOsHu7QK7DIxDJ4h8zTKYRSN+l8Di5g09NMbQOviQpWpa0R6gjED1 K/Ht6FqaWrJUVShYL7R7+FcBRrr3mEtQWhq9eqdjDLC3jtaByGwG/TDmcc/5j/9TNt+j xNSR2Qe9K88uCtjSCv4QxkAPyMzJ3j6nnZWxblv5qlPHX1nV9GToJPwAyfS2OZNsAPVa PV7uZPzCYg1ETbXCYx0VLeWRoOCGeRs5vgS814sE/aANNnyLM6nQpagqHjwgWoho/08G V1bkyK+B1hASdfo4YWYvRGaU+8v8ppElTwLe7a/h1b+L4EbroFbc3flToNIfqiwQ6A7I Aahg== 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; bh=iWVF+lX752jp1t/mb93dtybr96aJJJBWzuAf5wSlsvA=; fh=0La9aob1F/Y8SAeGwVrQGIcgcKzh1GuAYpocTJ8Ymq4=; b=yBEK/PD/5X+joy8HYTx2SxxS1cdxqO2MrJjlMxrwv4f4NM49Y26ZgVPrGXe0lzxU8S PL6N5PZZnFCRLY8U6QiWy01G9pvq5Fu7cKUUR847zZzZkzpGLKoOFYBRpeguQ1qZTeDh LKxbnCCzObT66aWtAGLqsX5xi7fDlkhmihK4OiHFi/ADmskC8nn31koXKkzauePbVc25 zquL2TOwUjXgZ+F39nbWfHpIuZOtUoVdY4WdjvtkiJOIxrFULxxFK2GBz7kcNnuk2T2/ itjC2ERCVhzE0elzsZ82L1f4txfjPDhVUgvuL3P6Mh4g3lCSoGg3UcR2Gbre+kGx/Nov ZBNA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=realtek.com); spf=pass (google.com: domain of linux-wireless+bounces-3379-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-wireless+bounces-3379-linux.lists.archive=gmail.com@vger.kernel.org" X-Forwarded-Encrypted: i=2; AJvYcCW/WgeaYWBNz+tV/bjPQo+3AryE/ycLhz5ejxzXX8pAPf3U8jlZlQ6HRKeD7vDg7Y6++bzlBBjg676S5EvVn1wMmcFlvxI7j3mHyjNK6Q== Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id e14-20020a170902ed8e00b001d4931a0bfcsi1084744plj.638.2024.02.08.22.54.59 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Feb 2024 22:54:59 -0800 (PST) Received-SPF: pass (google.com: domain of linux-wireless+bounces-3379-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=realtek.com); spf=pass (google.com: domain of linux-wireless+bounces-3379-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-wireless+bounces-3379-linux.lists.archive=gmail.com@vger.kernel.org" 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 sv.mirrors.kernel.org (Postfix) with ESMTPS id 04193280E81 for ; Fri, 9 Feb 2024 06:54:31 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 3E638657DD; Fri, 9 Feb 2024 06:54:08 +0000 (UTC) X-Original-To: linux-wireless@vger.kernel.org Received: from rtits2.realtek.com.tw (rtits2.realtek.com [211.75.126.72]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C3C9C657CA for ; Fri, 9 Feb 2024 06:54:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=211.75.126.72 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707461648; cv=none; b=L4p0jGNZIcdRTkXMREQNSZkXQmrccoYQc0YqePIoQiY4Cr5uvxcDN+CNdMquhTq9iJYefcArxlpmgP3Ws4WzRdnvhljZE4KttTsOU43/GwYEq7l8ab3w3TMa8VAqClef5+bgeZkRWAnOxsC0BQsZyliPY7GmRiB9OudSFulPtzQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707461648; c=relaxed/simple; bh=/aLcYv5SaWRp5DwEd0pGRpAS1JIHIRTGJfEV4cA/Vno=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=WFerIhJ2QOvTezXwTNJUlak9DXea9LM83Fs+te6a8/SW69ANQaac1Mapii4+E2lu/A0fMX2WNJc4shthJIrK3+tvk1kmOanIvLCGagbjYz0XNEu3QpAssdhCny66qiG25vIoM5sAP8a6bZVJEXc9QNrMks8POuqc30IoZmRH1HE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=realtek.com; spf=pass smtp.mailfrom=realtek.com; arc=none smtp.client-ip=211.75.126.72 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=realtek.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=realtek.com X-SpamFilter-By: ArmorX SpamTrap 5.78 with qID 4196s11R1548442, This message is accepted by code: ctloc85258 Received: from mail.realtek.com (rtexh36506.realtek.com.tw[172.21.6.27]) by rtits2.realtek.com.tw (8.15.2/2.95/5.92) with ESMTPS id 4196s11R1548442 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 9 Feb 2024 14:54:01 +0800 Received: from RTEXMBS04.realtek.com.tw (172.21.6.97) by RTEXH36506.realtek.com.tw (172.21.6.27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.17; Fri, 9 Feb 2024 14:54:02 +0800 Received: from [127.0.1.1] (172.16.16.210) by RTEXMBS04.realtek.com.tw (172.21.6.97) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.35; Fri, 9 Feb 2024 14:54:01 +0800 From: Ping-Ke Shih To: CC: , , , Subject: [PATCH v2 10/11] wifi: rtw89: reference quota mode when setting Tx power Date: Fri, 9 Feb 2024 14:52:28 +0800 Message-ID: <20240209065229.34515-11-pkshih@realtek.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20240209065229.34515-1-pkshih@realtek.com> References: <20240209065229.34515-1-pkshih@realtek.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: RTEXMBS02.realtek.com.tw (172.21.6.95) To RTEXMBS04.realtek.com.tw (172.21.6.97) From: Po-Hao Huang Reference the current quota mode to avoid misleading warnings. This patch is required after supporting DBCC quota mode. Signed-off-by: Po-Hao Huang Signed-off-by: Ping-Ke Shih --- drivers/net/wireless/realtek/rtw89/mac.c | 3 +-- drivers/net/wireless/realtek/rtw89/mac_be.c | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/net/wireless/realtek/rtw89/mac.c b/drivers/net/wireless/realtek/rtw89/mac.c index 33cc2ce4bb74..917bbc482560 100644 --- a/drivers/net/wireless/realtek/rtw89/mac.c +++ b/drivers/net/wireless/realtek/rtw89/mac.c @@ -5221,8 +5221,7 @@ bool rtw89_mac_get_txpwr_cr_ax(struct rtw89_dev *rtwdev, enum rtw89_phy_idx phy_idx, u32 reg_base, u32 *cr) { - const struct rtw89_dle_mem *dle_mem = rtwdev->chip->dle_mem; - enum rtw89_qta_mode mode = dle_mem->mode; + enum rtw89_qta_mode mode = rtwdev->mac.qta_mode; u32 addr = rtw89_mac_reg_by_idx(rtwdev, reg_base, phy_idx); if (addr < R_AX_PWR_RATE_CTRL || addr > CMAC1_END_ADDR_AX) { diff --git a/drivers/net/wireless/realtek/rtw89/mac_be.c b/drivers/net/wireless/realtek/rtw89/mac_be.c index 6447353d35d3..320e88229971 100644 --- a/drivers/net/wireless/realtek/rtw89/mac_be.c +++ b/drivers/net/wireless/realtek/rtw89/mac_be.c @@ -1896,8 +1896,7 @@ static bool rtw89_mac_get_txpwr_cr_be(struct rtw89_dev *rtwdev, enum rtw89_phy_idx phy_idx, u32 reg_base, u32 *cr) { - const struct rtw89_dle_mem *dle_mem = rtwdev->chip->dle_mem; - enum rtw89_qta_mode mode = dle_mem->mode; + enum rtw89_qta_mode mode = rtwdev->mac.qta_mode; int ret; ret = rtw89_mac_check_mac_en(rtwdev, (enum rtw89_mac_idx)phy_idx, -- 2.25.1