19 #include <linux/module.h>
21 #include <linux/slab.h>
44 #define tps65090_REG(_id) \
46 .id = TPS65090_ID_##_id, \
48 .name = tps65090_rails(_id), \
49 .id = TPS65090_ID_##_id, \
50 .ops = &tps65090_ops, \
51 .type = REGULATOR_VOLTAGE, \
52 .owner = THIS_MODULE, \
53 .enable_reg = (TPS65090_ID_##_id) + 12, \
54 .enable_mask = BIT(0), \
76 for (i = 0; i <
ARRAY_SIZE(TPS65090_regulator); i++) {
77 ri = &TPS65090_regulator[
i];
78 if (ri->
desc.id ==
id)
93 dev_dbg(&pdev->
dev,
"Probing regulator %d\n",
id);
95 ri = find_regulator_info(
id);
97 dev_err(&pdev->
dev,
"invalid regulator ID specified\n");
100 tps_pdata = pdev->
dev.platform_data;
110 dev_err(&pdev->
dev,
"failed to register regulator %s\n",
112 return PTR_ERR(rdev);
115 platform_set_drvdata(pdev, rdev);
129 .name =
"tps65090-regulator",
132 .probe = tps65090_regulator_probe,
136 static int __init tps65090_regulator_init(
void)
142 static void __exit tps65090_regulator_exit(
void)