Lines Matching refs:domain

3  * ZynqMP Generic PM domain support
28 * @gpd: Generic power domain
29 * @node_id: PM node ID corresponding to device inside PM domain
30 * @requested: The PM node mapped to the PM domain has been requested
65 * zynqmp_gpd_power_on() - Power on PM domain
66 * @domain: Generic PM domain
68 * This function is called before devices inside a PM domain are resumed, to
69 * power on PM domain.
73 static int zynqmp_gpd_power_on(struct generic_pm_domain *domain)
75 struct zynqmp_pm_domain *pd = to_zynqmp_pm_domain(domain);
83 dev_err(&domain->dev,
89 dev_dbg(&domain->dev, "set requirement to 0x%x for PM node id %d\n",
96 * zynqmp_gpd_power_off() - Power off PM domain
97 * @domain: Generic PM domain
99 * This function is called after devices inside a PM domain are suspended, to
100 * power off PM domain.
104 static int zynqmp_gpd_power_off(struct generic_pm_domain *domain)
106 struct zynqmp_pm_domain *pd = to_zynqmp_pm_domain(domain);
112 /* If domain is already released there is nothing to be done */
114 dev_dbg(&domain->dev, "PM node id %d is already released\n",
119 list_for_each_entry_safe(pdd, tmp, &domain->dev_list, list_node) {
124 domain->name);
133 dev_err(&domain->dev,
139 dev_dbg(&domain->dev, "set requirement to 0x%x for PM node id %d\n",
146 * zynqmp_gpd_attach_dev() - Attach device to the PM domain
147 * @domain: Generic PM domain
152 static int zynqmp_gpd_attach_dev(struct generic_pm_domain *domain,
155 struct zynqmp_pm_domain *pd = to_zynqmp_pm_domain(domain);
159 link = device_link_add(dev, &domain->dev, DL_FLAG_SYNC_STATE_ONLY);
161 dev_dbg(&domain->dev, "failed to create device link for %s\n",
165 if (domain->device_count)
171 dev_err(&domain->dev, "%s request failed for node %d: %d\n",
172 domain->name, pd->node_id, ret);
178 dev_dbg(&domain->dev, "%s requested PM node id %d\n",
185 * zynqmp_gpd_detach_dev() - Detach device from the PM domain
186 * @domain: Generic PM domain
189 static void zynqmp_gpd_detach_dev(struct generic_pm_domain *domain,
192 struct zynqmp_pm_domain *pd = to_zynqmp_pm_domain(domain);
196 if (domain->device_count)
201 dev_err(&domain->dev, "failed to release PM node id %d: %d\n",
208 dev_dbg(&domain->dev, "%s released PM node id %d\n",
231 * Add index in empty node_id of power domain list as no existing
232 * power domain found for current index.
277 pd->gpd.name = kasprintf(GFP_KERNEL, "domain%d", i);