diff options
author | Li Zhengyu <lizhengyu3@huawei.com> | 2022-05-09 17:21:02 +0800 |
---|---|---|
committer | Stephen Boyd <sboyd@kernel.org> | 2022-05-16 23:45:53 -0700 |
commit | b69b0adc71637d436883c5ed9bfadbfbb7e02fda (patch) | |
tree | a74f08301d1acc84cc03961a2f406aca71209dd7 /drivers/clk | |
parent | 14364fca21208d0954d594e1eccb4ad239881081 (diff) |
clk: fixed-rate: Remove redundant if statement
(np) is always true when (dev || !np) is false, so just remove
the check.
Signed-off-by: Li Zhengyu <lizhengyu3@huawei.com>
Link: https://lore.kernel.org/r/20220509092102.140520-1-lizhengyu3@huawei.com
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
Diffstat (limited to 'drivers/clk')
-rw-r--r-- | drivers/clk/clk-fixed-rate.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/clk/clk-fixed-rate.c b/drivers/clk/clk-fixed-rate.c index 45501637705c..ac68a6b40f0e 100644 --- a/drivers/clk/clk-fixed-rate.c +++ b/drivers/clk/clk-fixed-rate.c @@ -87,7 +87,7 @@ struct clk_hw *__clk_hw_register_fixed_rate(struct device *dev, hw = &fixed->hw; if (dev || !np) ret = clk_hw_register(dev, hw); - else if (np) + else ret = of_clk_hw_register(np, hw); if (ret) { kfree(fixed); |