diff options
author | Thomas Zimmermann <tzimmermann@suse.de> | 2020-01-23 14:59:24 +0100 |
---|---|---|
committer | Thomas Zimmermann <tzimmermann@suse.de> | 2020-02-13 13:08:13 +0100 |
commit | 7fe3f0d15aac6c98a97e6d7086f5a6b7bc4ccae4 (patch) | |
tree | ff005fcab13165c3859c8c4cdce19b181f666e26 /drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h | |
parent | drm: Add get_scanout_position() to struct drm_crtc_helper_funcs (diff) | |
download | linux-7fe3f0d15aac6c98a97e6d7086f5a6b7bc4ccae4.tar.xz linux-7fe3f0d15aac6c98a97e6d7086f5a6b7bc4ccae4.zip |
drm: Add get_vblank_timestamp() to struct drm_crtc_funcs
The callback get_vblank_timestamp() is currently located in struct
drm_driver, but really belongs into struct drm_crtc_funcs. Add an
equivalent there. Driver will be converted in separate patches.
The default implementation is drm_calc_vbltimestamp_from_scanoutpos().
The patch adds drm_crtc_vblank_helper_get_vblank_timestamp(), which is
an implementation for the CRTC callback.
v4:
* more readable code for setting high_prec (Ville, Jani)
v3:
* use refactored timestamp calculation to minimize duplicated code
* do more checks for crtc != NULL to support legacy drivers
v2:
* rename helper to drm_crtc_vblank_helper_get_vblank_timestamp()
* replace drm_calc_vbltimestamp_from_scanoutpos() with
drm_crtc_vblank_helper_get_vblank_timestamp() in docs
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200123135943.24140-4-tzimmermann@suse.de
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h')
0 files changed, 0 insertions, 0 deletions