Linux ARM-MSM sub-architecture
 help / color / mirror / Atom feed
From: Konrad Dybcio <konrad.dybcio@linaro.org>
To: Stephan Gerhold <stephan@gerhold.net>
Cc: Andy Gross <agross@kernel.org>,
	Bjorn Andersson <andersson@kernel.org>,
	Georgi Djakov <djakov@kernel.org>,
	Marijn Suijten <marijn.suijten@somainline.org>,
	linux-arm-msm@vger.kernel.org, linux-pm@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/4] interconnect: qcom: icc-rpm: Add AB/IB calculations coefficients
Date: Wed, 26 Jul 2023 19:19:34 +0200	[thread overview]
Message-ID: <829c2da7-4f88-4669-a114-c80603ccd4e1@linaro.org> (raw)
In-Reply-To: <ZMFU-hFSOHLr3hFP@gerhold.net>

On 26.07.2023 19:16, Stephan Gerhold wrote:
> On Wed, Jul 26, 2023 at 06:25:43PM +0200, Konrad Dybcio wrote:
>> Presumably due to the hardware being so complex, some nodes (or busses)
>> have different (usually higher) requirements for bandwidth than what
>> the usual calculations would suggest.
>>
> 
> Weird. I just hope this was never abused to workaround other broken
> configuration. A nice round ib_percent = 200 has mostly the same effect as
> 
>   - Doubling the requested peek bandwidth in the consumer driver (perhaps
>     they were too lazy to fix the driver in downstream at some point)
>   - Halving the node buswidth
> 
> It's probably hard to say for sure...
As per usual..

[...]

>>  
>>  	/*
>> @@ -315,6 +317,12 @@ static void qcom_icc_bus_aggregate(struct icc_provider *provider, u64 *agg_clk_r
>>  			else
>>  				agg_avg_rate = qn->sum_avg[i];
>>  
>> +			percent = qp->ab_percent ? qp->ab_percent : 100;
>> +			agg_avg_rate = mult_frac(percent, agg_avg_rate, 100);
> 
> 			if (qp->ab_percent)
> 				agg_avg_rate = mult_frac(qp->ab_percent, agg_avg_rate, 100);
> 
> Would be likely more efficient (no calculation if unspecified) and not
> much harder to read.
Oh right!

> 
>> +
>> +			percent = qn->ib_percent ? qn->ib_percent : 100;
>> +			agg_peak_rate = mult_frac(percent, qn->max_peak[i], 100);
>> +
> 
> agg_peak_rate doesn't seem to be used anywhere else? 🤔
Whoooooops....

Konrad

  reply	other threads:[~2023-07-26 17:19 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-26 16:25 [PATCH 0/4] Fix up icc clock rate calculation on some platforms Konrad Dybcio
2023-07-26 16:25 ` [PATCH 1/4] interconnect: qcom: icc-rpm: Add AB/IB calculations coefficients Konrad Dybcio
2023-07-26 17:16   ` Stephan Gerhold
2023-07-26 17:19     ` Konrad Dybcio [this message]
2023-07-29  9:25   ` kernel test robot
2023-07-26 16:25 ` [PATCH 2/4] interconnect: qcom: qcm2290: Set AB coefficients Konrad Dybcio
2023-07-26 17:18   ` Stephan Gerhold
2023-07-26 17:20     ` Konrad Dybcio
2023-07-26 17:26       ` Stephan Gerhold
2023-07-26 17:46         ` Konrad Dybcio
2023-07-26 17:52           ` Konrad Dybcio
2023-07-26 16:25 ` [PATCH 3/4] interconnect: qcom: sdm660: Set AB/IB coefficients Konrad Dybcio
2023-07-26 16:25 ` [PATCH 4/4] interconnect: qcom: msm8996: " Konrad Dybcio

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=829c2da7-4f88-4669-a114-c80603ccd4e1@linaro.org \
    --to=konrad.dybcio@linaro.org \
    --cc=agross@kernel.org \
    --cc=andersson@kernel.org \
    --cc=djakov@kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=marijn.suijten@somainline.org \
    --cc=stephan@gerhold.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox