linux-arm-msm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rob Clark <robdclark-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
Cc: linux-arm-msm-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Liviu Dudau <liviu.dudau-5wv7dgnIgG8@public.gmane.org>,
	freedreno-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org,
	Brian Starkey <brian.starkey-5wv7dgnIgG8@public.gmane.org>,
	Rob Clark <robdclark-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Subject: [RFC 0/4] drm/msm/mdp5: writeback connector support
Date: Fri, 23 Feb 2018 08:17:50 -0500	[thread overview]
Message-ID: <20180223131758.18362-1-robdclark@gmail.com> (raw)

(Sorry, meant to send this earlier, but got distracted on other things)

The first two patches are Brian Starkey's earlier writeback-connector
patches, with very minor rebasing to drm-next/v4.16-rc1, plus one small
addition to add atomic_commit() vfunc to the connector helpers, so that
writeback jobs could be committed directly from the atomic helpers.

I've tested this on dragonboard 410c (apq8016), with a hacked up
kmscube[1] to use the output of writeback as src texture for the next
frame.  (Yes, I know this isn't a "real" userspace, but I needed some
test code.)

So far, I've only managed to get WB2, which is connected to LM3, to
work.  I think there should be a WB0 attached to LM0 (which is also
attached to the DSI INTF).  It isn't clear to me if this can be used at
the same time as DSI video mode output.  If that is possible, then we
could support attaching both DSI and WB encoder+connector to the same
CRTC and re-use all the same planes being used for scanout to flatten
the composited image to a single buffer.  This would be an obvious and
simple use-case for weston and drm-hwc, to reduce power/bandwidth when
the screen is not updating by flattening all layers into a single layer
for the next frame.  But my attempts at making this work just made the
hardware grumpy.

These patches apply on top of msm-next[2] (which contains a couple other
required fixes, in particular improved CTL START signal handling).  The
patches can also be found on the msm-next-writeback[3] branch.

[1] https://github.com/robclark/kmscube/commits/writeback
[2] https://cgit.freedesktop.org/~robclark/linux/log/?h=msm-next
[3] https://cgit.freedesktop.org/~robclark/linux/log/?h=msm-next-writeback

Brian Starkey (2):
  drm: Add writeback connector type
  drm: writeback: Add out-fences for writeback connectors

Rob Clark (2):
  drm/msm/mdp5: add config for writeback pipes
  drm/msm/mdp5: writeback support

 Documentation/gpu/drm-kms.rst             |   9 +
 drivers/gpu/drm/Makefile                  |   2 +-
 drivers/gpu/drm/drm_atomic.c              | 229 ++++++++++++++++++-
 drivers/gpu/drm/drm_atomic_helper.c       |  30 +++
 drivers/gpu/drm/drm_connector.c           |   4 +-
 drivers/gpu/drm/drm_writeback.c           | 362 +++++++++++++++++++++++++++++
 drivers/gpu/drm/msm/Makefile              |   1 +
 drivers/gpu/drm/msm/disp/mdp5/mdp5.xml.h  |   2 -
 drivers/gpu/drm/msm/disp/mdp5/mdp5_cfg.c  |  17 +-
 drivers/gpu/drm/msm/disp/mdp5/mdp5_cfg.h  |  11 +
 drivers/gpu/drm/msm/disp/mdp5/mdp5_crtc.c |  23 +-
 drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c  |  39 +++-
 drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.h  |   7 +-
 drivers/gpu/drm/msm/disp/mdp5/mdp5_wb.c   | 367 ++++++++++++++++++++++++++++++
 drivers/gpu/drm/msm/dsi/dsi_host.c        |   4 +-
 include/drm/drm_atomic.h                  |  11 +
 include/drm/drm_connector.h               |  13 ++
 include/drm/drm_mode_config.h             |  22 ++
 include/drm/drm_modeset_helper_vtables.h  |  11 +
 include/drm/drm_writeback.h               | 128 +++++++++++
 include/uapi/drm/drm_mode.h               |   1 +
 21 files changed, 1265 insertions(+), 28 deletions(-)
 create mode 100644 drivers/gpu/drm/drm_writeback.c
 create mode 100644 drivers/gpu/drm/msm/disp/mdp5/mdp5_wb.c
 create mode 100644 include/drm/drm_writeback.h

-- 
2.14.3

_______________________________________________
Freedreno mailing list
Freedreno@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/freedreno

             reply	other threads:[~2018-02-23 13:17 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-23 13:17 Rob Clark [this message]
     [not found] ` <20180223131758.18362-1-robdclark-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2018-02-23 13:17   ` [RFC 1/4] drm: Add writeback connector type Rob Clark
     [not found]     ` <20180223131758.18362-2-robdclark-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2018-02-23 14:00       ` Liviu Dudau
     [not found]         ` <20180223140018.GV9111-A/Nd4k6kWRHZROr8t4l/smS4ubULX0JqMm0uRHvK7Nw@public.gmane.org>
2018-02-23 14:24           ` Rob Clark
     [not found]             ` <CAF6AEGvEZ6Z3dSHk9keb9MeQO28epeMey1zwsY51=UUHUH7FZw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2018-02-23 14:27               ` Liviu Dudau
2018-02-23 15:59       ` Sean Paul
2018-02-23 16:21         ` Liviu Dudau
     [not found]           ` <20180223162104.GX9111-A/Nd4k6kWRHZROr8t4l/smS4ubULX0JqMm0uRHvK7Nw@public.gmane.org>
2018-02-23 16:39             ` Sean Paul
2018-02-23 16:52               ` Liviu Dudau
2018-02-23 16:25         ` Rob Clark
2018-02-23 16:43           ` Sean Paul
2018-02-23 16:48             ` Liviu Dudau
     [not found]               ` <20180223164858.GY9111-A/Nd4k6kWRHZROr8t4l/smS4ubULX0JqMm0uRHvK7Nw@public.gmane.org>
2018-02-23 17:04                 ` Sean Paul
2018-02-23 13:17   ` [RFC 2/4] drm: writeback: Add out-fences for writeback connectors Rob Clark
     [not found]     ` <20180223131758.18362-3-robdclark-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2018-02-23 16:14       ` Sean Paul
2018-02-23 13:17   ` [RFC 3/4] drm/msm/mdp5: add config for writeback pipes Rob Clark
2018-02-23 16:32     ` Sean Paul
2018-02-23 13:17   ` [RFC 4/4] drm/msm/mdp5: writeback support Rob Clark
     [not found]     ` <20180223131758.18362-5-robdclark-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2018-02-23 16:30       ` Sean Paul
2018-02-23 18:15         ` Rob Clark
     [not found]           ` <CAF6AEGvAQu6zVO8d75YJgDLtpHJFxU0JGw8S7SR7HGOfMNPHXg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2018-02-26 15:41             ` Sean Paul

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180223131758.18362-1-robdclark@gmail.com \
    --to=robdclark-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
    --cc=brian.starkey-5wv7dgnIgG8@public.gmane.org \
    --cc=dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    --cc=freedreno-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    --cc=linux-arm-msm-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=liviu.dudau-5wv7dgnIgG8@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).