Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp1664619iob; Thu, 19 May 2022 11:26:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwq0+9Wc/oIpa9eev/qf6aRZtqO6mvaXiTrd2e/cxaVMl20v0en2YGOMTUUy5wHQg0/wp9s X-Received: by 2002:a17:906:fa85:b0:6fe:a2b8:ed3d with SMTP id lt5-20020a170906fa8500b006fea2b8ed3dmr1283528ejb.440.1652984772821; Thu, 19 May 2022 11:26:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652984772; cv=none; d=google.com; s=arc-20160816; b=tHphwrnlXLnYmaeDlJD8bZWUtn3FLyRipdfz8P9UZNDwIhjZLSmoxq2T/ANb6ebk8X rFzFIKQNUfVNwp2jLDcWOoOIOxCZLC4ItxFjxZCsusm15u3Av5kXJoq5LkyM64A865Z2 Bh4qJvtmTJtOMaizm/2D8Bnr72T38A+3k1VTXRwkY+g8aAw1IzyiarFysUTKxMg4nkNV rmCcV8FTXW2YndY2zMF8+kmdT8/jfDjwYgm0jaUPcO06ltkIPoXQyuZq8O3vuwJgG/vh UlKZYS4+T2FR34mrjVCtunYqQHaHP0JPGrRdxPRG2vwDlAbfSplbgXPqpBSOS96zlysg HqMQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:date:cc:to:from:subject:message-id; bh=jm4GDANcPuMbgNILLZJATCx0uekHZhSorZbaRGhSTP4=; b=ISvctHj8VQiQ1Tf4VxerQuMjAHDEcO9a0oKX9f+5NhpyHv31o11tmeZgYnqbW5t8xN 2yGKBcUIYcL134Le/RdByB0R7AaKYqKxX6XYgZd02mhNLEc3Somrb+fjDkUcbN3kDPhj 5dQ2uWDxjH5QTHgx6wQYB7Gi1u95fm1zbIPqGqB9s6GJdlnljymPfD0tgsg+hMQBXlUU 7AKVTa7Yp4yALqxinUBy4UTGQsOPqqQbBFZOi4zDcEiDjPKdM/r0gqiU4FS6NnANLHDP BXba49D3eEwzTEhIO4z+Wn3U8W4fiyO+nKWAX9INlzoTUSNEYxAvhiFIxdyumZjciQ11 KrqQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=mediatek.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id nd41-20020a17090762a900b006f3b984a18asi6539171ejc.208.2022.05.19.11.25.47; Thu, 19 May 2022 11:26:12 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=mediatek.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240414AbiESQWS (ORCPT + 69 others); Thu, 19 May 2022 12:22:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52202 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232987AbiESQWQ (ORCPT ); Thu, 19 May 2022 12:22:16 -0400 Received: from mailgw02.mediatek.com (unknown [210.61.82.184]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9842EC1EE7 for ; Thu, 19 May 2022 09:22:11 -0700 (PDT) X-UUID: 4dd7ca02c51f46fdbd8903ef4d3ffce3-20220520 X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.5,REQID:e119717e-d9d0-47aa-975b-453033f9ba35,OB:0,LO B:0,IP:0,URL:5,TC:0,Content:0,EDM:0,RT:0,SF:0,FILE:0,RULE:Release_Ham,ACTI ON:release,TS:5 X-CID-META: VersionHash:2a19b09,CLOUDID:b0d3e379-5ef6-470b-96c9-bdb8ced32786,C OID:IGNORED,Recheck:0,SF:nil,TC:nil,Content:0,EDM:-3,IP:nil,URL:1,File:nil ,QS:0,BEC:nil X-UUID: 4dd7ca02c51f46fdbd8903ef4d3ffce3-20220520 Received: from mtkexhb02.mediatek.inc [(172.21.101.103)] by mailgw02.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-SHA384 256/256) with ESMTP id 658681106; Fri, 20 May 2022 00:22:06 +0800 Received: from MTKMBS07N2.mediatek.inc (172.21.101.141) by mtkmbs10n2.mediatek.inc (172.21.101.183) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.2.792.3; Fri, 20 May 2022 00:22:05 +0800 Received: from mtkcas11.mediatek.inc (172.21.101.40) by mtkmbs07n2.mediatek.inc (172.21.101.141) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Fri, 20 May 2022 00:22:05 +0800 Received: from mtksdccf07 (172.21.84.99) by mtkcas11.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Fri, 20 May 2022 00:22:05 +0800 Message-ID: Subject: Re: [PATCH 3/3] mt76: mt7921: introduce BIOS SAR config in tx power From: Deren Wu To: Felix Fietkau , Lorenzo Bianconi CC: Sean Wang , Soul Huang , YN Chen , Leon Yen , "Eric-SY Chang" , KM Lin , Robin Chiu , CH Yeh , Posh Sun , Eric Liang , Stella Chang , Evelyn Tsai , "Ryder Lee" , Shayne Chen , linux-wireless , linux-mediatek , Ming Yen Hsieh Date: Fri, 20 May 2022 00:22:05 +0800 In-Reply-To: <8207b98b-0c10-aff4-55c4-6c7118454832@nbd.name> References: <2e6b69a763d60897639101506e39a2b1a81d8eab.1652941276.git.deren.wu@mediatek.com> <8207b98b-0c10-aff4-55c4-6c7118454832@nbd.name> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.2 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-MTK: N X-Spam-Status: No, score=-0.9 required=5.0 tests=BAYES_00,MAY_BE_FORGED, SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE,T_SPF_TEMPERROR,UNPARSEABLE_RELAY autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Hi Felix, On Thu, 2022-05-19 at 17:33 +0200, Felix Fietkau wrote: > On 19.05.22 08:38, Deren Wu wrote: > > From: Deren Wu > > > > Add new function mt7921_set_tx_sar_pwr() to update SAR power from > > .set_sar_specs and BIOS setting. Both settings would be merged into > > mt76_freq_range_power for final tx power value. > > > > Reviewed-by: Sean Wang > > Co-developed-by: Ming Yen Hsieh > > Signed-off-by: Ming Yen Hsieh > > Signed-off-by: Deren Wu > > --- > > .../net/wireless/mediatek/mt76/mt7921/init.c | 3 +- > > .../net/wireless/mediatek/mt76/mt7921/main.c | 32 +++++++++++++- > > ----- > > .../wireless/mediatek/mt76/mt7921/mt7921.h | 2 ++ > > 3 files changed, 26 insertions(+), 11 deletions(-) > > > > diff --git a/drivers/net/wireless/mediatek/mt76/mt7921/main.c > > b/drivers/net/wireless/mediatek/mt76/mt7921/main.c > > index 80279f342109..c86d8805f291 100644 > > --- a/drivers/net/wireless/mediatek/mt76/mt7921/main.c > > +++ b/drivers/net/wireless/mediatek/mt76/mt7921/main.c > > @@ -1469,20 +1469,34 @@ static void mt7921_ipv6_addr_change(struct > > ieee80211_hw *hw, > > } > > #endif > > > > +int mt7921_set_tx_sar_pwr(struct ieee80211_hw *hw, > > + const struct cfg80211_sar_specs *sar) > > +{ > > + struct mt76_phy *mphy = hw->priv; > > + int err; > > + > > + if (sar) { > > + err = mt76_init_sar_power(hw, sar); > > + if (err) > > + return err; > > + } > > + > > + mt7921_init_bios_sar_power(mt7921_hw_phy(hw), !sar); > > + > > + err = mt76_connac_mcu_set_rate_txpower(mphy); > > + > > + return err; > > +} > > +EXPORT_SYMBOL_GPL(mt7921_set_tx_sar_pwr); > > Why is this exported? Thanks for pointing out. I will remove unnecessary export in next version. Regards, Deren > > - Felix > > _______________________________________________ > Linux-mediatek mailing list > Linux-mediatek@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-mediatek