summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/drm_irq.c
diff options
context:
space:
mode:
authorThierry Reding <treding@nvidia.com>2015-08-12 17:00:24 +0200
committerDaniel Vetter <daniel.vetter@ffwll.ch>2015-08-12 17:28:21 +0200
commit2a7d3d6d5ddbd202c09f228829cd03609a8efb23 (patch)
treeaae8b1d942c852754adcef166b3fc69ab4087500 /drivers/gpu/drm/drm_irq.c
parentb54a0935b03888c8412aa5acbf873af9d753fbdd (diff)
downloadop-kernel-dev-2a7d3d6d5ddbd202c09f228829cd03609a8efb23.zip
op-kernel-dev-2a7d3d6d5ddbd202c09f228829cd03609a8efb23.tar.gz
drm/irq: Remove negative CRTC index special-case
The drm_send_vblank_event() function treats negative CRTC indices as meaning that a driver doesn't have proper VBLANK handling. This is the only place where DRM needs negative CRTC indices, so in order to enable subsequent cleanup, remove this special case and replace it by the more obvious check for whether or not VBLANK support was initialized. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/drm_irq.c')
-rw-r--r--drivers/gpu/drm/drm_irq.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/drm_irq.c b/drivers/gpu/drm/drm_irq.c
index 9fd784b..120a16f 100644
--- a/drivers/gpu/drm/drm_irq.c
+++ b/drivers/gpu/drm/drm_irq.c
@@ -971,7 +971,7 @@ void drm_send_vblank_event(struct drm_device *dev, int crtc,
struct timeval now;
unsigned int seq;
- if (crtc >= 0) {
+ if (dev->num_crtcs > 0) {
seq = drm_vblank_count_and_time(dev, crtc, &now);
} else {
seq = 0;
OpenPOWER on IntegriCloud