Lines Matching refs:zpd
15 #define PCU_DM_CLKEN(zpd) ((zpd)->reg_offset[REG_CLKEN]) argument
16 #define PCU_DM_ISOEN(zpd) ((zpd)->reg_offset[REG_ISOEN]) argument
17 #define PCU_DM_RSTEN(zpd) ((zpd)->reg_offset[REG_RSTEN]) argument
18 #define PCU_DM_PWREN(zpd) ((zpd)->reg_offset[REG_PWREN]) argument
19 #define PCU_DM_ACK_SYNC(zpd) ((zpd)->reg_offset[REG_ACK_SYNC]) argument
25 struct zx2967_pm_domain *zpd = (struct zx2967_pm_domain *)domain; in zx2967_power_on() local
29 val = readl_relaxed(pcubase + PCU_DM_PWREN(zpd)); in zx2967_power_on()
30 if (zpd->polarity == PWREN) in zx2967_power_on()
31 val |= BIT(zpd->bit); in zx2967_power_on()
33 val &= ~BIT(zpd->bit); in zx2967_power_on()
34 writel_relaxed(val, pcubase + PCU_DM_PWREN(zpd)); in zx2967_power_on()
38 val = readl_relaxed(pcubase + PCU_DM_ACK_SYNC(zpd)) in zx2967_power_on()
39 & BIT(zpd->bit); in zx2967_power_on()
47 val = readl_relaxed(pcubase + PCU_DM_RSTEN(zpd)); in zx2967_power_on()
48 val |= BIT(zpd->bit); in zx2967_power_on()
49 writel_relaxed(val, pcubase + PCU_DM_RSTEN(zpd)); in zx2967_power_on()
52 val = readl_relaxed(pcubase + PCU_DM_ISOEN(zpd)); in zx2967_power_on()
53 val &= ~BIT(zpd->bit); in zx2967_power_on()
54 writel_relaxed(val, pcubase + PCU_DM_ISOEN(zpd)); in zx2967_power_on()
57 val = readl_relaxed(pcubase + PCU_DM_CLKEN(zpd)); in zx2967_power_on()
58 val |= BIT(zpd->bit); in zx2967_power_on()
59 writel_relaxed(val, pcubase + PCU_DM_CLKEN(zpd)); in zx2967_power_on()
69 struct zx2967_pm_domain *zpd = (struct zx2967_pm_domain *)domain; in zx2967_power_off() local
73 val = readl_relaxed(pcubase + PCU_DM_CLKEN(zpd)); in zx2967_power_off()
74 val &= ~BIT(zpd->bit); in zx2967_power_off()
75 writel_relaxed(val, pcubase + PCU_DM_CLKEN(zpd)); in zx2967_power_off()
78 val = readl_relaxed(pcubase + PCU_DM_ISOEN(zpd)); in zx2967_power_off()
79 val |= BIT(zpd->bit); in zx2967_power_off()
80 writel_relaxed(val, pcubase + PCU_DM_ISOEN(zpd)); in zx2967_power_off()
83 val = readl_relaxed(pcubase + PCU_DM_RSTEN(zpd)); in zx2967_power_off()
84 val &= ~BIT(zpd->bit); in zx2967_power_off()
85 writel_relaxed(val, pcubase + PCU_DM_RSTEN(zpd)); in zx2967_power_off()
88 val = readl_relaxed(pcubase + PCU_DM_PWREN(zpd)); in zx2967_power_off()
89 if (zpd->polarity == PWREN) in zx2967_power_off()
90 val &= ~BIT(zpd->bit); in zx2967_power_off()
92 val |= BIT(zpd->bit); in zx2967_power_off()
93 writel_relaxed(val, pcubase + PCU_DM_PWREN(zpd)); in zx2967_power_off()
97 val = readl_relaxed(pcubase + PCU_DM_ACK_SYNC(zpd)) in zx2967_power_off()
98 & BIT(zpd->bit); in zx2967_power_off()