diff options
author | Mario Kleiner <mario.kleiner@tuebingen.mpg.de> | 2010-11-21 10:59:02 -0500 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2010-11-21 20:51:27 -0500 |
commit | 3e4ea7421f45966c93c8cbe81569e8dc93a58b87 (patch) | |
tree | 9a27cb7455aeed88a1ccaa0ec6d234b606c480f6 /drivers/gpu/drm/radeon/r100.c | |
parent | 6f34be50bd1bdd2ff3c955940e033a80d05f248a (diff) |
drm/kms/radeon: Reorder vblank and pageflip interrupt handling.
In the vblank irq handler, calls to actual vblank handling,
or at least drm_handle_vblank(), need to happen before
calls to radeon_crtc_handle_flip().
Reason: The high precision pageflip timestamping
and some other pageflip optimizations will need the updated
vblank count and timestamps for the current vblank interval.
These are calculated in drm_handle_vblank(), therefore it
must go first.
Signed-off-by: Mario Kleiner <mario.kleiner@tuebingen.mpg.de>
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/r100.c')
-rw-r--r-- | drivers/gpu/drm/radeon/r100.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/gpu/drm/radeon/r100.c b/drivers/gpu/drm/radeon/r100.c index b2e29798a99d..2316f73db6c0 100644 --- a/drivers/gpu/drm/radeon/r100.c +++ b/drivers/gpu/drm/radeon/r100.c | |||
@@ -650,22 +650,22 @@ int r100_irq_process(struct radeon_device *rdev) | |||
650 | } | 650 | } |
651 | /* Vertical blank interrupts */ | 651 | /* Vertical blank interrupts */ |
652 | if (status & RADEON_CRTC_VBLANK_STAT) { | 652 | if (status & RADEON_CRTC_VBLANK_STAT) { |
653 | if (rdev->irq.pflip[0]) | ||
654 | radeon_crtc_handle_flip(rdev, 0); | ||
655 | if (rdev->irq.crtc_vblank_int[0]) { | 653 | if (rdev->irq.crtc_vblank_int[0]) { |
656 | drm_handle_vblank(rdev->ddev, 0); | 654 | drm_handle_vblank(rdev->ddev, 0); |
657 | rdev->pm.vblank_sync = true; | 655 | rdev->pm.vblank_sync = true; |
658 | wake_up(&rdev->irq.vblank_queue); | 656 | wake_up(&rdev->irq.vblank_queue); |
659 | } | 657 | } |
658 | if (rdev->irq.pflip[0]) | ||
659 | radeon_crtc_handle_flip(rdev, 0); | ||
660 | } | 660 | } |
661 | if (status & RADEON_CRTC2_VBLANK_STAT) { | 661 | if (status & RADEON_CRTC2_VBLANK_STAT) { |
662 | if (rdev->irq.pflip[1]) | ||
663 | radeon_crtc_handle_flip(rdev, 1); | ||
664 | if (rdev->irq.crtc_vblank_int[1]) { | 662 | if (rdev->irq.crtc_vblank_int[1]) { |
665 | drm_handle_vblank(rdev->ddev, 1); | 663 | drm_handle_vblank(rdev->ddev, 1); |
666 | rdev->pm.vblank_sync = true; | 664 | rdev->pm.vblank_sync = true; |
667 | wake_up(&rdev->irq.vblank_queue); | 665 | wake_up(&rdev->irq.vblank_queue); |
668 | } | 666 | } |
667 | if (rdev->irq.pflip[1]) | ||
668 | radeon_crtc_handle_flip(rdev, 1); | ||
669 | } | 669 | } |
670 | if (status & RADEON_FP_DETECT_STAT) { | 670 | if (status & RADEON_FP_DETECT_STAT) { |
671 | queue_hotplug = true; | 671 | queue_hotplug = true; |