All of lore.kernel.org
 help / color / mirror / Atom feed
From: Rob Clark <robdclark@gmail.com>
To: Sascha Hauer <s.hauer@pengutronix.de>
Cc: "Linux Fbdev development list" <linux-fbdev@vger.kernel.org>,
	"Benjamin Gaignard" <benjamin.gaignard@linaro.org>,
	"dri-devel@lists.freedesktop.org"
	<dri-devel@lists.freedesktop.org>,
	"Jesse Barnes" <jesse.barnes@intel.com>,
	"Laurent Pinchart" <laurent.pinchart@ideasonboard.com>,
	"Sebastien Guiriec" <s-guiriec@ti.com>,
	"Laurent Pinchart" <laurent.pinchart+renesas@ideasonboard.com>,
	"Tom Gall" <tom.gall@linaro.org>,
	"Ragesh Radhakrishnan" <Ragesh.R@linaro.org>,
	"Tomi Valkeinen" <tomi.valkeinen@ti.com>,
	"linux-media@vger.kernel.org" <linux-media@vger.kernel.org>,
	"Stephen Warren" <swarren@wwwdotorg.org>,
	"Mark Zhang" <markz@nvidia.com>,
	"Stéphane Marchesin" <stephane.marchesin@gmail.com>,
	"Alexandre Courbot" <acourbot@nvidia.com>,
	"Thomas Petazzoni" <thomas.petazzoni@free-electrons.com>,
	"Sunil Joshi" <joshi@samsung.com>,
	"Kyungmin Park" <kyungmin.park@samsung.com>
Subject: Re: [PATCH/RFC v3 00/19] Common Display Framework
Date: Wed, 21 Aug 2013 08:22:59 -0400	[thread overview]
Message-ID: <CAF6AEGuRXhzmopjmsWuQ5D6jDB1QOBvvKx-WXMYSc2qHcVn2fQ@mail.gmail.com> (raw)
In-Reply-To: <20130821070947.GM31036@pengutronix.de>

On Wed, Aug 21, 2013 at 3:09 AM, Sascha Hauer <s.hauer@pengutronix.de> wrote:
> On Tue, Aug 20, 2013 at 02:40:55PM -0400, Rob Clark wrote:
>> On Tue, Aug 20, 2013 at 11:24 AM, Laurent Pinchart
>> <laurent.pinchart@ideasonboard.com> wrote:
>> > Hi Rob,
>> >
>> >> Or maybe, put another way, I still think we should still optimize for the
>> >> common case. I mean I'm sure you *can* design hw that has an LVDS->DP bridge
>> >> in the capture path, and if you had something like an FPGA where that was
>> >> cheap to do maybe you even would (for fun). But if in the real world, there
>> >> are only one or two cases of actual hw using the same bridge in a capture
>> >> pipeline which is normally used in display pipelines, then duplicating some
>> >> small bit of code for that abnormal case if it makes things easier for the
>> >> common case, seems like a reasonable trade-off to me.
>> >
>> > That was my opinion as well until I started working on a Xilinx platform.
>> > There's dozens of IP cores there that are used in both capture and display
>> > pipelines.
>>
>> or maybe just some helper lib's to handling the register level programming?
>>
>> Anyways, I guess you can call it a "worse is better" thing, but if you
>> can get 90% of the desired effect for 10% of the work, take the
>> simpler solution.  I don't think we should make things more layered or
>> more difficult for one exceptional case.
>>
>>
>> > Furthermore, FPGA display pipelines being made of individual IP cores, we need
>> > a way to write one driver per IP core and make them all interact. The recently
>> > proposed drm_bridge is one possible solution to this issue (and to a different
>> > but similar issue that trigerred the development of drm_bridge), but it's in
>> > my opinion not generic enough. We're facing several problems that are related,
>> > it would really be a shame not to solve them with a good enough framework.
>>
>> well, I've been working on DSI panel support in msm drm, and also been
>> looking at the patches to add DSI support in i915.  And the panel
>> interface ends up looking basically like the drm_bridge interface.
>> Perhaps the only thing not generic there is the name.
>>
>> >> I mean, take a DSI panel driver, for example.. anything but a trivial panel
>> >> driver, you are going to want to expose some custom properties on the
>> >> connector for controlling non-standard features. So you end up with both
>> >> cdf_foo for the common part, and drm_foo for gluing in the properties. And
>> >> now these two parts which otherwise would be one, end up having to stay in
>> >> sync merged through different trees, etc. It seems a lot like making my life
>> >> more difficult for a fairly hypothetical gain ;-)
>> >
>> > The DSI panel driver should not be split into two parts. It should implement a
>> > CDF entity, any glue needed for DRM will not be part of the panel driver.
>>
>> right, but that glue ends up needing to be *somewhere*, which makes it
>> the 2nd part.
>>
>> >> Or, take an hdmi or DP bridge. To use any of the common
>> >> infrastructure/helpers in drm, you end up implementing a generic interface,
>> >> where both the producer and consumer is inside drm. Which just seems a bit
>> >> pointless and extra hoops to jump through. Especially when we discover that
>> >> we need to extend/enhance the common interface outside of drm to make it
>> >> work. (I'm thinking of display_entity_control_ops::get_modes() here, but I'm
>> >> sure there are more examples.) And I think we'll run into similar issues
>> >> with display_entity_control_ops::set_state(), since the on<->off sequencing
>> >> can get hairy when the upstream/downstream entity is fed a clk by the
>> >> downstream/upstream entity. And similarly, I think we'll go through a few
>> >> revisions of DSI panel/bus params before we have everything that everyone
>> >> needs.
>> >
>> > I don't see where needing multiple revisions of a patch set would be bad :-)
>>
>> I mean over multiple kernel revisions, as people start adding support
>> for new hw and run into limitations of the "framework".
>
> A framework can be changed, extended and fixed. In the end we talking
> about a completely in-kernel framework for which we do not have to
> maintain a stable API.

oh sure, this is why I'd be absolutely against exposing this to
userspace currently..

But my only point here was that an in-drm framework, all the fix-ups
due to a framework change are sorted out before Dave sends his pull
req to linus.  We do this on a semi-regular basis already in drm
already.

Anyways, not a show-stopper thing.. just (in my mind) one additional
inconvenience (and not really the biggest one) about having the
"framework" outside of drm.  I'm more concerned about just having the
"display entity" code at a layer below the helpers and property api's
that I'd like to use in drm.

And just to be clear, part of my negative experience about this is the
omapdss/omapdrm split.  I just see cfd outside of drm as encouraging
others to make the same mistake.

>>
>> We've already figured out that just having enable() and disable() is
>> not sufficient for displayport link training.  I'm not sure what else
>> we'll discover.
>
> It's pretty much expected that other things will be discovered, but this
> will also happen with all sub-drm-driver frameworks we currently have.

right, which is why I want to "optimize" for this case by having
everything effected by evolving the framework merged via drm.

>>
>> I'm not saying not to solve (most of these) problems.. I don't think
>> chaining multiple drm_bridge's is impossible, I can think of at least
>> two ways to implement it.  But I think we should solve that as someone
>> is adding support for hw that uses this.  This (a) lets us break
>> things up into smaller more incremental changes (drm_bridge is
>> *considerably* smaller than the current CDF patchset), and (b) avoids
>> us solving the wrong problems.
>>
>> btw, I think DT bindings is orthogonal to this discussion.
>
> Not really. The common display framework is about splitting the pipeline
> into its components and adding a common view to the components. It's CDF
> helper code that can translate a DT binding directly into a encoder
> pipeline.

yes, DT binding are orthogonal.  This is something that should work
for BIOS, ACPI, DT, fex (just kidding), etc.  I mean there might be
some DT helpers, but that should be kind of on the side.

If DT binding are really to be OS independent, we probably need some
better way to deal w/ collecting up DT nodes for one (userspace
visible) driver (or cases where driver <-> DT is not 1<->1).  But that
is really an entirely different topic, or at least not applicable to
where the "framework" lives.

BR,
-R

> Sascha
>
>
> --
> Pengutronix e.K.                           |                             |
> Industrial Linux Solutions                 | http://www.pengutronix.de/  |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

  reply	other threads:[~2013-08-21 12:22 UTC|newest]

Thread overview: 83+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-09 17:14 [PATCH/RFC v3 00/19] Common Display Framework Laurent Pinchart
2013-08-09 17:14 ` [PATCH/RFC v3 01/19] OMAPDSS: panels: Rename Kconfig options to OMAP2_DISPLAY_* Laurent Pinchart
2013-08-09 17:14 ` [PATCH/RFC v3 02/19] video: Add Common Display Framework core Laurent Pinchart
2013-09-02  8:42   ` Tomi Valkeinen
2013-09-03 11:29     ` Laurent Pinchart
2013-08-09 17:14 ` [PATCH/RFC v3 03/19] video: display: Add video and stream control operations Laurent Pinchart
2013-08-09 17:14 ` [PATCH/RFC v3 04/19] video: display: Add display entity notifier Laurent Pinchart
2013-08-09 17:14 ` [PATCH/RFC v3 05/19] video: display: Graph helpers Laurent Pinchart
2013-08-09 17:14 ` [PATCH/RFC v3 06/19] video: display: OF support Laurent Pinchart
2013-08-13 14:37   ` Philipp Zabel
2013-08-21  1:02     ` Laurent Pinchart
2013-08-21  9:10       ` Philipp Zabel
2013-08-22  0:51         ` Laurent Pinchart
2013-08-09 17:14 ` [PATCH/RFC v3 07/19] video: display: Add pixel coding definitions Laurent Pinchart
2013-08-09 17:14 ` [PATCH/RFC v3 08/19] video: display: Add MIPI DBI bus support Laurent Pinchart
2013-08-14  0:52   ` Rob Clark
2013-08-20 13:26     ` Laurent Pinchart
2013-08-26 11:10   ` Tomi Valkeinen
2013-09-06 14:09     ` Laurent Pinchart
2013-09-06 15:43       ` Tomi Valkeinen
2013-09-07  9:35         ` Tomi Valkeinen
2013-09-04 10:50   ` Vikas Sajjan
2013-09-06 14:37     ` Laurent Pinchart
2013-09-18 10:59       ` Vikas Sajjan
2013-09-04 12:52   ` Vikas Sajjan
2013-09-06 14:56     ` Laurent Pinchart
2013-08-09 17:15 ` [PATCH/RFC v3 09/19] video: panel: Add DPI panel support Laurent Pinchart
2013-08-09 17:15 ` [PATCH/RFC v3 10/19] video: panel: Add R61505 " Laurent Pinchart
2013-08-09 17:15 ` [PATCH/RFC v3 11/19] video: panel: Add R61517 " Laurent Pinchart
2013-08-09 17:15 ` [PATCH/RFC v3 12/19] video: display: Add VGA Digital to Analog Converter support Laurent Pinchart
2013-08-09 17:15 ` [PATCH/RFC v3 13/19] video: display: Add VGA connector support Laurent Pinchart
2013-08-09 17:15 ` [PATCH/RFC v3 14/19] ARM: shmobile: r8a7790: Add DU clocks for DT Laurent Pinchart
2013-08-09 17:15 ` [PATCH/RFC v3 15/19] ARM: shmobile: r8a7790: Add DU device node to device tree Laurent Pinchart
2013-08-09 17:15 ` [PATCH/RFC v3 16/19] ARM: shmobile: marzen: Port DU platform data to CDF Laurent Pinchart
2013-08-09 17:15 ` [PATCH/RFC v3 17/19] ARM: shmobile: lager: " Laurent Pinchart
2013-08-09 17:15 ` [PATCH/RFC v3 18/19] ARM: shmobile: lager-reference: Add display device nodes to device tree Laurent Pinchart
2013-08-09 17:15 ` [PATCH/RFC v3 19/19] drm/rcar-du: Port to the Common Display Framework Laurent Pinchart
2013-08-14  0:43 ` [PATCH/RFC v3 00/19] " Rob Clark
2013-08-20 15:24   ` Laurent Pinchart
2013-08-20 18:40     ` Rob Clark
2013-08-21  7:09       ` Sascha Hauer
2013-08-21 12:22         ` Rob Clark [this message]
2013-09-06 16:16           ` Laurent Pinchart
2013-09-09 12:12           ` Tomi Valkeinen
2013-09-09 14:17             ` Rob Clark
2013-09-09 14:58               ` Tomi Valkeinen
2013-09-09 15:10                 ` Rob Clark
2013-09-02 11:06 ` Tomi Valkeinen
2013-09-30 13:48 ` Tomi Valkeinen
2013-10-02 12:23   ` Andrzej Hajda
2013-10-02 12:23     ` Andrzej Hajda
2013-10-02 13:24     ` Tomi Valkeinen
2013-10-02 13:24       ` Tomi Valkeinen
2013-10-02 13:24       ` Tomi Valkeinen
2013-10-09 14:08       ` Andrzej Hajda
2013-10-09 14:08         ` Andrzej Hajda
2013-10-11  6:37         ` Tomi Valkeinen
2013-10-11  6:37           ` Tomi Valkeinen
2013-10-11  6:37           ` Tomi Valkeinen
2013-10-11 11:19           ` Andrzej Hajda
2013-10-11 11:19             ` Andrzej Hajda
2013-10-11 12:30             ` Tomi Valkeinen
2013-10-11 12:30               ` Tomi Valkeinen
2013-10-11 12:30               ` Tomi Valkeinen
2013-10-11 14:16               ` Andrzej Hajda
2013-10-11 14:16                 ` Andrzej Hajda
2013-10-11 14:45                 ` Tomi Valkeinen
2013-10-11 14:45                   ` Tomi Valkeinen
2013-10-11 14:45                   ` Tomi Valkeinen
2013-10-17  7:48                   ` Andrzej Hajda
2013-10-17  7:48                     ` Andrzej Hajda
2013-10-17  8:18                     ` Tomi Valkeinen
2013-10-17  8:18                       ` Tomi Valkeinen
2013-10-17  8:18                       ` Tomi Valkeinen
2013-10-17 12:26                       ` Andrzej Hajda
2013-10-17 12:26                         ` Andrzej Hajda
2013-10-17 12:55                         ` Tomi Valkeinen
2013-10-17 12:55                           ` Tomi Valkeinen
2013-10-17 12:55                           ` Tomi Valkeinen
2013-10-18 11:55                           ` Andrzej Hajda
2013-10-18 11:55                             ` Andrzej Hajda
2013-08-09 23:02 Laurent Pinchart
2013-08-09 23:02 ` Laurent Pinchart

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=CAF6AEGuRXhzmopjmsWuQ5D6jDB1QOBvvKx-WXMYSc2qHcVn2fQ@mail.gmail.com \
    --to=robdclark@gmail.com \
    --cc=Ragesh.R@linaro.org \
    --cc=acourbot@nvidia.com \
    --cc=benjamin.gaignard@linaro.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=jesse.barnes@intel.com \
    --cc=joshi@samsung.com \
    --cc=kyungmin.park@samsung.com \
    --cc=laurent.pinchart+renesas@ideasonboard.com \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-fbdev@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=markz@nvidia.com \
    --cc=s-guiriec@ti.com \
    --cc=s.hauer@pengutronix.de \
    --cc=stephane.marchesin@gmail.com \
    --cc=swarren@wwwdotorg.org \
    --cc=thomas.petazzoni@free-electrons.com \
    --cc=tom.gall@linaro.org \
    --cc=tomi.valkeinen@ti.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.