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] [day] [month] [year] [list]
Message-ID: <CAOh2x==aeT-DU+PoqzGRoe+RaL0K+sVFmSLKTqC_20BQ0QmtTw@mail.gmail.com>
Date:	Tue, 29 Oct 2013 19:16:12 +0530
From:	Viresh Kumar <viresh.kumar@...aro.org>
To:	Wei Yongjun <weiyj.lk@...il.com>
Cc:	Shiraz HASHIM <shiraz.hashim@...com>,
	Russell King <linux@....linux.org.uk>,
	yongjun_wei@...ndmicro.com.cn,
	"linux-arm-kernel@...ts.infradead.org" 
	<linux-arm-kernel@...ts.infradead.org>,
	spear-devel <spear-devel@...t.st.com>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] ARM: spear: fix return value check in spear_setup_of_timer()

On Tue, Oct 29, 2013 at 7:34 AM, Wei Yongjun <weiyj.lk@...il.com> wrote:
> From: Wei Yongjun <yongjun_wei@...ndmicro.com.cn>
>
> In case of error, the function clk_get_sys() returns ERR_PTR()
> and never returns NULL. The NULL test in the return value check
> should be replaced with IS_ERR().
>
> Signed-off-by: Wei Yongjun <yongjun_wei@...ndmicro.com.cn>
> ---
>  arch/arm/mach-spear/time.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/arm/mach-spear/time.c b/arch/arm/mach-spear/time.c
> index d449673..3263a34 100644
> --- a/arch/arm/mach-spear/time.c
> +++ b/arch/arm/mach-spear/time.c
> @@ -222,7 +222,7 @@ void __init spear_setup_of_timer(void)
>         }
>
>         gpt_clk = clk_get_sys("gpt0", NULL);
> -       if (!gpt_clk) {
> +       if (IS_ERR(gpt_clk)) {
>                 pr_err("%s:couldn't get clk for gpt\n", __func__);
>                 goto err_iomap;
>         }

Acked-by: Viresh Kumar <viresh.kumar@...aro.org>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ