clk: remove redundant negative index check in of_clk_get_parent_name()

This if-block can be dropped because the of_parse_phandle_with_args()
in the following line returns -EINVAL for negative index.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
This commit is contained in:
Masahiro Yamada 2015-11-20 16:36:19 +09:00 committed by Stephen Boyd
parent 59fe66313a
commit c736c4e11e

View File

@ -3062,9 +3062,6 @@ const char *of_clk_get_parent_name(struct device_node *np, int index)
int count;
struct clk *clk;
if (index < 0)
return NULL;
rc = of_parse_phandle_with_args(np, "clocks", "#clock-cells", index,
&clkspec);
if (rc)