diff options
Diffstat (limited to 'drivers/video/pxafb.c')
-rw-r--r-- | drivers/video/pxafb.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/video/pxafb.c b/drivers/video/pxafb.c index 815fbc8317fc..16e37a535d85 100644 --- a/drivers/video/pxafb.c +++ b/drivers/video/pxafb.c | |||
@@ -43,6 +43,7 @@ | |||
43 | #include <asm/io.h> | 43 | #include <asm/io.h> |
44 | #include <asm/irq.h> | 44 | #include <asm/irq.h> |
45 | #include <asm/uaccess.h> | 45 | #include <asm/uaccess.h> |
46 | #include <asm/div64.h> | ||
46 | #include <asm/arch/pxa-regs.h> | 47 | #include <asm/arch/pxa-regs.h> |
47 | #include <asm/arch/bitfield.h> | 48 | #include <asm/arch/bitfield.h> |
48 | #include <asm/arch/pxafb.h> | 49 | #include <asm/arch/pxafb.h> |
@@ -460,7 +461,7 @@ static inline unsigned int get_pcd(unsigned int pixclock) | |||
460 | * speeds */ | 461 | * speeds */ |
461 | 462 | ||
462 | pcd = (unsigned long long)get_lcdclk_frequency_10khz() * pixclock; | 463 | pcd = (unsigned long long)get_lcdclk_frequency_10khz() * pixclock; |
463 | pcd /= 100000000 * 2; | 464 | do_div(pcd, 100000000 * 2); |
464 | /* no need for this, since we should subtract 1 anyway. they cancel */ | 465 | /* no need for this, since we should subtract 1 anyway. they cancel */ |
465 | /* pcd += 1; */ /* make up for integer math truncations */ | 466 | /* pcd += 1; */ /* make up for integer math truncations */ |
466 | return (unsigned int)pcd; | 467 | return (unsigned int)pcd; |