lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150127152047.GA13776@saruman.tx.rr.com>
Date:	Tue, 27 Jan 2015 09:20:47 -0600
From:	Felipe Balbi <balbi@...com>
To:	Soren Brinkmann <soren.brinkmann@...inx.com>
CC:	Andreas Färber <afaerber@...e.de>,
	Michal Simek <michal.simek@...inx.com>,
	<devicetree@...r.kernel.org>,
	Peter Crosthwaite <peter.crosthwaite@...inx.com>,
	Arnd Bergmann <arnd@...db.de>, <linux-kernel@...r.kernel.org>,
	<linux-arm-kernel@...ts.infradead.org>,
	Ola Jeppson <ola@...pteva.com>, <linux-gpio@...r.kernel.org>,
	<linux-usb@...r.kernel.org>, Felipe Balbi <balbi@...com>
Subject: Re: [PATCH] usb: phy-generic: Don't fail on missing gpio reset

On Mon, Jan 26, 2015 at 05:45:29PM -0800, Soren Brinkmann wrote:
> A reset through a GPIO is optional. Don't fail probing when it is
> missing.
> 
> Reported-by: Andreas Färber <afaerber@...e.de>
> Signed-off-by: Soren Brinkmann <soren.brinkmann@...inx.com>
> ---
> Hi Andreas,
> 
> does this do the trick?
> 
> 	Thanks,
> 	Sören
> 
>  drivers/usb/phy/phy-generic.c | 6 ++----
>  1 file changed, 2 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/usb/phy/phy-generic.c b/drivers/usb/phy/phy-generic.c
> index dd05254241fb..a73d4c738f0b 100644
> --- a/drivers/usb/phy/phy-generic.c
> +++ b/drivers/usb/phy/phy-generic.c
> @@ -241,10 +241,8 @@ int usb_phy_gen_create_phy(struct device *dev, struct usb_phy_generic *nop,
>  
>  	if (err == -EPROBE_DEFER)
>  		return -EPROBE_DEFER;
> -	if (err) {
> -		dev_err(dev, "Error requesting RESET GPIO\n");
> -		return err;
> -	}
> +	if (err)
> +		nop->gpiod_reset = NULL;

there's a better patch to use gpiod_get_optional(), instead.

-- 
balbi

Download attachment "signature.asc" of type "application/pgp-signature" (820 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ