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/rs600.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/rs600.c')
-rw-r--r-- | drivers/gpu/drm/radeon/rs600.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/gpu/drm/radeon/rs600.c b/drivers/gpu/drm/radeon/rs600.c index 683652bea17c..9a85b1614c86 100644 --- a/drivers/gpu/drm/radeon/rs600.c +++ b/drivers/gpu/drm/radeon/rs600.c | |||
@@ -662,22 +662,22 @@ int rs600_irq_process(struct radeon_device *rdev) | |||
662 | } | 662 | } |
663 | /* Vertical blank interrupts */ | 663 | /* Vertical blank interrupts */ |
664 | if (G_007EDC_LB_D1_VBLANK_INTERRUPT(rdev->irq.stat_regs.r500.disp_int)) { | 664 | if (G_007EDC_LB_D1_VBLANK_INTERRUPT(rdev->irq.stat_regs.r500.disp_int)) { |
665 | if (rdev->irq.pflip[0]) | ||
666 | radeon_crtc_handle_flip(rdev, 0); | ||
667 | if (rdev->irq.crtc_vblank_int[0]) { | 665 | if (rdev->irq.crtc_vblank_int[0]) { |
668 | drm_handle_vblank(rdev->ddev, 0); | 666 | drm_handle_vblank(rdev->ddev, 0); |
669 | rdev->pm.vblank_sync = true; | 667 | rdev->pm.vblank_sync = true; |
670 | wake_up(&rdev->irq.vblank_queue); | 668 | wake_up(&rdev->irq.vblank_queue); |
671 | } | 669 | } |
670 | if (rdev->irq.pflip[0]) | ||
671 | radeon_crtc_handle_flip(rdev, 0); | ||
672 | } | 672 | } |
673 | if (G_007EDC_LB_D2_VBLANK_INTERRUPT(rdev->irq.stat_regs.r500.disp_int)) { | 673 | if (G_007EDC_LB_D2_VBLANK_INTERRUPT(rdev->irq.stat_regs.r500.disp_int)) { |
674 | if (rdev->irq.pflip[1]) | ||
675 | radeon_crtc_handle_flip(rdev, 1); | ||
676 | if (rdev->irq.crtc_vblank_int[1]) { | 674 | if (rdev->irq.crtc_vblank_int[1]) { |
677 | drm_handle_vblank(rdev->ddev, 1); | 675 | drm_handle_vblank(rdev->ddev, 1); |
678 | rdev->pm.vblank_sync = true; | 676 | rdev->pm.vblank_sync = true; |
679 | wake_up(&rdev->irq.vblank_queue); | 677 | wake_up(&rdev->irq.vblank_queue); |
680 | } | 678 | } |
679 | if (rdev->irq.pflip[1]) | ||
680 | radeon_crtc_handle_flip(rdev, 1); | ||
681 | } | 681 | } |
682 | if (G_007EDC_DC_HOT_PLUG_DETECT1_INTERRUPT(rdev->irq.stat_regs.r500.disp_int)) { | 682 | if (G_007EDC_DC_HOT_PLUG_DETECT1_INTERRUPT(rdev->irq.stat_regs.r500.disp_int)) { |
683 | queue_hotplug = true; | 683 | queue_hotplug = true; |