Merge branch 'drm-next0420' of https://github.com/markyzq/kernel-drm-rockchip into...
[firefly-linux-kernel-4.4.55.git] / arch / arm / mach-rockchip / pm.h
index 7c889c04604b5ec0d9faaec30d0b612275c4cda4..03ff31d8282d07bd4fcd54dcde67b6ee7d7069ef 100644 (file)
@@ -50,6 +50,8 @@ static inline void rockchip_suspend_init(void)
 
 #define RK3288_SGRF_SOC_CON0           (0x0000)
 #define RK3288_SGRF_FAST_BOOT_ADDR     (0x0120)
+#define SGRF_PCLK_WDT_GATE             BIT(6)
+#define SGRF_PCLK_WDT_GATE_WRITE       BIT(22)
 #define SGRF_FAST_BOOT_EN              BIT(8)
 #define SGRF_FAST_BOOT_EN_WRITE                BIT(24)
 
@@ -63,6 +65,10 @@ static inline void rockchip_suspend_init(void)
 /* PMU_WAKEUP_CFG1 bits */
 #define PMU_ARMINT_WAKEUP_EN           BIT(0)
 
+/* wait 30ms for OSC stable and 30ms for pmic stable */
+#define OSC_STABL_CNT_THRESH   (32 * 30)
+#define PMU_STABL_CNT_THRESH   (32 * 30)
+
 enum rk3288_pwr_mode_con {
        PMU_PWR_MODE_EN = 0,
        PMU_CLK_CORE_SRC_GATE_EN,