Skip to content
Commit 9c632a63 authored by Dan Carpenter's avatar Dan Carpenter Committed by Stephen Boyd
Browse files

clk: clocking-wizard: Fix Oops in clk_wzrd_register_divider()



Smatch detected this potential error pointer dereference
clk_wzrd_register_divider().  If devm_clk_hw_register() fails then
it sets "hw" to an error pointer and then dereferences it on the
next line.  Return the error directly instead.

Fixes: 5a853722 ("staging: clocking-wizard: Add support for dynamic reconfiguration")
Signed-off-by: default avatarDan Carpenter <dan.carpenter@linaro.org>
Link: https://lore.kernel.org/r/f0e39b5c-4554-41e0-80d9-54ca3fabd060@kili.mountain


Reviewed-by: default avatarMichal Simek <michal.simek@amd.com>
Signed-off-by: default avatarStephen Boyd <sboyd@kernel.org>
parent da2edb3e
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment