Lines Matching full:pd

42  * @pd: generic_pm_domain for use with the genpd framework
49 struct generic_pm_domain pd; member
54 #define genpd_to_ti_sci_pd(gpd) container_of(gpd, struct ti_sci_pm_domain, pd)
65 struct ti_sci_pm_domain *pd = genpd_to_ti_sci_pd(genpd); in ti_sci_pd_set_lat_constraint() local
66 const struct ti_sci_handle *ti_sci = pd->parent->ti_sci; in ti_sci_pd_set_lat_constraint()
78 pd->idx, val); in ti_sci_pd_set_lat_constraint()
85 struct ti_sci_pm_domain *pd = genpd_to_ti_sci_pd(genpd); in ti_sci_pd_set_wkup_constraint() local
86 const struct ti_sci_handle *ti_sci = pd->parent->ti_sci; in ti_sci_pd_set_wkup_constraint()
99 ret = ti_sci->ops.pm_ops.set_device_constraint(ti_sci, pd->idx, in ti_sci_pd_set_wkup_constraint()
102 dev_dbg(dev, "ti_sci_pd: ID:%d set device constraint.\n", pd->idx); in ti_sci_pd_set_wkup_constraint()
112 struct ti_sci_pm_domain *pd = genpd_to_ti_sci_pd(domain); in ti_sci_pd_power_off() local
113 const struct ti_sci_handle *ti_sci = pd->parent->ti_sci; in ti_sci_pd_power_off()
115 return ti_sci->ops.dev_ops.put_device(ti_sci, pd->idx); in ti_sci_pd_power_off()
124 struct ti_sci_pm_domain *pd = genpd_to_ti_sci_pd(domain); in ti_sci_pd_power_on() local
125 const struct ti_sci_handle *ti_sci = pd->parent->ti_sci; in ti_sci_pd_power_on()
127 if (pd->exclusive) in ti_sci_pd_power_on()
129 pd->idx); in ti_sci_pd_power_on()
131 return ti_sci->ops.dev_ops.get_device(ti_sci, pd->idx); in ti_sci_pd_power_on()
193 struct ti_sci_pm_domain *pd; in ti_sci_pm_idx_exists() local
195 list_for_each_entry(pd, &pd_provider->pd_list, node) { in ti_sci_pm_idx_exists()
196 if (pd->idx == idx) in ti_sci_pm_idx_exists()
207 struct ti_sci_pm_domain *pd; in ti_sci_pm_domain_probe() local
244 pd = devm_kzalloc(dev, sizeof(*pd), GFP_KERNEL); in ti_sci_pm_domain_probe()
245 if (!pd) in ti_sci_pm_domain_probe()
248 pd->pd.name = devm_kasprintf(dev, GFP_KERNEL, in ti_sci_pm_domain_probe()
249 "pd:%d", in ti_sci_pm_domain_probe()
251 if (!pd->pd.name) in ti_sci_pm_domain_probe()
254 pd->pd.power_off = ti_sci_pd_power_off; in ti_sci_pm_domain_probe()
255 pd->pd.power_on = ti_sci_pd_power_on; in ti_sci_pm_domain_probe()
256 pd->pd.flags |= GENPD_FLAG_ACTIVE_WAKEUP; in ti_sci_pm_domain_probe()
257 pd->idx = args.args[0]; in ti_sci_pm_domain_probe()
258 pd->parent = pd_provider; in ti_sci_pm_domain_probe()
265 pd->pd.domain.ops.suspend = ti_sci_pd_suspend; in ti_sci_pm_domain_probe()
267 pm_genpd_init(&pd->pd, NULL, true); in ti_sci_pm_domain_probe()
269 list_add(&pd->node, &pd_provider->pd_list); in ti_sci_pm_domain_probe()
288 list_for_each_entry(pd, &pd_provider->pd_list, node) in ti_sci_pm_domain_probe()
289 pd_provider->data.domains[pd->idx] = &pd->pd; in ti_sci_pm_domain_probe()