diff options
author | Stephen Boyd <sboyd@codeaurora.org> | 2016-02-20 04:29:17 +0300 |
---|---|---|
committer | Stephen Boyd <sboyd@codeaurora.org> | 2016-02-27 03:01:32 +0300 |
commit | 8c1b1e54faed690261752afcba27c79ce4d3fa10 (patch) | |
tree | 075c60de1e8e0d9ce51833e3d9c64b34494483fb /drivers/clk/at91/clk-slow.c | |
parent | 929e7f3bc7b82fb3e72392dec6a1df334cff6313 (diff) | |
download | linux-8c1b1e54faed690261752afcba27c79ce4d3fa10.tar.xz |
clk: at91: Remove impossible checks for of_clk_get_parent_count()
These checks for < 0 are impossible now that
of_clk_get_parent_count() returns an unsigned int. Change the
checks for == 0 and update the type.
Cc: Boris Brezillon <boris.brezillon@free-electrons.com>
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Diffstat (limited to 'drivers/clk/at91/clk-slow.c')
-rw-r--r-- | drivers/clk/at91/clk-slow.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/clk/at91/clk-slow.c b/drivers/clk/at91/clk-slow.c index 6f99a530ead6..67b304726d06 100644 --- a/drivers/clk/at91/clk-slow.c +++ b/drivers/clk/at91/clk-slow.c @@ -366,11 +366,11 @@ void __init of_at91sam9x5_clk_slow_setup(struct device_node *np, { struct clk *clk; const char *parent_names[2]; - int num_parents; + unsigned int num_parents; const char *name = np->name; num_parents = of_clk_get_parent_count(np); - if (num_parents <= 0 || num_parents > 2) + if (num_parents == 0 || num_parents > 2) return; of_clk_parent_fill(np, parent_names, num_parents); @@ -437,7 +437,7 @@ void __init of_at91sam9260_clk_slow_setup(struct device_node *np, { struct clk *clk; const char *parent_names[2]; - int num_parents; + unsigned int num_parents; const char *name = np->name; num_parents = of_clk_get_parent_count(np); |