[RFC v2 0/7] drm: asynchronous atomic plane update

Ville Syrjälä ville.syrjala at linux.intel.com
Thu Apr 27 16:10:34 UTC 2017


On Thu, Apr 27, 2017 at 12:15:12PM -0300, Gustavo Padovan wrote:
> From: Gustavo Padovan <gustavo.padovan at collabora.com>
> 
> Hi,
> 
> Second take of Asynchronous Plane Updates over Atomic. Here I looked
> to msm, vc4 and i915 to identify a common pattern to create atomic helpers
> for async updates. So in patch 1 drm_atomic_async_check() and
> drm_atomic_helper_async_commit() are introduced along with driver's plane hooks:
> ->atomic_async_check() and ->atomic_async_commit().
> 
> For now we only support async update for one plane at a time. Also the async
> update can't modify the CRTC so no modesets are allowed.
> 
> Then the other patches add support for it in the drivers. I did virtio mostly
> for testing. i915 have been converted and I've been using it without any
> problem. IGT tests seems to be fine, but there are somewhat random failures
> with or without the async update changes. msm and vc4 are only compile-tested.
> So I think this needs more testing
> 
> I started IGT changes to test the Atomic IOCTL with the new flag:
> 
> https://git.collabora.com/cgit/user/padovan/intel-gpu-tools.git/
> 
> v2:
> 
> Apart from all comments on v1 one extra change I made was to remove the
> constraint of only updating the plane if the queued state didn't touch
> that plane. I believe it was a too cautious of a change, furthermore this
> constraint was affecting throughput negatively on i915.

So you're now allowing reordering the updates? As in update A is
scheduled before update B, but update B happens before update A.
That is not a good idea.

> 
> TODO
> 
>  - improve i-g-t tests where needed
>  - support async page flips (that can be done after uptreaming this part)
>  - figure out what to do for hw that do not update the plane until the next
>  vblank. Maybe wait and see what they do and them extract helpers?
> 
> Comments are welcome!
> 
> Gustavo Padovan (7):
>   drm/atomic: initial support for asynchronous plane update
>   drm/virtio: support async cursor updates
>   drm/i915: update cursors asynchronously through atomic
>   drm/i915: remove intel_cursor_plane_funcs
>   drm/msm: update cursors asynchronously through atomic
>   drm/msm: remove mdp5_cursor_plane_funcs
>   drm/vc4: update cursors asynchronously through atomic
> 
>  drivers/gpu/drm/drm_atomic.c              |  50 ++++++++++
>  drivers/gpu/drm/drm_atomic_helper.c       |  48 +++++++++
>  drivers/gpu/drm/i915/intel_atomic_plane.c |  52 ++++++++++
>  drivers/gpu/drm/i915/intel_display.c      | 158 ++++-------------------------
>  drivers/gpu/drm/msm/mdp/mdp5/mdp5_plane.c | 161 ++++++++++--------------------
>  drivers/gpu/drm/vc4/vc4_plane.c           |  94 +++++------------
>  drivers/gpu/drm/virtio/virtgpu_plane.c    |  42 ++++++++
>  include/drm/drm_atomic.h                  |   2 +
>  include/drm/drm_atomic_helper.h           |   2 +
>  include/drm/drm_modeset_helper_vtables.h  |  45 +++++++++
>  include/uapi/drm/drm_mode.h               |   4 +-
>  11 files changed, 343 insertions(+), 315 deletions(-)
> 
> -- 
> 2.9.3
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

-- 
Ville Syrjälä
Intel OTC


More information about the dri-devel mailing list