diff options
| author | Thomas Zimmermann <[email protected]> | 2020-01-23 13:59:23 +0000 |
|---|---|---|
| committer | Thomas Zimmermann <[email protected]> | 2020-02-13 12:08:13 +0000 |
| commit | f1e2b6371c12aec5e772e5fdedaa4455c20a787f (patch) | |
| tree | 10b7d59c36576348f8733c868377d87bddbdcc12 /drivers/gpu/drm/amd/amdgpu/dce_virtual.c | |
| parent | drm: Remove internal setup of struct drm_device.vblank_disable_immediate (diff) | |
| download | kernel-f1e2b6371c12aec5e772e5fdedaa4455c20a787f.tar.gz kernel-f1e2b6371c12aec5e772e5fdedaa4455c20a787f.zip | |
drm: Add get_scanout_position() to struct drm_crtc_helper_funcs
The new callback get_scanout_position() reads the current location
of the scanout process. The operation is currently located in struct
drm_driver, but really belongs to the CRTC. Drivers will be converted
in separate patches.
To help with the conversion, the timestamp calculation has been
moved from drm_calc_vbltimestamp_from_scanoutpos() to
drm_crtc_vblank_helper_get_vblank_timestamp_internal(). The helper
function supports the new and old interface of get_scanout_position().
drm_calc_vbltimestamp_from_scanoutpos() remains as a wrapper around
the new function.
Callback functions return the scanout position from the CRTC. The
legacy version of the interface receives the device and pipe index,
the modern version receives a pointer to the CRTC. We keep the
legacy version until all drivers have been converted.
v4:
* 80-character line fixes
v3:
* refactor drm_calc_vbltimestamp_from_scanoutpos() to minimize
code duplication
* define types for get_scanout_position() callbacks
v2:
* fix logical op in drm_calc_vbltimestamp_from_scanoutpos()
Signed-off-by: Thomas Zimmermann <[email protected]>
Tested-by: Yannick Fertré <[email protected]>
Reviewed-by: Ville Syrjälä <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/dce_virtual.c')
0 files changed, 0 insertions, 0 deletions
