Skip to content

Commit 9085b23

Browse files
quic-bjorandeGeorgi Djakov
authored andcommitted
interconnect: qcom: icc-rpm: Fix peak rate calculation
Per the commit message of commit 'dd014803f260 ("interconnect: qcom: icc-rpm: Add AB/IB calculations coefficients")', the peak rate should be 100/ib_percent. But, in what looks like a typical typo, the numerator value is discarded in the calculation. Update the implementation to match the described intention. Fixes: dd01480 ("interconnect: qcom: icc-rpm: Add AB/IB calculations coefficients") Cc: [email protected] Signed-off-by: Bjorn Andersson <[email protected]> Reviewed-by: Konrad Dybcio <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Georgi Djakov <[email protected]>
1 parent bfc7db1 commit 9085b23

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/interconnect/qcom/icc-rpm.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -307,7 +307,7 @@ static u64 qcom_icc_calc_rate(struct qcom_icc_provider *qp, struct qcom_icc_node
307307

308308
if (qn->ib_coeff) {
309309
agg_peak_rate = qn->max_peak[ctx] * 100;
310-
agg_peak_rate = div_u64(qn->max_peak[ctx], qn->ib_coeff);
310+
agg_peak_rate = div_u64(agg_peak_rate, qn->ib_coeff);
311311
} else {
312312
agg_peak_rate = qn->max_peak[ctx];
313313
}

0 commit comments

Comments
 (0)