X-Git-Url: http://pilppa.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=drivers%2Fvideo%2Fgxt4500.c;h=564557792bed6e616d590b8c49a1d28f3719f442;hb=2fca5ccf97d2c28bcfce44f5b07d85e74e3cd18e;hp=e92337bef50d00951bc4a7b9689f0d05b31a62ec;hpb=1212663fba7c5e003e05d24f043d5ed57eb18b24;p=linux-2.6-omap-h63xx.git 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) for (pdiv1 = 1; pdiv1 <= 8; ++pdiv1) { for (pdiv2 = 1; pdiv2 <= pdiv1; ++pdiv2) { postdiv = pdiv1 * pdiv2; - pll_period = (period_ps + postdiv - 1) / postdiv; + pll_period = DIV_ROUND_UP(period_ps, postdiv); /* keep pll in range 350..600 MHz */ if (pll_period < 1666 || pll_period > 2857) continue;