diff options
author | Haojian Zhuang <haojian.zhuang@linaro.org> | 2013-10-23 13:06:29 +0800 |
---|---|---|
committer | Haojian Zhuang <haojian.zhuang@linaro.org> | 2013-10-23 13:06:29 +0800 |
commit | c1879341cbc8efb0ee605a2e4311728cceab7f95 (patch) | |
tree | b5ed8cf830d5cd42a20981e69fff6ef6265475d1 | |
parent | 5a5ad985de4558c3743629a4ce65b90c03a9e1a0 (diff) |
clk: hi3xxx: fix the count of clock dividertracking-hilt-clkdiv-1023
Since the last item is always <0, 0>, we should add 1 on the count
of the clock divider.
Signed-off-by: Haojian Zhuang <haojian.zhuang@linaro.org>
-rw-r--r-- | drivers/clk/hisilicon/clk-hi3xxx.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/clk/hisilicon/clk-hi3xxx.c b/drivers/clk/hisilicon/clk-hi3xxx.c index ade1297ee4b4..adaab5e5480a 100644 --- a/drivers/clk/hisilicon/clk-hi3xxx.c +++ b/drivers/clk/hisilicon/clk-hi3xxx.c @@ -528,7 +528,7 @@ void __init hi3620_clkdiv_setup(struct device_node *np) return; /*table ends with <0, 0>, so plus one to table_num*/ - table_num = max_div - min_div + 1; + table_num = max_div - min_div + 1 + 1; table = kzalloc(sizeof(struct clk_div_table) * table_num, GFP_KERNEL); if (!table) |