Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp3747561yba; Mon, 29 Apr 2019 07:54:50 -0700 (PDT) X-Google-Smtp-Source: APXvYqwpJsUperejwr30TPJbeCKoi+pmpfXpg0mowNe0PpN9hQCE5Iw5gNtVET4+WKrA5OeVhtwS X-Received: by 2002:a17:902:bb0d:: with SMTP id l13mr12306394pls.141.1556549690608; Mon, 29 Apr 2019 07:54:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1556549690; cv=none; d=google.com; s=arc-20160816; b=XKISzGH7B7HrLFYXh/QZedxMNwcJT6NAADCf0+Ssm5guCZun2CNQeTZCVpwDYULtCS eDAVrScvVQNU50+cZwJapSQydrd5WBEw1YKqdSegffM3pic76a+wZkDPUEhZ8+PQnmOy X4ARwSPQMPxm7N4kXple0CckzGOlKYKi1sTgQqyUkwXVCObP06QrlwoMexuC11/5oP/w LRfTZs0ipVjVDR+5W8ppN/7XWXBG8EKdCy2TKm4PpaZix6rHnli74RyLgjHv913Zd+0o 9osVP4hB+PzP7L7euVjT+wYi0O2NhQ6tHzvbcxZGbYAfMtz2/r8nCs1kduM2U4+1M3Jb Yi3g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:date:message-id:user-agent:cc:to :references:in-reply-to:from:subject:content-transfer-encoding :mime-version:dmarc-filter:dkim-signature:dkim-signature; bh=9Z3UsekmrtiBZNj5O3sbiEtq3Q9UG3FiI8uODkPouUw=; b=iHhydY8EATKOwp/cqeDTNqh/zNuA8cXO2RK4OfV08LleAd2g8q4Nuk7tVfjb+SGVV7 QJDXGAFPRDwALOkN5xBkAQgUc1BpnCFCMTrwWMRCoxLPk2qfmKLfVQphGs5HRTYzgF2e KAmwafss67JYBRIZnDVegekdZVPdpAmCvmKMabBnC6c48s6afa84REE4ZYRMkIPblbBF qVtqmuJX/LK5ceIqSH+Fdr/rMVME5ylxTGNKvKEoO+oyFb9xaJ+bd4Jye703ud7NdoQD YXjSer2enjs//1Oe5TYKS96uOpdzsYF6vkmKiYMk25MM5rEizQcZRte/IwerYXUlCtI6 texw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=lNHdL2K2; dkim=pass header.i=@codeaurora.org header.s=default header.b=WDGu879V; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h22si32993785pfn.238.2019.04.29.07.54.35; Mon, 29 Apr 2019 07:54:50 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=lNHdL2K2; dkim=pass header.i=@codeaurora.org header.s=default header.b=WDGu879V; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728427AbfD2OyM (ORCPT + 99 others); Mon, 29 Apr 2019 10:54:12 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:47636 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728365AbfD2OyL (ORCPT ); Mon, 29 Apr 2019 10:54:11 -0400 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id B36C161157; Mon, 29 Apr 2019 14:54:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1556549650; bh=D3p73H9DBZZeHMrWmU118GN9gCpBzpMfZfYbHtTct/k=; h=Subject:From:In-Reply-To:References:To:Cc:Date:From; b=lNHdL2K2HsL06FoGMYtl1T7rTKe3IPTHAhqyNr1EA85wGR5Tz3uqRf5fGns/gwi+K SK8YjBOkhRraiMf/flbzUpRrgN7kxFp5F3LJ89TYCI3WNeEim72jh2oh9Qs5bqcp7y bd+V3/x7Cq8x5qIRmjaiECu0RrWfbjx2gxWioKWQ= X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=2.0 tests=ALL_TRUSTED,BAYES_00, DKIM_INVALID,DKIM_SIGNED,MISSING_DATE,MISSING_MID autolearn=no autolearn_force=no version=3.4.0 Received: from potku.adurom.net (88-114-240-156.elisa-laajakaista.fi [88.114.240.156]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: kvalo@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id C926260E7A; Mon, 29 Apr 2019 14:54:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1556549649; bh=D3p73H9DBZZeHMrWmU118GN9gCpBzpMfZfYbHtTct/k=; h=Subject:From:In-Reply-To:References:To:Cc:From; b=WDGu879VQ3q4PzxkWUN1xKNz8nnKi/tX/RysPzu9x0dXc6E3XSEJpEC2np1X2Z6Zq uK/rOP+lZGjpELux06a6lFmjm4cix4GWrVja0Lrgqq+UXx/v0t8NbaDSk6i5g+mEYZ 2YBpiRow7FUqG/C4OrVj72RwnnvByXU3OhM/yYQw= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org C926260E7A Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=kvalo@codeaurora.org Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: Re: [PATCH] ath9k: Differentiate between max combined and per chain power From: Kalle Valo In-Reply-To: <20190320103723.27228-1-sven@narfation.org> References: <20190320103723.27228-1-sven@narfation.org> To: Sven Eckelmann Cc: linux-wireless@vger.kernel.org, QCA ath9k Development , Sven Eckelmann User-Agent: pwcli/0.0.0-git (https://github.com/kvalo/pwcli/) Python/2.7.12 Message-Id: <20190429145410.B36C161157@smtp.codeaurora.org> Date: Mon, 29 Apr 2019 14:54:10 +0000 (UTC) Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Sven Eckelmann wrote: > The ath9k driver uses as maximum allowed txpower the constant > MAX_RATE_POWER. It is used to set a maximum txpower limit for the PHY > (which is combined txpower) and also the maximum txpower for per chain > rates. Its value 63 is derived from the maximum number the registers can > store for the per chain txpower. > > The max txpower a user can set because of this is 31 dBm (floor(63 / 2)). > This also means that a device with multiple tx chains is even limited > further: > > * 1 chain: 31 dBm per chain > * 2 chains: 28 dBm per chain > * 3 chains: 26 dBm per chain > > This combined txpower limit of 31 dBm becomes even more problematic when > some extra antenna gain is set in the EEPROM. A high power device is then > no longer able to reach its potential limits. > > Instead the code dealing with the combined txpower must use a higher limit > than 63 and only the code dealing with the per chain txpower have to use > the limit of 63. Since the antenna gain can be quite large and 8 bit > variables are often used in ath9k for txpower, a large, divisible by two > number like 254 is a good choice for this new limit. > > Signed-off-by: Sven Eckelmann > Signed-off-by: Kalle Valo Patch applied to ath-next branch of ath.git, thanks. b037b107565f ath9k: Differentiate between max combined and per chain power -- https://patchwork.kernel.org/patch/10861389/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches