LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH v2 0/5] dma-fence: Deadline awareness
@ 2021-08-07 18:37 Rob Clark
  2021-08-07 18:37 ` [PATCH v2 1/5] dma-fence: Add deadline awareness Rob Clark
                   ` (5 more replies)
  0 siblings, 6 replies; 15+ messages in thread
From: Rob Clark @ 2021-08-07 18:37 UTC (permalink / raw)
  To: dri-devel
  Cc: linux-arm-msm, freedreno, Daniel Vetter, Christian König,
	Rob Clark, Alex Deucher, Andrey Grodzovsky, Christian König,
	Gustavo Padovan, Jack Zhang, Lee Jones,
	moderated list:DMA BUFFER SHARING FRAMEWORK, open list,
	open list:DMA BUFFER SHARING FRAMEWORK, Luben Tuikov,
	Steven Price, Tian Tao

From: Rob Clark <robdclark@chromium.org>

Based on discussion from a previous series[1] to add a "boost" mechanism
when, for example, vblank deadlines are missed.  Instead of a boost
callback, this approach adds a way to set a deadline on the fence, by
which the waiter would like to see the fence signalled.

I've not yet had a chance to re-work the drm/msm part of this, but
wanted to send this out as an RFC in case I don't have a chance to
finish the drm/msm part this week.

Original description:

In some cases, like double-buffered rendering, missing vblanks can
trick the GPU into running at a lower frequence, when really we
want to be running at a higher frequency to not miss the vblanks
in the first place.

This is partially inspired by a trick i915 does, but implemented
via dma-fence for a couple of reasons:

1) To continue to be able to use the atomic helpers
2) To support cases where display and gpu are different drivers

[1] https://patchwork.freedesktop.org/series/90331/

v1: https://patchwork.freedesktop.org/series/93035/
v2: Move filtering out of later deadlines to fence implementation
    to avoid increasing the size of dma_fence

Rob Clark (5):
  dma-fence: Add deadline awareness
  drm/vblank: Add helper to get next vblank time
  drm/atomic-helper: Set fence deadline for vblank
  drm/scheduler: Add fence deadline support
  drm/msm: Add deadline based boost support

 drivers/dma-buf/dma-fence.c             | 20 +++++++
 drivers/gpu/drm/drm_atomic_helper.c     | 36 ++++++++++++
 drivers/gpu/drm/drm_vblank.c            | 31 ++++++++++
 drivers/gpu/drm/msm/msm_fence.c         | 76 +++++++++++++++++++++++++
 drivers/gpu/drm/msm/msm_fence.h         | 20 +++++++
 drivers/gpu/drm/msm/msm_gpu.h           |  1 +
 drivers/gpu/drm/msm/msm_gpu_devfreq.c   | 20 +++++++
 drivers/gpu/drm/scheduler/sched_fence.c | 25 ++++++++
 drivers/gpu/drm/scheduler/sched_main.c  |  3 +
 include/drm/drm_vblank.h                |  1 +
 include/drm/gpu_scheduler.h             |  6 ++
 include/linux/dma-fence.h               | 16 ++++++
 12 files changed, 255 insertions(+)

-- 
2.31.1


^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2021-08-17  9:04 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-07 18:37 [PATCH v2 0/5] dma-fence: Deadline awareness Rob Clark
2021-08-07 18:37 ` [PATCH v2 1/5] dma-fence: Add deadline awareness Rob Clark
2021-08-16 10:15   ` Christian König
2021-08-07 18:37 ` [PATCH v2 2/5] drm/vblank: Add helper to get next vblank time Rob Clark
2021-08-07 18:37 ` [PATCH v2 3/5] drm/atomic-helper: Set fence deadline for vblank Rob Clark
2021-08-16 15:35   ` Daniel Vetter
2021-08-07 18:37 ` [PATCH v2 4/5] drm/scheduler: Add fence deadline support Rob Clark
2021-08-16 10:14   ` Christian König
2021-08-16 15:38     ` Daniel Vetter
2021-08-16 22:25       ` Rob Clark
2021-08-17  9:04         ` Daniel Vetter
2021-08-07 18:37 ` [PATCH v2 5/5] drm/msm: Add deadline based boost support Rob Clark
2021-08-16 10:16 ` [PATCH v2 0/5] dma-fence: Deadline awareness Christian König
2021-08-16 22:29   ` Rob Clark
2021-08-17  9:00     ` Christian König

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).