• Home
  • Raw
  • Download

Lines Matching full:ldo

44 	struct wm8994_ldo *ldo = rdev_get_drvdata(rdev);  in wm8994_ldo2_list_voltage()  local
49 switch (ldo->wm8994->type) { in wm8994_ldo2_list_voltage()
153 int id = pdev->id % ARRAY_SIZE(pdata->ldo); in wm8994_ldo_probe()
155 struct wm8994_ldo *ldo; in wm8994_ldo_probe() local
159 dev_dbg(&pdev->dev, "Probing LDO%d\n", id + 1); in wm8994_ldo_probe()
161 ldo = devm_kzalloc(&pdev->dev, sizeof(struct wm8994_ldo), GFP_KERNEL); in wm8994_ldo_probe()
162 if (!ldo) in wm8994_ldo_probe()
165 ldo->wm8994 = wm8994; in wm8994_ldo_probe()
166 ldo->supply = wm8994_ldo_consumer[id]; in wm8994_ldo_probe()
167 ldo->supply.dev_name = dev_name(wm8994->dev); in wm8994_ldo_probe()
170 config.driver_data = ldo; in wm8994_ldo_probe()
172 config.init_data = &ldo->init_data; in wm8994_ldo_probe()
175 * Look up LDO enable GPIO from the parent device node, we don't in wm8994_ldo_probe()
187 if (!pdata || !pdata->ldo[id].init_data || wm8994->dev->of_node) { in wm8994_ldo_probe()
189 ldo->supply.dev_name, ldo->supply.supply); in wm8994_ldo_probe()
191 ldo->init_data = wm8994_ldo_default[id]; in wm8994_ldo_probe()
192 ldo->init_data.consumer_supplies = &ldo->supply; in wm8994_ldo_probe()
194 ldo->init_data.constraints.valid_ops_mask = 0; in wm8994_ldo_probe()
196 ldo->init_data = *pdata->ldo[id].init_data; in wm8994_ldo_probe()
204 if (ldo->wm8994->type == WM8994) { in wm8994_ldo_probe()
205 ldo->regulator = devm_regulator_register(&pdev->dev, in wm8994_ldo_probe()
209 ldo->regulator = devm_regulator_register(&pdev->dev, in wm8994_ldo_probe()
214 if (IS_ERR(ldo->regulator)) { in wm8994_ldo_probe()
215 ret = PTR_ERR(ldo->regulator); in wm8994_ldo_probe()
216 dev_err(wm8994->dev, "Failed to register LDO%d: %d\n", in wm8994_ldo_probe()
221 platform_set_drvdata(pdev, ldo); in wm8994_ldo_probe()
229 .name = "wm8994-ldo",
237 MODULE_DESCRIPTION("WM8994 LDO driver");
239 MODULE_ALIAS("platform:wm8994-ldo");