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: <20181112151739.GI13311@localhost>
Date:   Mon, 12 Nov 2018 16:17:39 +0100
From:   Johan Hovold <johan@...nel.org>
To:     Nishad Kamdar <nishadkamdar@...il.com>
Cc:     Vaibhav Hiremath <hvaibhav.linux@...il.com>,
        Johan Hovold <johan@...nel.org>, Alex Elder <elder@...nel.org>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        greybus-dev@...ts.linaro.org, devel@...verdev.osuosl.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] staging: greybus: arche-apb-ctrl.c: Switch to the gpio
 descriptor interface

On Sun, Nov 11, 2018 at 11:14:14AM +0530, Nishad Kamdar wrote:
> Use the gpiod interface instead of the deprecated old non-descriptor
> interface.
> 
> Signed-off-by: Nishad Kamdar <nishadkamdar@...il.com>
> ---
>  drivers/staging/greybus/arche-apb-ctrl.c | 158 ++++++++++-------------
>  1 file changed, 65 insertions(+), 93 deletions(-)

> -	apb->pwrdn_gpio = of_get_named_gpio(np, "pwr-down-gpios", 0);
> -	if (apb->pwrdn_gpio < 0)
> -		dev_warn(dev, "failed to get power down gpio\n");
> +	apb->pwrdn = devm_gpiod_get(dev, "gb,pwr-down-gpios", GPIOD_OUT_LOW);
> +	if (IF_ERR(apb->pwrdn)) {

Looks like you didn't even compile test this one. :(

> +		ret = PTR_ERR(apb->pwrdn);
> +		dev_warn(dev, "Failed requesting power down GPIO: %d\n", ret);
> +		return ret;
> +	}

Johan

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ