diff options
author | Paul A. Clarke <pc@us.ibm.com> | 2007-08-10 16:00:49 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-08-11 18:47:40 -0400 |
commit | e798bd95b61918e653f3d28f9176237236f2d103 (patch) | |
tree | 139853ab30618fdab1b0329cfbc68b3d01d7e117 /drivers/video/matrox/g450_pll.c | |
parent | acb73865328bd6211a1452f39a4f660d26658918 (diff) |
matroxfb: rectify jitter (G450/G550)
This builds upon my previous attempts to resolve some jitter problems seen
with the Matrox G450 and G550 -based cards, including odd disparities observed
between x86 and Power -based machines in a somewhat less hackish way (removing
the hacked ifdefs).
Apparently, preference should be given to use the DVI PLL when frequencies
permit, the Standard PLL otherwise. The max pixel clock for the panellink
interface is extracted from the PInS information on the card and used as a
limit to determine which PLL to use.
Signed-off-by: Paul A. Clarke <pc@us.ibm.com>
Acked-by: Petr Vandrovec <petr@vandrovec.name>
Signed-off-by: Antonino Daplas <adaplas@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/video/matrox/g450_pll.c')
-rw-r--r-- | drivers/video/matrox/g450_pll.c | 23 |
1 files changed, 13 insertions, 10 deletions
diff --git a/drivers/video/matrox/g450_pll.c b/drivers/video/matrox/g450_pll.c index 7c76e079ca7d..d42346e7fdda 100644 --- a/drivers/video/matrox/g450_pll.c +++ b/drivers/video/matrox/g450_pll.c | |||
@@ -331,16 +331,19 @@ static int __g450_setclk(WPMINFO unsigned int fout, unsigned int pll, | |||
331 | tmp |= M1064_XPIXCLKCTRL_PLL_UP; | 331 | tmp |= M1064_XPIXCLKCTRL_PLL_UP; |
332 | } | 332 | } |
333 | matroxfb_DAC_out(PMINFO M1064_XPIXCLKCTRL, tmp); | 333 | matroxfb_DAC_out(PMINFO M1064_XPIXCLKCTRL, tmp); |
334 | #ifdef __powerpc__ | 334 | /* DVI PLL preferred for frequencies up to |
335 | /* This is necessary to avoid jitter on PowerPC | 335 | panel link max, standard PLL otherwise */ |
336 | * (OpenFirmware) systems, but apparently | 336 | if (fout >= MINFO->max_pixel_clock_panellink) |
337 | * introduces jitter, at least on a x86-64 | 337 | tmp = 0; |
338 | * using DVI. | 338 | else tmp = |
339 | * A simple workaround is disable for non-PPC. | 339 | M1064_XDVICLKCTRL_DVIDATAPATHSEL | |
340 | */ | 340 | M1064_XDVICLKCTRL_C1DVICLKSEL | |
341 | matroxfb_DAC_out(PMINFO M1064_XDVICLKCTRL, 0); | 341 | M1064_XDVICLKCTRL_C1DVICLKEN | |
342 | #endif /* __powerpc__ */ | 342 | M1064_XDVICLKCTRL_DVILOOPCTL | |
343 | matroxfb_DAC_out(PMINFO M1064_XPWRCTRL, xpwrctrl); | 343 | M1064_XDVICLKCTRL_P1LOOPBWDTCTL; |
344 | matroxfb_DAC_out(PMINFO M1064_XDVICLKCTRL,tmp); | ||
345 | matroxfb_DAC_out(PMINFO M1064_XPWRCTRL, | ||
346 | xpwrctrl); | ||
344 | 347 | ||
345 | matroxfb_DAC_unlock_irqrestore(flags); | 348 | matroxfb_DAC_unlock_irqrestore(flags); |
346 | } | 349 | } |