interconnect: qcom: icc-rpmh: Add support for enabling BCMs needed for QoS

Some QoS blocks require voting for BCMs before their registers can be
accessed, since they require clocks and regulators controlled by BCM.
Hence add qos_proxy flag to indicate the BCM needs to be voted for
QoS configuration.

Change-Id: Idc618e7a3d28d31d38d85f5b21e6b9f12e86ebe2
Signed-off-by: Veera Vegivada <vvegivad@codeaurora.org>
This commit is contained in:
Veera Vegivada 2021-09-07 11:35:15 +05:30 committed by Mike Tipton
parent 487d9a368e
commit fd8e26e71e
2 changed files with 6 additions and 0 deletions

View File

@ -222,6 +222,9 @@ static bool bcm_needs_qos_proxy(struct qcom_icc_bcm *bcm)
{
int i;
if (bcm->qos_proxy)
return true;
if (bcm->voter_idx == 0)
for (i = 0; i < bcm->num_nodes; i++)
if (bcm->nodes[i]->qosbox)

View File

@ -99,6 +99,8 @@ struct qcom_icc_node {
* @perf_mode_mask: mask to OR with enable_mask when QCOM_ICC_TAG_PERF_MODE is set
* @dirty: flag used to indicate whether the bcm needs to be committed
* @keepalive: flag used to indicate whether a keepalive is required
* @qos_proxy: flag used to indicate whether a proxy vote needed as part of
* qos configuration
* @aux_data: auxiliary data used when calculating threshold values and
* communicating with RPMh
* @list: used to link to other bcms when compiling lists for commit
@ -117,6 +119,7 @@ struct qcom_icc_bcm {
u32 perf_mode_mask;
bool dirty;
bool keepalive;
bool qos_proxy;
struct bcm_db aux_data;
struct list_head list;
struct list_head ws_list;