devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tomi Valkeinen <tomi.valkeinen@ti.com>
To: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: Tony Lindgren <tony@atomide.com>,
	linux-omap@vger.kernel.org, linux-fbdev@vger.kernel.org,
	devicetree@vger.kernel.org, Archit Taneja <archit@ti.com>,
	Darren Etheridge <detheridge@ti.com>
Subject: Re: [PATCH 13/26] ARM: omap3.dtsi: add omapdss information
Date: Thu, 12 Dec 2013 10:38:34 +0200	[thread overview]
Message-ID: <52A9760A.3000801@ti.com> (raw)
In-Reply-To: <2364383.8GWpsWSoJu@avalon>

[-- Attachment #1: Type: text/plain, Size: 5929 bytes --]

On 2013-12-12 01:44, Laurent Pinchart wrote:

>> The DSS subdevices depend on the dss_core. dss_core has to be powered up
>> for any of the subdevices to work. This is done automatically by the
>> runtime PM when the subdevices are children of the dss_core.
> 
> I'd like to get a clearer picture of the hardware here. The OMAP3 ISP is 
> organized in a seemingly similar way, with the hardware subdivided in high-
> level more-or-less independent modules. However, from a system point of view, 
> the ISP submodules are not standalone: they're part of the same power domain 
> as the ISP core, with subclocks management and interrupts being handled by the 
> ISP core. For those reasons we've modeled the ISP as a single platform device.
> 
> Are the DSS submodules really independent, or are they organized similarly ? 
> For instance do they each have a clock handled by the OMAP core clock IP, or 
> are the clocks gated by the DSS core ? Do they have interrupts routed to the 
> GIC, or does the DSS core driver demux the interrupts ?

The DSS is "interesting". The TRM for various OMAP versions are the best
source of information, there's integration section in the very beginning
of the DSS chapter.

We have the main dss_core (just DSS in the TRM, but for clarity we use
dss_core) module, which is kind of a wrapper/glue for all the
submodules. dss_core contains things like controlling muxes for signals
between submodules, or clocks coming from outside. And there's the DSS
power domain, containing all the DSS modules.

Then we have DISPC, which reads the pixel data, manipulates it, and
outputs raw RGB data to encoder submodules.

Then we have DSI, HDMI, RFBI, VENC encoder submodules. They all have
separate address spaces, some have dedicated PLLs, PHYs, and interrupts.

Then DPI, which I think is mostly just level shifters. It's really just
a port, as you say.

SDI is a bit unclear to me. The registers for it are in the dss_core.
There's only a few registers, but it does have a PHY and a PLL. But I
guess it's also more of a port than a separate module.

As for the clocks, I'm not sure what the actual point is that you want
to clarify. DSS gets one "main" func clock from PRCM, which is used by
DISPC and in some cases other submodules. But then we have dedicated DSI
and HDMI PLLs, which, at least in DSI's case, can be used to fully
satisfy DSI's clock needs. The PLLs can also be used for DISPC, so the
PRCM clock is not needed in all cases.

The interrupts, then. In OMAP4, DISPC, DSI1, DSI2 and HDMI each have
their own interrupt line. In OMAP3, DISPC and DSI shared the same
interrupt line. But in both OMAP4 and OMAP3 DISPC and DSI interrupt
status/enable is handled via the respective IP.

The DSS submodules also are not really designed together. For example,
the HDMI IP is from one vendor, not TI. And the HDMI IP is different in
OMAP4 and OMAP5. Most of the DSS IPs are, I believe, from TI. But it's
not like all the IPs were designed to work together, that's why we have
wrappers/glue blocks (e.g. around HDMI).

So, are they independent? I don't know =). I think they lean on the
independent side. dss_core is always needed for the submodules to work,
but for example DSI could be used without DISPC, using system DMA to
transfer data from memory to DSI. Not a very useful thing to do, but
still, there are dedicated DMA channels for that.

> If the submodules are not independent, would it make sense to have a single DT 
> node that would be matched with the DSS core driver ? You could list 
> information about the submodules in subnodes, and possibly create platform 
> devices internally in the DSS core, but a single platform device would be 
> instantiated from DT, and the DSS core wouldn't need a "simple-bus" compatible 
> string. My gut feeling is that this would be a better representation of the 
> hardware, but I might not known enough about the DSS and be completely wrong.

I have been wondering about this for a long time. The DSS modules have
dependencies, and splitting them into separate devices/drivers brings
the issue of probe order. We side-step that by having the virtual
omapdss driver add the drivers for DSS modules in proper order.

But then, I feel that they are quite independent and probably should be
separate devices. And we've had omap hwmods, which I believe force us to
have separate devices (although afaik hwmods are going away).

>>> BTW, for v3.15, I'm hoping to do patches where we deprecate ti,hwmods
>>> property and do the lookup based on the compatible property instead ;)
>>> So from that point of view we need to get the device mapping right in
>>> the .dtsi files, and don't want to start mixing up separate devices into
>>> single .dtsi entry.
>>
>> Hmm, was that just a general comment, or something that affects the DSS
>> DT data I have in my patch? As far as I understand, the DSS nodes
>> reflect the current hwmods correctly.
>>
>> With the exception that DPI and SDI do not have a matching hwmod, as
>> they are really part of dss_core/dispc. They are separate nodes as they
>> are "video outputs" the same way as the other subnodes.
>>
>> I could perhaps remove the DPI and SDI nodes, and have them as direct
>> video ports from DISPC, but... That's easier said than done.
> 
> DPI and SDI indeed seem like ports to me, node devices. Have you given the 
> implementation a thought ? How difficult would it be ?

I have not though too much about the implementation. I'll spend some
time on that to see how it goes.

There's also the question where do the ports belong to. DISPC outputs
the pixels.

For DPI, I don't see dss_core really doing anything.

For SDI, the dss_core contains the control for the SDI PLL and PHY. But
SDI PLL and PHY are not parts of dss_core, just the control is done via
dss_core.

 Tomi



[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 901 bytes --]

  reply	other threads:[~2013-12-12  8:38 UTC|newest]

Thread overview: 88+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-04 12:28 [PATCH 00/26] OMAPDSS: DT support (Christmas edition) Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 01/26] OMAPDSS: rename display-sysfs 'name' entry Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 02/26] OMAPDSS: DSI: fix fifosize Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 03/26] ARM: OMAP: remove DSS DT hack Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 04/26] OMAPDSS: remove DT hacks for regulators Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 05/26] ARM: OMAP2+: add omapdss_init_of() Tomi Valkeinen
2013-12-11 23:10   ` Laurent Pinchart
2013-12-12  7:30     ` Tomi Valkeinen
2013-12-13  8:32       ` Archit Taneja
2013-12-13  8:40         ` Tomi Valkeinen
2013-12-13 17:07         ` Tony Lindgren
2013-12-04 12:28 ` [PATCH 06/26] OMAPDSS: if dssdev->name==NULL, use alias Tomi Valkeinen
2013-12-11 23:13   ` Laurent Pinchart
2013-12-11 23:56     ` Laurent Pinchart
2013-12-12  7:41       ` Tomi Valkeinen
     [not found]         ` <52A968BD.20304-l0cyMroinI0@public.gmane.org>
2013-12-12 10:05           ` Sebastian Reichel
2013-12-12 13:22             ` Laurent Pinchart
2013-12-12 14:13             ` Tomi Valkeinen
2013-12-12 14:15               ` Laurent Pinchart
2013-12-12 14:19                 ` Tomi Valkeinen
2013-12-12 17:31                   ` Sebastian Reichel
2013-12-13 12:01               ` Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 07/26] OMAPDSS: get dssdev->alias from DT alias Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 08/26] OMAPFB: clean up default display search Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 09/26] OMAPFB: search for default display with DT alias Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 10/26] OMAPDSS: add of helpers Tomi Valkeinen
2013-12-11 23:19   ` Laurent Pinchart
2013-12-12  7:48     ` Tomi Valkeinen
2013-12-13  2:37       ` Laurent Pinchart
2013-12-04 12:28 ` [PATCH 11/26] OMAPDSS: Add DT support to DSS, DISPC, DPI, HDMI, VENC Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 12/26] OMAPDSS: Add DT support to DSI Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 13/26] ARM: omap3.dtsi: add omapdss information Tomi Valkeinen
2013-12-05 17:05   ` Tony Lindgren
2013-12-09 12:45     ` Tomi Valkeinen
2013-12-09 18:04       ` Tony Lindgren
2013-12-11 23:44       ` Laurent Pinchart
2013-12-12  8:38         ` Tomi Valkeinen [this message]
2013-12-12 21:59           ` Tony Lindgren
2013-12-13  3:27             ` Laurent Pinchart
2013-12-13 10:18               ` Tomi Valkeinen
     [not found]                 ` <52AADEF3.9040808-l0cyMroinI0@public.gmane.org>
2013-12-13 17:10                   ` Tony Lindgren
2013-12-13  3:24           ` Laurent Pinchart
2013-12-13  9:29             ` Tomi Valkeinen
2013-12-16 10:49             ` Tomi Valkeinen
     [not found]               ` <52AEDA9F.2020609-l0cyMroinI0@public.gmane.org>
2013-12-16 13:55                 ` Laurent Pinchart
2013-12-04 12:28 ` [PATCH 14/26] ARM: omap4.dtsi: " Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 15/26] ARM: omap4-panda.dts: add display information Tomi Valkeinen
2013-12-06  8:57   ` Javier Martinez Canillas
2013-12-09 12:56     ` Tomi Valkeinen
2013-12-09 15:09       ` Javier Martinez Canillas
2013-12-09 15:30         ` Tomi Valkeinen
2013-12-09 16:53           ` Javier Martinez Canillas
2013-12-10 10:56             ` Enric Balletbo Serra
2013-12-10 12:10               ` Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 16/26] ARM: omap4-sdp.dts: " Tomi Valkeinen
2013-12-13  9:27   ` Archit Taneja
2013-12-13  9:39     ` Tomi Valkeinen
2013-12-13  9:58       ` Archit Taneja
2013-12-13 10:15         ` Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 17/26] ARM: omap3-tobi.dts: add lcd (TEST) Tomi Valkeinen
2013-12-06 10:18   ` Florian Vaussard
2013-12-10 12:18     ` Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 18/26] ARM: omap3-beagle.dts: add display information Tomi Valkeinen
2013-12-06  8:41   ` Javier Martinez Canillas
2013-12-09 12:06     ` Tomi Valkeinen
2013-12-09 12:16       ` Javier Martinez Canillas
2013-12-04 12:28 ` [PATCH 19/26] ARM: omap3-beagle-xm.dts: " Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 20/26] OMAPDSS: panel-dsi-cm: Add DT support Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 21/26] OMAPDSS: encoder-tfp410: " Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 22/26] OMAPDSS: connector-dvi: " Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 23/26] OMAPDSS: encoder-tpd12s015: " Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 24/26] OMAPDSS: hdmi-connector: " Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 25/26] OMAPDSS: panel-dpi: " Tomi Valkeinen
2013-12-04 12:28 ` [PATCH 26/26] OMAPDSS: connector-analog-tv: " Tomi Valkeinen
     [not found] ` <1386160133-24026-1-git-send-email-tomi.valkeinen-l0cyMroinI0@public.gmane.org>
2013-12-04 16:01   ` [PATCH 00/26] OMAPDSS: DT support (Christmas edition) Sebastian Reichel
2013-12-05  9:41     ` Tomi Valkeinen
2013-12-12  0:39 ` Laurent Pinchart
2013-12-12  8:54   ` Tomi Valkeinen
2013-12-13  3:45     ` Laurent Pinchart
2013-12-13  8:16       ` Geert Uytterhoeven
2013-12-13 10:05       ` Tomi Valkeinen
2013-12-13 14:37         ` Laurent Pinchart
2013-12-13 15:47           ` Tomi Valkeinen
2013-12-13 17:22             ` Tony Lindgren
2013-12-14  7:34               ` Tomi Valkeinen
2013-12-14 14:09                 ` Tony Lindgren
2013-12-16  7:24                   ` Tomi Valkeinen
2013-12-18  0:30                     ` Tony Lindgren

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=52A9760A.3000801@ti.com \
    --to=tomi.valkeinen@ti.com \
    --cc=archit@ti.com \
    --cc=detheridge@ti.com \
    --cc=devicetree@vger.kernel.org \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-fbdev@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=tony@atomide.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 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).