Bug 13944

Summary: nouveau video blitter gives tearing with two outputs
Product: xorg Reporter: Pierre Ossman <pierre-bugzilla>
Component: Driver/nouveauAssignee: Nouveau Project <nouveau>
Status: RESOLVED FIXED QA Contact: Xorg Project Team <xorg-team>
Severity: normal    
Priority: medium    
Version: 7.3 (2007.09)   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Pierre Ossman 2008-01-06 07:24:37 UTC
When I enable two outputs, the video blitter (not the texture adapter) slightly mis-syncs so that I have a single tear moving slowly over the screen. Things work fine as long as only a single output is enabled.
Comment 1 Pierre Ossman 2008-01-06 07:35:26 UTC
The problem is this part of NVWaitVSync():

	/* If crtc1 is active, this will produce one, otherwise zero */
	/* The assumption is that at least one is active */
	OUT_RING  (pNv->crtc_active[1]);

What happens is that it will wait for vsync on CRTC 1 if it's active, and CRTC 0 otherwise. I assume this was added because bad things happen if you wait for an inactive CRTC.

This is of course very incorrect in dual-head as it means it will always wait for CRTC 1. And the vsync of the two CRTCs are unlikely to occur at the same time.

To fix this, the NVWaitVSync() function needs to wait on the relevant CRTC. But pScrn seems to be card global, so I guess another parameter needs to be added. I'm not sure how the callers can determine it either though.
Comment 2 Arthur Huillet 2008-01-20 06:33:05 UTC
Closing, since your patch supposedly fixes it.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.