drm: Widen vblank count to 64-bits [v3]
authorKeith Packard <keithp@keithp.com>
Thu, 12 Oct 2017 18:57:49 +0000 (11:57 -0700)
committerDave Airlie <airlied@redhat.com>
Fri, 20 Oct 2017 21:23:24 +0000 (07:23 +1000)
commit570e86963a511c1b404e81c72d2c42169faf9324
tree141fe6301ce5ea32f2acdfc109bff15a5c615fc2
parent19f470b2e47ddde4ad51744c2e140b86524b1f5a
drm: Widen vblank count to 64-bits [v3]

This modifies the datatypes used by the vblank code to provide 64 bits
of vblank count.

The driver interfaces have been left using 32 bits of vblank count;
all of the code necessary to widen that value for the user API was
already included to handle devices returning fewer than 32-bits.

This will provide the necessary datatypes for the Vulkan API.

v2:

 * Re-write wait_vblank ioctl to ABSOLUTE sequence

    When an application uses the WAIT_VBLANK ioctl with RELATIVE
    or NEXTONMISS bits set, the target vblank interval is updated
    within the kernel. We need to write that target back to the
    ioctl buffer and update the flags bits so that if the wait is
    interrupted by a signal, when it is re-started, it will target
    precisely the same vblank count as before.

 * Leave driver API with 32-bit vblank count

v3:

 * Rebase on top of Arnd Bergmann's patch which had
   the switch to ktime_t parts.

[airlied: fix conflict with Ville vblank change].

Suggested-by: Michel Dänzer <michel@daenzer.net>
Suggested-by: Daniel Vetter <daniel@ffwll.ch>
Signed-off-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
(cherry picked from commit 2affbc16983e4fc90960bc7f70e7615f4228199b)
drivers/gpu/drm/drm_vblank.c
include/drm/drm_vblank.h