disp: msm: sde: add qactive override

This change adds the hooks to enable the active signal override
in power collapse sequence. Active signal override is needed to
disable the clock gating when the power collapse sequence
is running.

Change-Id: I9edaed7960b236b3d0179cb67f9cc2c9b3546c9d
Signed-off-by: Abhijit Kulkarni <kabhijit@codeaurora.org>
This commit is contained in:
Abhijit Kulkarni
2020-01-08 20:20:28 -08:00
committed by Gerrit - the friendly Code Review server
parent ebb1a2799c
commit 748372a24c
5 changed files with 65 additions and 5 deletions

View File

@@ -1,6 +1,6 @@
// SPDX-License-Identifier: GPL-2.0-only
/*
* Copyright (c) 2018-2019, The Linux Foundation. All rights reserved.
* Copyright (c) 2018-2020, The Linux Foundation. All rights reserved.
*
*/
@@ -13,6 +13,7 @@
#define UIDLE_CTL 0x0
#define UIDLE_STATUS 0x4
#define UIDLE_FAL10_VETO_OVERRIDE 0x8
#define UIDLE_QACTIVE_HF_OVERRIDE 0xc
#define UIDLE_WD_TIMER_CTL 0x10
#define UIDLE_WD_TIMER_CTL2 0x14
@@ -177,6 +178,18 @@ void sde_hw_uidle_setup_ctl(struct sde_hw_uidle *uidle,
SDE_REG_WRITE(c, UIDLE_CTL, reg_val);
}
static void sde_hw_uilde_active_override(struct sde_hw_uidle *uidle,
bool enable)
{
struct sde_hw_blk_reg_map *c = &uidle->hw;
u32 reg_val = 0;
if (enable)
reg_val = BIT(0) | BIT(31);
SDE_REG_WRITE(c, UIDLE_QACTIVE_HF_OVERRIDE, reg_val);
}
static inline void _setup_uidle_ops(struct sde_hw_uidle_ops *ops,
unsigned long cap)
{
@@ -185,6 +198,8 @@ static inline void _setup_uidle_ops(struct sde_hw_uidle_ops *ops,
ops->uidle_setup_cntr = sde_hw_uidle_setup_cntr;
ops->uidle_get_cntr = sde_hw_uidle_get_cntr;
ops->uidle_get_status = sde_hw_uidle_get_status;
if (cap & BIT(SDE_UIDLE_QACTIVE_OVERRIDE))
ops->active_override_enable = sde_hw_uilde_active_override;
}
struct sde_hw_uidle *sde_hw_uidle_init(enum sde_uidle idx,