Patch "interconnect: qcom: icc-rpmh: Add BCMs to commit list in pre_aggregate" has been added to the 5.10-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    interconnect: qcom: icc-rpmh: Add BCMs to commit list in pre_aggregate

to the 5.10-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     interconnect-qcom-icc-rpmh-add-bcms-to-commit-list-i.patch
and it can be found in the queue-5.10 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 36874ac60c095178afa0616db16ee70f61c61d11
Author: Mike Tipton <mdtipton@xxxxxxxxxxxxxx>
Date:   Wed Jul 21 10:54:32 2021 -0700

    interconnect: qcom: icc-rpmh: Add BCMs to commit list in pre_aggregate
    
    [ Upstream commit f84f5b6f72e68bbaeb850b58ac167e4a3a47532a ]
    
    We're only adding BCMs to the commit list in aggregate(), but there are
    cases where pre_aggregate() is called without subsequently calling
    aggregate(). In particular, in icc_sync_state() when a node with initial
    BW has zero requests. Since BCMs aren't added to the commit list in
    these cases, we don't actually send the zero BW request to HW. So the
    resources remain on unnecessarily.
    
    Add BCMs to the commit list in pre_aggregate() instead, which is always
    called even when there are no requests.
    
    Fixes: 976daac4a1c5 ("interconnect: qcom: Consolidate interconnect RPMh support")
    Signed-off-by: Mike Tipton <mdtipton@xxxxxxxxxxxxxx>
    Link: https://lore.kernel.org/r/20210721175432.2119-5-mdtipton@xxxxxxxxxxxxxx
    Signed-off-by: Georgi Djakov <djakov@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/interconnect/qcom/icc-rpmh.c b/drivers/interconnect/qcom/icc-rpmh.c
index f6fae64861ce..27cc5f03611c 100644
--- a/drivers/interconnect/qcom/icc-rpmh.c
+++ b/drivers/interconnect/qcom/icc-rpmh.c
@@ -20,13 +20,18 @@ void qcom_icc_pre_aggregate(struct icc_node *node)
 {
 	size_t i;
 	struct qcom_icc_node *qn;
+	struct qcom_icc_provider *qp;
 
 	qn = node->data;
+	qp = to_qcom_provider(node->provider);
 
 	for (i = 0; i < QCOM_ICC_NUM_BUCKETS; i++) {
 		qn->sum_avg[i] = 0;
 		qn->max_peak[i] = 0;
 	}
+
+	for (i = 0; i < qn->num_bcms; i++)
+		qcom_icc_bcm_voter_add(qp->voter, qn->bcms[i]);
 }
 EXPORT_SYMBOL_GPL(qcom_icc_pre_aggregate);
 
@@ -44,10 +49,8 @@ int qcom_icc_aggregate(struct icc_node *node, u32 tag, u32 avg_bw,
 {
 	size_t i;
 	struct qcom_icc_node *qn;
-	struct qcom_icc_provider *qp;
 
 	qn = node->data;
-	qp = to_qcom_provider(node->provider);
 
 	if (!tag)
 		tag = QCOM_ICC_TAG_ALWAYS;
@@ -67,9 +70,6 @@ int qcom_icc_aggregate(struct icc_node *node, u32 tag, u32 avg_bw,
 	*agg_avg += avg_bw;
 	*agg_peak = max_t(u32, *agg_peak, peak_bw);
 
-	for (i = 0; i < qn->num_bcms; i++)
-		qcom_icc_bcm_voter_add(qp->voter, qn->bcms[i]);
-
 	return 0;
 }
 EXPORT_SYMBOL_GPL(qcom_icc_aggregate);



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux