static int omap4_clkdm_del_wkup_sleep_dep(struct clockdomain *clkdm1, struct clockdomain *clkdm2) { omap4_cminst_clear_inst_reg_bits((1 << clkdm2->dep_bit), clkdm1->prcm_partition, clkdm1->cm_inst, clkdm1->clkdm_offs + OMAP4_CM_STATICDEP); return 0; }
static int omap4_clkdm_clear_all_wkup_sleep_deps(struct clockdomain *clkdm) { struct clkdm_dep *cd; u32 mask = 0; for (cd = clkdm->wkdep_srcs; cd && cd->clkdm_name; cd++) { if (!cd->clkdm) continue; mask |= 1 << cd->clkdm->dep_bit; atomic_set(&cd->wkdep_usecount, 0); } omap4_cminst_clear_inst_reg_bits(mask, clkdm->prcm_partition, clkdm->cm_inst, clkdm->clkdm_offs + OMAP4_CM_STATICDEP); return 0; }
static int omap4_clkdm_clear_all_wkup_sleep_deps(struct clockdomain *clkdm) { struct clkdm_dep *cd; u32 mask = 0; if (!clkdm->prcm_partition) return 0; for (cd = clkdm->wkdep_srcs; cd && cd->clkdm_name; cd++) { if (!cd->clkdm) continue; /* only happens if data is erroneous */ mask |= 1 << cd->clkdm->dep_bit; cd->wkdep_usecount = 0; } omap4_cminst_clear_inst_reg_bits(mask, clkdm->prcm_partition, clkdm->cm_inst, clkdm->clkdm_offs + OMAP4_CM_STATICDEP); return 0; }