mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-12 21:57:43 +00:00
usb: chipidea: core: change vbus-regulator as optional
Vbus regualtor is an optional regulator, for platforms, which doesn't have this regulator, it will get a dummy regulator and show warning message. Signed-off-by: Peter Chen <peter.chen@nxp.com>
This commit is contained in:
parent
93c2c7330a
commit
782c1c49f3
1 changed files with 1 additions and 1 deletions
|
@ -683,7 +683,7 @@ static int ci_get_platdata(struct device *dev,
|
|||
|
||||
if (platdata->dr_mode != USB_DR_MODE_PERIPHERAL) {
|
||||
/* Get the vbus regulator */
|
||||
platdata->reg_vbus = devm_regulator_get(dev, "vbus");
|
||||
platdata->reg_vbus = devm_regulator_get_optional(dev, "vbus");
|
||||
if (PTR_ERR(platdata->reg_vbus) == -EPROBE_DEFER) {
|
||||
return -EPROBE_DEFER;
|
||||
} else if (PTR_ERR(platdata->reg_vbus) == -ENODEV) {
|
||||
|
|
Loading…
Reference in a new issue