Lines Matching refs:pwrc
25 struct meson_secure_pwrc *pwrc; member
50 if (meson_sm_call(pwrc_domain->pwrc->fw, SM_A1_PWRC_GET, &is_off, in pwrc_secure_is_off()
63 if (meson_sm_call(pwrc_domain->pwrc->fw, SM_A1_PWRC_SET, NULL, in meson_secure_pwrc_off()
78 if (meson_sm_call(pwrc_domain->pwrc->fw, SM_A1_PWRC_SET, NULL, in meson_secure_pwrc_on()
139 struct meson_secure_pwrc *pwrc; in meson_secure_pwrc_probe() local
154 pwrc = devm_kzalloc(&pdev->dev, sizeof(*pwrc), GFP_KERNEL); in meson_secure_pwrc_probe()
155 if (!pwrc) { in meson_secure_pwrc_probe()
160 pwrc->fw = meson_sm_get(sm_np); in meson_secure_pwrc_probe()
162 if (!pwrc->fw) in meson_secure_pwrc_probe()
165 pwrc->xlate.domains = devm_kcalloc(&pdev->dev, match->count, in meson_secure_pwrc_probe()
166 sizeof(*pwrc->xlate.domains), in meson_secure_pwrc_probe()
168 if (!pwrc->xlate.domains) in meson_secure_pwrc_probe()
171 pwrc->domains = devm_kcalloc(&pdev->dev, match->count, in meson_secure_pwrc_probe()
172 sizeof(*pwrc->domains), GFP_KERNEL); in meson_secure_pwrc_probe()
173 if (!pwrc->domains) in meson_secure_pwrc_probe()
176 pwrc->xlate.num_domains = match->count; in meson_secure_pwrc_probe()
177 platform_set_drvdata(pdev, pwrc); in meson_secure_pwrc_probe()
180 struct meson_secure_pwrc_domain *dom = &pwrc->domains[i]; in meson_secure_pwrc_probe()
185 dom->pwrc = pwrc; in meson_secure_pwrc_probe()
194 pwrc->xlate.domains[i] = &dom->base; in meson_secure_pwrc_probe()
197 return of_genpd_add_provider_onecell(pdev->dev.of_node, &pwrc->xlate); in meson_secure_pwrc_probe()