Lines Matching +full:vdd18 +full:- +full:supply
1 // SPDX-License-Identifier: GPL-2.0
82 "vdd18", "vdd3",
100 int num = rptr->cfg->num_vregs; in eusb2_repeater_init_vregs()
101 struct device *dev = rptr->dev; in eusb2_repeater_init_vregs()
104 rptr->vregs = devm_kcalloc(dev, num, sizeof(*rptr->vregs), GFP_KERNEL); in eusb2_repeater_init_vregs()
105 if (!rptr->vregs) in eusb2_repeater_init_vregs()
106 return -ENOMEM; in eusb2_repeater_init_vregs()
109 rptr->vregs[i].supply = rptr->cfg->vreg_list[i]; in eusb2_repeater_init_vregs()
111 return devm_regulator_bulk_get(dev, num, rptr->vregs); in eusb2_repeater_init_vregs()
117 struct device_node *np = rptr->dev->of_node; in eusb2_repeater_init()
118 struct regmap *regmap = rptr->regmap; in eusb2_repeater_init()
119 const u32 *init_tbl = rptr->cfg->init_tbl; in eusb2_repeater_init()
123 u32 base = rptr->base; in eusb2_repeater_init()
127 of_property_read_u8(np, "qcom,tune-usb2-amplitude", &tune_iusb2); in eusb2_repeater_init()
128 of_property_read_u8(np, "qcom,tune-usb2-disc-thres", &tune_hsdisc); in eusb2_repeater_init()
129 of_property_read_u8(np, "qcom,tune-usb2-preem", &tune_usb2_preem); in eusb2_repeater_init()
131 ret = regulator_bulk_enable(rptr->cfg->num_vregs, rptr->vregs); in eusb2_repeater_init()
153 dev_err(rptr->dev, "initialization timed-out\n"); in eusb2_repeater_init()
162 struct regmap *regmap = rptr->regmap; in eusb2_repeater_set_mode()
163 u32 base = rptr->base; in eusb2_repeater_set_mode()
180 * regulators (say host <-> device mode switch). in eusb2_repeater_set_mode()
186 return -EINVAL; in eusb2_repeater_set_mode()
196 return regulator_bulk_disable(rptr->cfg->num_vregs, rptr->vregs); in eusb2_repeater_exit()
209 struct device *dev = &pdev->dev; in eusb2_repeater_probe()
211 struct device_node *np = dev->of_node; in eusb2_repeater_probe()
217 return -ENOMEM; in eusb2_repeater_probe()
219 rptr->dev = dev; in eusb2_repeater_probe()
222 rptr->cfg = of_device_get_match_data(dev); in eusb2_repeater_probe()
223 if (!rptr->cfg) in eusb2_repeater_probe()
224 return -EINVAL; in eusb2_repeater_probe()
226 rptr->regmap = dev_get_regmap(dev->parent, NULL); in eusb2_repeater_probe()
227 if (!rptr->regmap) in eusb2_repeater_probe()
228 return -ENODEV; in eusb2_repeater_probe()
234 rptr->base = res; in eusb2_repeater_probe()
242 rptr->phy = devm_phy_create(dev, np, &eusb2_repeater_ops); in eusb2_repeater_probe()
243 if (IS_ERR(rptr->phy)) { in eusb2_repeater_probe()
245 return PTR_ERR(rptr->phy); in eusb2_repeater_probe()
248 phy_set_drvdata(rptr->phy, rptr); in eusb2_repeater_probe()
254 dev_info(dev, "Registered Qcom-eUSB2 repeater\n"); in eusb2_repeater_probe()
266 eusb2_repeater_exit(rptr->phy); in eusb2_repeater_remove()
271 .compatible = "qcom,pm8550b-eusb2-repeater",
282 .name = "qcom-eusb2-repeater",