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: <4742528.GXAFRqVoOG@jernej-laptop>
Date:   Sat, 27 Aug 2022 13:07:38 +0200
From:   Jernej Škrabec <jernej.skrabec@...il.com>
To:     linux-kernel@...r.kernel.org, linux-sunxi@...ts.linux.dev,
        linux-arm-kernel@...ts.infradead.org, linux-clk@...r.kernel.org,
        Yang Yingliang <yangyingliang@...wei.com>
Cc:     mturquette@...libre.com, sboyd@...nel.org, wens@...e.org
Subject: Re: [PATCH -next 3/3] clk: sunxi-ng: ccu-sun9i-a80-usb: Use dev_err_probe() helper

Dne sobota, 27. avgust 2022 ob 11:41:51 CEST je Yang Yingliang napisal(a):
> dev_err() can be replace with dev_err_probe() which will check if error
> code is -EPROBE_DEFER.
> 
> Signed-off-by: Yang Yingliang <yangyingliang@...wei.com>

Reviewed-by: Jernej Skrabec <jernej.skrabec@...il.com>

Best regards,
Jernej

> ---
>  drivers/clk/sunxi-ng/ccu-sun9i-a80-usb.c | 9 +++------
>  1 file changed, 3 insertions(+), 6 deletions(-)
> 
> diff --git a/drivers/clk/sunxi-ng/ccu-sun9i-a80-usb.c
> b/drivers/clk/sunxi-ng/ccu-sun9i-a80-usb.c index 575ae4ccc65f..a0fb0da8f356
> 100644
> --- a/drivers/clk/sunxi-ng/ccu-sun9i-a80-usb.c
> +++ b/drivers/clk/sunxi-ng/ccu-sun9i-a80-usb.c
> @@ -101,12 +101,9 @@ static int sun9i_a80_usb_clk_probe(struct
> platform_device *pdev) return PTR_ERR(reg);
> 
>  	bus_clk = devm_clk_get(&pdev->dev, "bus");
> -	if (IS_ERR(bus_clk)) {
> -		ret = PTR_ERR(bus_clk);
> -		if (ret != -EPROBE_DEFER)
> -			dev_err(&pdev->dev, "Couldn't get bus clk: 
%d\n", ret);
> -		return ret;
> -	}
> +	if (IS_ERR(bus_clk))
> +		return dev_err_probe(&pdev->dev, PTR_ERR(bus_clk),
> +				     "Couldn't get bus clk\n");
> 
>  	/* The bus clock needs to be enabled for us to access the 
registers */
>  	ret = clk_prepare_enable(bus_clk);




Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ