diff options
Diffstat (limited to 'drivers/video/gxt4500.c')
-rw-r--r-- | drivers/video/gxt4500.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/video/gxt4500.c b/drivers/video/gxt4500.c index e92337bef50..564557792be 100644 --- a/drivers/video/gxt4500.c +++ b/drivers/video/gxt4500.c | |||
@@ -238,7 +238,7 @@ static int calc_pll(int period_ps, struct gxt4500_par *par) | |||
238 | for (pdiv1 = 1; pdiv1 <= 8; ++pdiv1) { | 238 | for (pdiv1 = 1; pdiv1 <= 8; ++pdiv1) { |
239 | for (pdiv2 = 1; pdiv2 <= pdiv1; ++pdiv2) { | 239 | for (pdiv2 = 1; pdiv2 <= pdiv1; ++pdiv2) { |
240 | postdiv = pdiv1 * pdiv2; | 240 | postdiv = pdiv1 * pdiv2; |
241 | pll_period = (period_ps + postdiv - 1) / postdiv; | 241 | pll_period = DIV_ROUND_UP(period_ps, postdiv); |
242 | /* keep pll in range 350..600 MHz */ | 242 | /* keep pll in range 350..600 MHz */ |
243 | if (pll_period < 1666 || pll_period > 2857) | 243 | if (pll_period < 1666 || pll_period > 2857) |
244 | continue; | 244 | continue; |