]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
clk: at91: fix check of clk_register() returned value
authorVladimir Zapolskiy <vz@mleia.com>
Mon, 7 Mar 2016 23:41:29 +0000 (01:41 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 8 Jun 2016 01:18:50 +0000 (18:18 -0700)
commit0f519544d9da48c5b64f708ee86dea161ee43885
tree3f4be3fb197cc0cad6829d9771d3c2d2adb818df
parent319e5751f330825a7b1e593a9ada36e6e8450448
clk: at91: fix check of clk_register() returned value

commit cb0ceaf77d93964a0d00477c79f4499123f6159c upstream.

The clk_register() function returns a valid pointer to struct clk or
ERR_PTR() error code, this makes a check for returned NULL value
useless and may lead to oops on error path.

Signed-off-by: Vladimir Zapolskiy <vz@mleia.com>
Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Fixes: bcc5fd49a0fd ("clk: at91: add a driver for the h32mx clock")
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/clk/at91/clk-h32mx.c