linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Thierry Reding <thierry.reding@avionic-design.de>
To: Tomi Valkeinen <tomi.valkeinen@ti.com>
Cc: Alex Courbot <acourbot@nvidia.com>,
	Stephen Warren <swarren@nvidia.com>,
	Simon Glass <sjg@chromium.org>,
	Grant Likely <grant.likely@secretlab.ca>,
	Rob Herring <rob.herring@calxeda.com>,
	Mark Brown <broonie@opensource.wolfsonmicro.com>,
	Anton Vorontsov <cbou@mail.ru>,
	David Woodhouse <dwmw2@infradead.org>,
	Arnd Bergmann <arnd@arndb.de>,
	Leela Krishna Amudala <leelakrishna.a@gmail.com>,
	"linux-tegra@vger.kernel.org" <linux-tegra@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linux-fbdev@vger.kernel.org" <linux-fbdev@vger.kernel.org>,
	"devicetree-discuss@lists.ozlabs.org" 
	<devicetree-discuss@lists.ozlabs.org>,
	"linux-doc@vger.kernel.org" <linux-doc@vger.kernel.org>
Subject: Re: [PATCH v4 1/3] Runtime Interpreted Power Sequences
Date: Tue, 21 Aug 2012 11:13:06 +0200	[thread overview]
Message-ID: <20120821091306.GA4819@avionic-0098.mockup.avionic-design.de> (raw)
In-Reply-To: <1345539465.4085.22.camel@deskari>

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

On Tue, Aug 21, 2012 at 11:57:45AM +0300, Tomi Valkeinen wrote:
> On Tue, 2012-08-21 at 10:33 +0200, Thierry Reding wrote:
> 
> > I suppose power sequences aren't needed if you have a specific driver
> > for every panel out there. However that also means that you'd have to
> > write drivers for literally every panel that requires support. In the
> > end this will just result in discussion down the road how the common
> > functionality can be refactored and we may end up with power sequences
> > again.
> > 
> > Also as you mentioned, power sequences are useful for a number of other
> > use-cases. Without power sequences you'll have to potentially create
> > extra frameworks tha reimplement parts of the power sequence code for
> > their specific hardware needs.
> 
> Right. I think my main concern is the use of DT data, not power
> sequences as such. I've been going back and forth in my mind with this
> issue with OMAP also.
> 
> The question is: what stuff belongs to DT data and what belongs to the
> kernel? I've been trying to go to the direction where DT is used to
> describe the HW connections of different IP blocks and to pass board
> specific configuration. Everything else is in the driver.
> 
> This doesn't mean that we'd have a separate driver for each device. For
> example, we have a generic panel driver in OMAP, which contains a kind
> of small panel database. The panel database contains the name of the
> panel as a key, and panel specific configuration as a value. This
> configuration could also contain some kind of generic power sequence.

I see. I do like the idea of it, because it is more straightforward than
representing the whole sequence in DT. Matching could be done using the
standard compatible property.

However this also means we'll essentially just be moving the board code.
Being in a central location it would be easier to refactor commonalities
though.

> I'd like to require the board developer to only fill in to the DT data
> what panel he is using, and how it's connected on his board. Not panel's
> internal functionality.

The amount of work required by the board developer would largely depend
on whether support for the panel is already present or not. For new
panels this would mean that a new driver needs to be written, while
representing the power sequence in DT might be easier to do, and readily
available from some datasheet.

> The one benefit I see with DT based approach is that if we have, say,
> 10000 panels, we'd have quite a big database in kernel memory and a
> board may only need one or two of those. But perhaps that could be
> helped with the use of __initdata.

I haven't worked with many different panels, so maybe I can't judge this
too well, but if panel drivers were kept in a central location, then the
number can be reduced by generalizing parts of existing drivers.

Thierry

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

  reply	other threads:[~2012-08-21  9:13 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-16  6:08 [PATCH v4 0/3] Runtime Interpreted Power Sequences Alexandre Courbot
2012-08-16  6:08 ` [PATCH v4 1/3] " Alexandre Courbot
2012-08-16  7:42   ` Thierry Reding
2012-08-16  9:19     ` Alex Courbot
2012-08-16  9:52       ` Thierry Reding
2012-08-16 10:33         ` Alex Courbot
2012-08-16 10:52           ` Thierry Reding
2012-08-16 14:14   ` Mark Brown
2012-08-16 18:38   ` Stephen Warren
2012-08-16 18:47     ` Mark Brown
2012-08-16 18:57       ` Stephen Warren
2012-08-16 19:35         ` Stephen Warren
2012-08-16 19:49     ` Thierry Reding
2012-08-16 21:10     ` Mitch Bradley
2012-08-17 23:04       ` Mark Brown
2012-08-17  8:52     ` Alex Courbot
2012-08-21  7:44   ` Tomi Valkeinen
2012-08-21  8:22     ` Alex Courbot
2012-08-21  8:33       ` Thierry Reding
2012-08-21  8:53         ` Alex Courbot
2012-08-21  8:57         ` Tomi Valkeinen
2012-08-21  9:13           ` Thierry Reding [this message]
2012-08-21  9:54             ` Tomi Valkeinen
2012-08-21 16:57               ` Mark Brown
2012-08-22  5:42                 ` Thierry Reding
2012-08-24  9:24               ` Alex Courbot
2012-08-24 10:34                 ` Tomi Valkeinen
2012-08-16  6:08 ` [PATCH v4 2/3] pwm_backlight: use power sequences Alexandre Courbot
2012-08-16 18:42   ` Stephen Warren
2012-08-16  6:08 ` [PATCH v4 3/3] tegra: add pwm backlight device tree nodes Alexandre Courbot
2012-08-16 18:45   ` Stephen Warren
2012-08-16 21:47 ` [PATCH v4 0/3] Runtime Interpreted Power Sequences Rafael J. Wysocki
2012-08-17  8:54   ` Alex Courbot

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=20120821091306.GA4819@avionic-0098.mockup.avionic-design.de \
    --to=thierry.reding@avionic-design.de \
    --cc=acourbot@nvidia.com \
    --cc=arnd@arndb.de \
    --cc=broonie@opensource.wolfsonmicro.com \
    --cc=cbou@mail.ru \
    --cc=devicetree-discuss@lists.ozlabs.org \
    --cc=dwmw2@infradead.org \
    --cc=grant.likely@secretlab.ca \
    --cc=leelakrishna.a@gmail.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-fbdev@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=rob.herring@calxeda.com \
    --cc=sjg@chromium.org \
    --cc=swarren@nvidia.com \
    --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 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).