aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/via/dvi.c
diff options
context:
space:
mode:
authorFlorian Tobias Schandinat <FlorianSchandinat@gmx.de>2011-03-11 00:04:01 +0000
committerFlorian Tobias Schandinat <FlorianSchandinat@gmx.de>2011-03-12 10:22:06 +0000
commitfd3cc69848b7e1873e5f12bbcdd572b20277ecf3 (patch)
tree05ce614d358d964f36b40d3dd148770c8c8b5a4b /drivers/video/via/dvi.c
parent97597a39778eefb628eb7734a18f32c7880ad0e0 (diff)
downloadkernel_samsung_smdk4412-fd3cc69848b7e1873e5f12bbcdd572b20277ecf3.zip
kernel_samsung_smdk4412-fd3cc69848b7e1873e5f12bbcdd572b20277ecf3.tar.gz
kernel_samsung_smdk4412-fd3cc69848b7e1873e5f12bbcdd572b20277ecf3.tar.bz2
viafb: remove duplicated clock storage
The clocks can be easily recalculated by the timing and refresh value. This brings us one step closer to removing VIAs modetable and use generic ones and being easier extensible. Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
Diffstat (limited to 'drivers/video/via/dvi.c')
-rw-r--r--drivers/video/via/dvi.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/video/via/dvi.c b/drivers/video/via/dvi.c
index 84e21b3..41ca198 100644
--- a/drivers/video/via/dvi.c
+++ b/drivers/video/via/dvi.c
@@ -195,7 +195,9 @@ void viafb_dvi_set_mode(struct VideoModeTable *mode, int mode_bpp,
struct crt_mode_table *pDviTiming;
unsigned long desirePixelClock, maxPixelClock;
pDviTiming = mode->crtc;
- desirePixelClock = pDviTiming->clk / 1000000;
+ desirePixelClock = pDviTiming->refresh_rate
+ * pDviTiming->crtc.hor_total * pDviTiming->crtc.ver_total
+ / 1000000;
maxPixelClock = (unsigned long)viaparinfo->
tmds_setting_info->max_pixel_clock;