Lines Matching refs:exynos
42 struct dwc3_exynos *exynos; in dwc3_exynos_probe() local
48 exynos = devm_kzalloc(dev, sizeof(*exynos), GFP_KERNEL); in dwc3_exynos_probe()
49 if (!exynos) in dwc3_exynos_probe()
53 exynos->dev = dev; in dwc3_exynos_probe()
54 exynos->num_clks = driver_data->num_clks; in dwc3_exynos_probe()
55 exynos->clk_names = (const char **)driver_data->clk_names; in dwc3_exynos_probe()
56 exynos->suspend_clk_idx = driver_data->suspend_clk_idx; in dwc3_exynos_probe()
58 platform_set_drvdata(pdev, exynos); in dwc3_exynos_probe()
60 for (i = 0; i < exynos->num_clks; i++) { in dwc3_exynos_probe()
61 exynos->clks[i] = devm_clk_get(dev, exynos->clk_names[i]); in dwc3_exynos_probe()
62 if (IS_ERR(exynos->clks[i])) { in dwc3_exynos_probe()
64 exynos->clk_names[i]); in dwc3_exynos_probe()
65 return PTR_ERR(exynos->clks[i]); in dwc3_exynos_probe()
69 for (i = 0; i < exynos->num_clks; i++) { in dwc3_exynos_probe()
70 ret = clk_prepare_enable(exynos->clks[i]); in dwc3_exynos_probe()
73 clk_disable_unprepare(exynos->clks[i]); in dwc3_exynos_probe()
78 if (exynos->suspend_clk_idx >= 0) in dwc3_exynos_probe()
79 clk_prepare_enable(exynos->clks[exynos->suspend_clk_idx]); in dwc3_exynos_probe()
81 exynos->vdd33 = devm_regulator_get(dev, "vdd33"); in dwc3_exynos_probe()
82 if (IS_ERR(exynos->vdd33)) { in dwc3_exynos_probe()
83 ret = PTR_ERR(exynos->vdd33); in dwc3_exynos_probe()
86 ret = regulator_enable(exynos->vdd33); in dwc3_exynos_probe()
92 exynos->vdd10 = devm_regulator_get(dev, "vdd10"); in dwc3_exynos_probe()
93 if (IS_ERR(exynos->vdd10)) { in dwc3_exynos_probe()
94 ret = PTR_ERR(exynos->vdd10); in dwc3_exynos_probe()
97 ret = regulator_enable(exynos->vdd10); in dwc3_exynos_probe()
118 regulator_disable(exynos->vdd10); in dwc3_exynos_probe()
120 regulator_disable(exynos->vdd33); in dwc3_exynos_probe()
122 for (i = exynos->num_clks - 1; i >= 0; i--) in dwc3_exynos_probe()
123 clk_disable_unprepare(exynos->clks[i]); in dwc3_exynos_probe()
125 if (exynos->suspend_clk_idx >= 0) in dwc3_exynos_probe()
126 clk_disable_unprepare(exynos->clks[exynos->suspend_clk_idx]); in dwc3_exynos_probe()
133 struct dwc3_exynos *exynos = platform_get_drvdata(pdev); in dwc3_exynos_remove() local
138 for (i = exynos->num_clks - 1; i >= 0; i--) in dwc3_exynos_remove()
139 clk_disable_unprepare(exynos->clks[i]); in dwc3_exynos_remove()
141 if (exynos->suspend_clk_idx >= 0) in dwc3_exynos_remove()
142 clk_disable_unprepare(exynos->clks[exynos->suspend_clk_idx]); in dwc3_exynos_remove()
144 regulator_disable(exynos->vdd33); in dwc3_exynos_remove()
145 regulator_disable(exynos->vdd10); in dwc3_exynos_remove()
201 struct dwc3_exynos *exynos = dev_get_drvdata(dev); in dwc3_exynos_suspend() local
204 for (i = exynos->num_clks - 1; i >= 0; i--) in dwc3_exynos_suspend()
205 clk_disable_unprepare(exynos->clks[i]); in dwc3_exynos_suspend()
207 regulator_disable(exynos->vdd33); in dwc3_exynos_suspend()
208 regulator_disable(exynos->vdd10); in dwc3_exynos_suspend()
215 struct dwc3_exynos *exynos = dev_get_drvdata(dev); in dwc3_exynos_resume() local
218 ret = regulator_enable(exynos->vdd33); in dwc3_exynos_resume()
223 ret = regulator_enable(exynos->vdd10); in dwc3_exynos_resume()
229 for (i = 0; i < exynos->num_clks; i++) { in dwc3_exynos_resume()
230 ret = clk_prepare_enable(exynos->clks[i]); in dwc3_exynos_resume()
233 clk_disable_unprepare(exynos->clks[i]); in dwc3_exynos_resume()