diff options
-rw-r--r-- | bsd-core/drm_dma.c | 1 | ||||
-rw-r--r-- | bsd/drm_dma.h | 1 | ||||
-rw-r--r-- | libdrm/xf86drm.c | 1 | ||||
-rw-r--r-- | linux-core/drm_dma.c | 1 | ||||
-rw-r--r-- | linux/drm_dma.h | 1 |
5 files changed, 5 insertions, 0 deletions
diff --git a/bsd-core/drm_dma.c b/bsd-core/drm_dma.c index 69c66c9a..0f0dd4fd 100644 --- a/bsd-core/drm_dma.c +++ b/bsd-core/drm_dma.c @@ -619,6 +619,7 @@ int DRM(wait_vblank)( DRM_IOCTL_ARGS ) if (vblwait.request.type & _DRM_VBLANK_RELATIVE) { vblwait.request.sequence += atomic_read(&dev->vbl_received); + vblwait.request.type &= ~_DRM_VBLANK_RELATIVE; } flags = vblwait.request.type & _DRM_VBLANK_FLAGS_MASK; diff --git a/bsd/drm_dma.h b/bsd/drm_dma.h index 69c66c9a..0f0dd4fd 100644 --- a/bsd/drm_dma.h +++ b/bsd/drm_dma.h @@ -619,6 +619,7 @@ int DRM(wait_vblank)( DRM_IOCTL_ARGS ) if (vblwait.request.type & _DRM_VBLANK_RELATIVE) { vblwait.request.sequence += atomic_read(&dev->vbl_received); + vblwait.request.type &= ~_DRM_VBLANK_RELATIVE; } flags = vblwait.request.type & _DRM_VBLANK_FLAGS_MASK; diff --git a/libdrm/xf86drm.c b/libdrm/xf86drm.c index 6c830664..d250365e 100644 --- a/libdrm/xf86drm.c +++ b/libdrm/xf86drm.c @@ -1105,6 +1105,7 @@ int drmWaitVBlank(int fd, drmVBlankPtr vbl) do { ret = ioctl(fd, DRM_IOCTL_WAIT_VBLANK, vbl); + vbl->request.type &= ~DRM_VBLANK_RELATIVE; } while (ret && errno == EINTR); return ret; diff --git a/linux-core/drm_dma.c b/linux-core/drm_dma.c index 33af34be..df4ed809 100644 --- a/linux-core/drm_dma.c +++ b/linux-core/drm_dma.c @@ -628,6 +628,7 @@ int DRM(wait_vblank)( DRM_IOCTL_ARGS ) switch ( vblwait.request.type & ~_DRM_VBLANK_FLAGS_MASK ) { case _DRM_VBLANK_RELATIVE: vblwait.request.sequence += atomic_read( &dev->vbl_received ); + vblwait.request.type &= ~_DRM_VBLANK_RELATIVE; case _DRM_VBLANK_ABSOLUTE: break; default: diff --git a/linux/drm_dma.h b/linux/drm_dma.h index 33af34be..df4ed809 100644 --- a/linux/drm_dma.h +++ b/linux/drm_dma.h @@ -628,6 +628,7 @@ int DRM(wait_vblank)( DRM_IOCTL_ARGS ) switch ( vblwait.request.type & ~_DRM_VBLANK_FLAGS_MASK ) { case _DRM_VBLANK_RELATIVE: vblwait.request.sequence += atomic_read( &dev->vbl_received ); + vblwait.request.type &= ~_DRM_VBLANK_RELATIVE; case _DRM_VBLANK_ABSOLUTE: break; default: |