Commit ba782893 authored by Roel Kluin's avatar Roel Kluin Committed by Linus Torvalds

drivers/video/omap/hwa742.c: div reaches max_clk_div

With for(div = 0; div < max_clk_div; div++) { ... } div reaches max_clk_div.
Signed-off-by: default avatarRoel Kluin <roel.kluin@gmail.com>
Cc: Joe Perches <joe@perches.com>
Acked-by: default avatarTrilok Soni <soni.trilok@gmail.com>
Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent afbb9d8d
......@@ -742,7 +742,7 @@ static int calc_extif_timings(unsigned long sysclk, int *extif_mem_div)
if (calc_reg_timing(sysclk, div) == 0)
break;
}
if (div > max_clk_div)
if (div >= max_clk_div)
goto err;
*extif_mem_div = div;
......@@ -752,7 +752,7 @@ static int calc_extif_timings(unsigned long sysclk, int *extif_mem_div)
break;
}
if (div > max_clk_div)
if (div >= max_clk_div)
goto err;
return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment