summaryrefslogtreecommitdiffstats
path: root/include/soc
diff options
context:
space:
mode:
authorDmitry Osipenko <digetx@gmail.com>2021-06-01 05:31:18 +0300
committerThierry Reding <treding@nvidia.com>2021-06-02 10:58:55 +0200
commit41bafa698ddd07533914f34aeb432e762ed0cd30 (patch)
tree2b5643b55937815d6f0dd85a8bcf7072992f0eef /include/soc
parentf880ee9e96887786dc21e9433ede1719bc3b2624 (diff)
downloadlinux-41bafa698ddd07533914f34aeb432e762ed0cd30.tar.bz2
soc/tegra: pmc: Add driver state syncing
Add driver state syncing that is invoked once all PMC consumers are attached and ready. The consumers are the power domain clients. The synchronization callback is invoked once all client drivers are probed, the driver core handles this for us. This callback informs PMC driver that all voltage votes are initialized by each PD client and it's safe to begin voltage scaling of the core power domain. Signed-off-by: Dmitry Osipenko <digetx@gmail.com> Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org> [treding@nvidia.com: squash DT backwards-compatibility patch] Signed-off-by: Thierry Reding <treding@nvidia.com>
Diffstat (limited to 'include/soc')
-rw-r--r--include/soc/tegra/pmc.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/soc/tegra/pmc.h b/include/soc/tegra/pmc.h
index 361cb64246f7..d186bccd125d 100644
--- a/include/soc/tegra/pmc.h
+++ b/include/soc/tegra/pmc.h
@@ -171,6 +171,8 @@ int tegra_io_rail_power_off(unsigned int id);
void tegra_pmc_set_suspend_mode(enum tegra_suspend_mode mode);
void tegra_pmc_enter_suspend_mode(enum tegra_suspend_mode mode);
+bool tegra_pmc_core_domain_state_synced(void);
+
#else
static inline int tegra_powergate_power_on(unsigned int id)
{
@@ -227,6 +229,11 @@ static inline void tegra_pmc_enter_suspend_mode(enum tegra_suspend_mode mode)
{
}
+static inline bool tegra_pmc_core_domain_state_synced(void)
+{
+ return false;
+}
+
#endif /* CONFIG_SOC_TEGRA_PMC */
#if defined(CONFIG_SOC_TEGRA_PMC) && defined(CONFIG_PM_SLEEP)