lkml.org 
[lkml]   [2020]   [Sep]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC 00/10] Add USB support for Hikey 970
On Fri, Sep 04, 2020 at 02:28:49PM +0200, Mauro Carvalho Chehab wrote:

> It sounds that the only power supply related to USB is for the USB
> hub (ldo17), with sounds unlikely to affect dwc3. Yet, just in case,
> I added a dirty hack at dwc3_probe:

> <snip>
> diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c
> index 25c686a752b0..e42be91fe6c2 100644
> --- a/drivers/usb/dwc3/core.c
> +++ b/drivers/usb/dwc3/core.c
> @@ -1491,6 +1491,11 @@ static int dwc3_probe(struct platform_device *pdev)
>
> }

> +struct regulator *reg;
> +reg = devm_regulator_get(dev, "ldo17");
> +ret = PTR_ERR_OR_ZERO(reg);
> +if (ret) return ret;

A regulator_get() is going to do absolutely nothing to the state of the
regulator, if you're trying to enable it you need to do regulator_enable()
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2020-09-04 14:36    [W:0.084 / U:0.052 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site