On 17.06.2014 20:41, Christian König wrote: > Am 17.06.2014 12:12, schrieb Michel Dänzer: >> From: Michel Dänzer <michel.daenzer@xxxxxxx> >> >> This reverts commit 75f36d861957cb05b7889af24c8cd4a789398304. >> >> drm_vblank_get() is necessary to ensure the DRM vblank counter value is >> up to date in drm_send_vblank_event(). >> >> Seems to fix weston hangs waiting for page flips to complete. >> >> Signed-off-by: Michel Dänzer <michel.daenzer@xxxxxxx> > > Both patches are: Reviewed-by: Christian König <christian.koenig@xxxxxxx> Thank you. Looking into these issues has got me thinking about the use of the page flip interrupt: If the page flip interrupt arrives before the corresponding vertical blank interrupt, the DRM vblank counter will be lower than expected by 1 in drm_send_vblank_event(). I suspect this is the cause of (WW) RADEON(0): radeon_dri2_flip_event_handler: Pageflip completion event has impossible msc [x-1] < target_msc [x] messages in the X log file which have been popping up in bug reports lately. This also results in 0s being returned to the client for the MSC and timestamp of the swap completion, which could cause all kinds of bad behaviour. The easy way to avoid that would be to stop using the page flip interrupt for this again. Could there be another solution for the issues you addressed by using it? If not, another issue I encountered in 3.15 is that radeon_crtc_handle_flip() is called unconditionally when a page flip interrupt arrives. If the flip was already handled (presumably from the vertical blank interrupt), the BUG_ON() in drm_vblank_put() triggers a panic. This happened to me with weston. This is presumably not an issue in 3.16 because radeon_crtc_handle_flip() now bails early if radeon_crtc->flip_work == NULL. -- Earthling Michel Dänzer | http://www.amd.com Libre software enthusiast | Mesa and X developer _______________________________________________ dri-devel mailing list dri-devel@xxxxxxxxxxxxxxxxxxxxx http://lists.freedesktop.org/mailman/listinfo/dri-devel