-
- Downloads
drm/atomic: hook atomic_async_{check,update} with PAGE_FLIP_ASYNC flag
Add atomic_async_{check,update} hooks in drm_plane_helper_funcs.
These hooks are called when userspace requests asyncronous page flip in
the atomic api through the flag DRM_MODE_PAGE_FLIP_ASYNC.
Update those hooks in the drivers that implement async functions, except
for amdgpu who handles the flag in the normal path, and rockchip who
doesn't support async page flip.
Signed-off-by:
Helen Koike <helen.koike@collabora.com>
Series-changes: 4
- Fix drm_atomic_helper_async_amend_check to return -EOPNOTSUPP then
hooks are not provided
Commit-notes:
Hi,
This patch is an attempt to expose the implementation that already exist
for true async page flips updates through atomic api when the
DRM_MODE_PAGE_FLIP_ASYNC is used.
In this commit I'm re-introducing the atomic_async_{check,update} hooks.
I know it is a bit weird to remove them first and them re-add them, but
I did this in the last commit to avoid any state of inconsistency
between commits, as rockchip doesn't support async page flip and they were
being used as amend.
So I reverted to amend first and then re-introced async again
tied to the DRM_MODE_PAGE_FLIP_ASYNC flag (I also think this is easier
to read).
To use async, it is required to have
dev->mode_config.async_page_flip = true;
but I see that only amdgpu and vc4 have this, so this patch won't take
effect on mdp5.
Nouveau and radeon also have this flag, but they don't implement the
async hooks yet.
Please let me know what you think.
Thanks
Helen
END
Showing
- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c 5 additions, 0 deletionsdrivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
- drivers/gpu/drm/drm_atomic_helper.c 27 additions, 9 deletionsdrivers/gpu/drm/drm_atomic_helper.c
- drivers/gpu/drm/drm_atomic_uapi.c 2 additions, 1 deletiondrivers/gpu/drm/drm_atomic_uapi.c
- drivers/gpu/drm/msm/disp/mdp5/mdp5_plane.c 2 additions, 0 deletionsdrivers/gpu/drm/msm/disp/mdp5/mdp5_plane.c
- drivers/gpu/drm/rockchip/rockchip_drm_vop.c 4 additions, 0 deletionsdrivers/gpu/drm/rockchip/rockchip_drm_vop.c
- drivers/gpu/drm/vc4/vc4_plane.c 2 additions, 0 deletionsdrivers/gpu/drm/vc4/vc4_plane.c
- include/drm/drm_atomic.h 2 additions, 0 deletionsinclude/drm/drm_atomic.h
- include/drm/drm_atomic_helper.h 5 additions, 4 deletionsinclude/drm/drm_atomic_helper.h
- include/drm/drm_modeset_helper_vtables.h 37 additions, 0 deletionsinclude/drm/drm_modeset_helper_vtables.h
Loading
Please register or sign in to comment