All of lore.kernel.org
 help / color / mirror / Atom feed
From: Grant Likely <grant.likely@secretlab.ca>
To: linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCHv9 1/3] Runtime Interpreted Power Sequences
Date: Wed, 21 Nov 2012 16:44:04 +0000	[thread overview]
Message-ID: <20121121164404.E04EF3E0AE2@localhost> (raw)
In-Reply-To: <20121121013133.GE4673@opensource.wolfsonmicro.com>

On Wed, 21 Nov 2012 10:31:34 +0900, Mark Brown <broonie@opensource.wolfsonmicro.com> wrote:
> On Tue, Nov 20, 2012 at 09:54:29PM +0000, Grant Likely wrote:
> > On Sat, 17 Nov 2012 19:55:45 +0900, Alexandre Courbot <acourbot@nvidia.com> wrote:
> 
> > > With the advent of the device tree and of ARM kernels that are not
> > > board-tied, we cannot rely on these board-specific hooks anymore but
> 
> > This isn't strictly true. It is still perfectly fine to have board
> > specific code when necessary. However, there is strong encouragement to
> > enable that code in device drivers as much as possible and new board
> > files need to have very strong justification.
> 
> This isn't the message that's gone over, and even for device drivers
> everyone seems to be taking the whole device tree thing as a move to
> pull all data out of the kernel.  In some cases there are some real
> practical advantages to doing this but a lot of the people making these
> changes seem to view having things in DT as a goal in itself.

I know, and I do apologize for my part in not communicating and
shepherding enough. For anyone reading; please be pragmatic on putting
things into the DT. If a binding starts to look really complex, ask
whether or not it helps things.

> > I'm thinking about the scripts as trivial-to-parse ascii strings that
> > have a very simple set of commands. The commands use resources already
> > defined in the node. ie. 'g0' refers to the first entry in the gpios
> > property. 'r0' for the regulator, 'p0' for the pwms, 'd' means delay. By
> > no means take this as the format to use, it is just an example off the
> > top of my head, but it is already way easier to work with than putting
> > each command into a node.
> 
> It does appear to have some legibility challenges, especially with using
> the indexes into the arrays of resources.  On the other hand the arrays
> should be fairly small.

This is merely an example off the top of my head. I'm in no way wed to
the syntax.

> > > +Platform Data Format
> > > +--------------------
> > > +All relevant data structures for declaring power sequences are located in
> > > +include/linux/power_seq.h.
> 
> > Hmm... If sequences are switched to a string instead, then platform_data
> > should also use it. The power sequence data structures can be created at
> > runtime by parsing the string.
> 
> Seems like a step backwards to me - why not let people store the more
> parsed version of the data?  It's going to be less convenient for users
> on non-DT systems.
> 
> As I said in my earlier reviews I think this is a useful thing to have
> as a utility library for drivers independantly of the DT bindings, it
> would allow drivers to become more data driven.  Perhaps we can rework
> the series so that the DT bindings are added as a final patch?  All the
> rest of the code seems OK.

I'm fine with that if the bindings don't get merged yet.

g.


WARNING: multiple messages have this Message-ID (diff)
From: Grant Likely <grant.likely@secretlab.ca>
To: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: Alexandre Courbot <acourbot@nvidia.com>,
	Anton Vorontsov <cbouatmailru@gmail.com>,
	Stephen Warren <swarren@nvidia.com>,
	Thierry Reding <thierry.reding@avionic-design.de>,
	Mark Zhang <markz@nvidia.com>,
	Rob Herring <rob.herring@calxeda.com>,
	David Woodhouse <dwmw2@infradead.org>,
	Arnd Bergmann <arnd@arndb.de>,
	linux-tegra@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, linux-fbdev@vger.kernel.org,
	devicetree-discuss@lists.ozlabs.org, linux-pm@vger.kernel.org,
	Alexandre Courbot <gnurou@gmail.com>
Subject: Re: [PATCHv9 1/3] Runtime Interpreted Power Sequences
Date: Wed, 21 Nov 2012 16:44:04 +0000	[thread overview]
Message-ID: <20121121164404.E04EF3E0AE2@localhost> (raw)
In-Reply-To: <20121121013133.GE4673@opensource.wolfsonmicro.com>

On Wed, 21 Nov 2012 10:31:34 +0900, Mark Brown <broonie@opensource.wolfsonmicro.com> wrote:
> On Tue, Nov 20, 2012 at 09:54:29PM +0000, Grant Likely wrote:
> > On Sat, 17 Nov 2012 19:55:45 +0900, Alexandre Courbot <acourbot@nvidia.com> wrote:
> 
> > > With the advent of the device tree and of ARM kernels that are not
> > > board-tied, we cannot rely on these board-specific hooks anymore but
> 
> > This isn't strictly true. It is still perfectly fine to have board
> > specific code when necessary. However, there is strong encouragement to
> > enable that code in device drivers as much as possible and new board
> > files need to have very strong justification.
> 
> This isn't the message that's gone over, and even for device drivers
> everyone seems to be taking the whole device tree thing as a move to
> pull all data out of the kernel.  In some cases there are some real
> practical advantages to doing this but a lot of the people making these
> changes seem to view having things in DT as a goal in itself.

I know, and I do apologize for my part in not communicating and
shepherding enough. For anyone reading; please be pragmatic on putting
things into the DT. If a binding starts to look really complex, ask
whether or not it helps things.

> > I'm thinking about the scripts as trivial-to-parse ascii strings that
> > have a very simple set of commands. The commands use resources already
> > defined in the node. ie. 'g0' refers to the first entry in the gpios
> > property. 'r0' for the regulator, 'p0' for the pwms, 'd' means delay. By
> > no means take this as the format to use, it is just an example off the
> > top of my head, but it is already way easier to work with than putting
> > each command into a node.
> 
> It does appear to have some legibility challenges, especially with using
> the indexes into the arrays of resources.  On the other hand the arrays
> should be fairly small.

This is merely an example off the top of my head. I'm in no way wed to
the syntax.

> > > +Platform Data Format
> > > +--------------------
> > > +All relevant data structures for declaring power sequences are located in
> > > +include/linux/power_seq.h.
> 
> > Hmm... If sequences are switched to a string instead, then platform_data
> > should also use it. The power sequence data structures can be created at
> > runtime by parsing the string.
> 
> Seems like a step backwards to me - why not let people store the more
> parsed version of the data?  It's going to be less convenient for users
> on non-DT systems.
> 
> As I said in my earlier reviews I think this is a useful thing to have
> as a utility library for drivers independantly of the DT bindings, it
> would allow drivers to become more data driven.  Perhaps we can rework
> the series so that the DT bindings are added as a final patch?  All the
> rest of the code seems OK.

I'm fine with that if the bindings don't get merged yet.

g.


WARNING: multiple messages have this Message-ID (diff)
From: grant.likely@secretlab.ca (Grant Likely)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCHv9 1/3] Runtime Interpreted Power Sequences
Date: Wed, 21 Nov 2012 16:44:04 +0000	[thread overview]
Message-ID: <20121121164404.E04EF3E0AE2@localhost> (raw)
In-Reply-To: <20121121013133.GE4673@opensource.wolfsonmicro.com>

On Wed, 21 Nov 2012 10:31:34 +0900, Mark Brown <broonie@opensource.wolfsonmicro.com> wrote:
> On Tue, Nov 20, 2012 at 09:54:29PM +0000, Grant Likely wrote:
> > On Sat, 17 Nov 2012 19:55:45 +0900, Alexandre Courbot <acourbot@nvidia.com> wrote:
> 
> > > With the advent of the device tree and of ARM kernels that are not
> > > board-tied, we cannot rely on these board-specific hooks anymore but
> 
> > This isn't strictly true. It is still perfectly fine to have board
> > specific code when necessary. However, there is strong encouragement to
> > enable that code in device drivers as much as possible and new board
> > files need to have very strong justification.
> 
> This isn't the message that's gone over, and even for device drivers
> everyone seems to be taking the whole device tree thing as a move to
> pull all data out of the kernel.  In some cases there are some real
> practical advantages to doing this but a lot of the people making these
> changes seem to view having things in DT as a goal in itself.

I know, and I do apologize for my part in not communicating and
shepherding enough. For anyone reading; please be pragmatic on putting
things into the DT. If a binding starts to look really complex, ask
whether or not it helps things.

> > I'm thinking about the scripts as trivial-to-parse ascii strings that
> > have a very simple set of commands. The commands use resources already
> > defined in the node. ie. 'g0' refers to the first entry in the gpios
> > property. 'r0' for the regulator, 'p0' for the pwms, 'd' means delay. By
> > no means take this as the format to use, it is just an example off the
> > top of my head, but it is already way easier to work with than putting
> > each command into a node.
> 
> It does appear to have some legibility challenges, especially with using
> the indexes into the arrays of resources.  On the other hand the arrays
> should be fairly small.

This is merely an example off the top of my head. I'm in no way wed to
the syntax.

> > > +Platform Data Format
> > > +--------------------
> > > +All relevant data structures for declaring power sequences are located in
> > > +include/linux/power_seq.h.
> 
> > Hmm... If sequences are switched to a string instead, then platform_data
> > should also use it. The power sequence data structures can be created at
> > runtime by parsing the string.
> 
> Seems like a step backwards to me - why not let people store the more
> parsed version of the data?  It's going to be less convenient for users
> on non-DT systems.
> 
> As I said in my earlier reviews I think this is a useful thing to have
> as a utility library for drivers independantly of the DT bindings, it
> would allow drivers to become more data driven.  Perhaps we can rework
> the series so that the DT bindings are added as a final patch?  All the
> rest of the code seems OK.

I'm fine with that if the bindings don't get merged yet.

g.

  reply	other threads:[~2012-11-21 16:44 UTC|newest]

Thread overview: 158+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-17 10:55 [PATCHv9 0/3] Runtime Interpreted Power Sequences Alexandre Courbot
2012-11-17 10:55 ` Alexandre Courbot
2012-11-17 10:55 ` Alexandre Courbot
2012-11-17 10:55 ` [PATCHv9 1/3] " Alexandre Courbot
2012-11-17 10:55   ` Alexandre Courbot
2012-11-17 10:55   ` Alexandre Courbot
2012-11-17 10:55   ` Alexandre Courbot
2012-11-17 11:38   ` Anton Vorontsov
2012-11-17 11:38     ` Anton Vorontsov
2012-11-17 11:38     ` Anton Vorontsov
2012-11-19  2:29     ` Alex Courbot
2012-11-19  2:29       ` Alex Courbot
2012-11-19  2:29       ` Alex Courbot
2012-11-19  2:29       ` Alex Courbot
2012-11-19  2:32       ` Anton Vorontsov
2012-11-19  2:32         ` Anton Vorontsov
2012-11-19  2:32         ` Anton Vorontsov
2012-11-20 14:48   ` Tomi Valkeinen
2012-11-20 14:48     ` Tomi Valkeinen
2012-11-20 14:48     ` Tomi Valkeinen
2012-11-20 14:48     ` Tomi Valkeinen
2012-11-21  1:56     ` Alex Courbot
2012-11-21  1:56       ` Alex Courbot
2012-11-21  1:56       ` Alex Courbot
2012-11-21  1:56       ` Alex Courbot
2012-11-21  8:13       ` Tomi Valkeinen
2012-11-21  8:13         ` Tomi Valkeinen
2012-11-21  8:13         ` Tomi Valkeinen
2012-11-21  8:13         ` Tomi Valkeinen
2012-11-21  8:32         ` Alex Courbot
2012-11-21  8:32           ` Alex Courbot
2012-11-21  8:32           ` Alex Courbot
2012-11-21  8:32           ` Alex Courbot
2012-11-21  8:48           ` Tomi Valkeinen
2012-11-21  8:48             ` Tomi Valkeinen
2012-11-21  8:48             ` Tomi Valkeinen
2012-11-21  8:48             ` Tomi Valkeinen
2012-11-21 10:00             ` Alex Courbot
2012-11-21 10:00               ` Alex Courbot
2012-11-21 10:00               ` Alex Courbot
2012-11-22 13:01               ` Grant Likely
2012-11-22 13:01                 ` Grant Likely
2012-11-22 13:01                 ` Grant Likely
2012-11-22 13:01                 ` Grant Likely
2012-11-20 21:54   ` Grant Likely
2012-11-20 21:54     ` Grant Likely
2012-11-20 21:54     ` Grant Likely
2012-11-20 21:54     ` Grant Likely
2012-11-21  1:31     ` Mark Brown
2012-11-21  1:31       ` Mark Brown
2012-11-21  1:31       ` Mark Brown
2012-11-21 16:44       ` Grant Likely [this message]
2012-11-21 16:44         ` Grant Likely
2012-11-21 16:44         ` Grant Likely
2012-11-22  8:57       ` Linus Walleij
2012-11-22  8:57         ` Linus Walleij
2012-11-22  8:57         ` Linus Walleij
2012-11-22  8:57         ` Linus Walleij
2012-11-22  9:55         ` Alexandre Courbot
2012-11-22  9:55           ` Alexandre Courbot
2012-11-22  9:55           ` Alexandre Courbot
2012-11-22  9:55           ` Alexandre Courbot
2012-11-23  1:44         ` Mark Brown
2012-11-23  1:44           ` Mark Brown
2012-11-23  1:44           ` Mark Brown
2012-11-21  4:23     ` Alex Courbot
2012-11-21  4:23       ` Alex Courbot
2012-11-21  4:23       ` Alex Courbot
2012-11-21 11:06       ` Tomi Valkeinen
2012-11-21 11:06         ` Tomi Valkeinen
2012-11-21 11:06         ` Tomi Valkeinen
2012-11-21 11:06         ` Tomi Valkeinen
2012-11-21 11:40         ` Thierry Reding
2012-11-21 11:40           ` Thierry Reding
2012-11-21 11:40           ` Thierry Reding
2012-11-21 11:40           ` Thierry Reding
2012-11-21 12:04           ` Tomi Valkeinen
2012-11-21 12:04             ` Tomi Valkeinen
2012-11-21 12:04             ` Tomi Valkeinen
2012-11-21 13:00             ` Thierry Reding
2012-11-21 13:00               ` Thierry Reding
2012-11-21 13:00               ` Thierry Reding
2012-11-21 13:32               ` Tomi Valkeinen
2012-11-21 13:32                 ` Tomi Valkeinen
2012-11-21 13:32                 ` Tomi Valkeinen
2012-11-21 13:32                 ` Tomi Valkeinen
2012-11-21 15:02                 ` Alexandre Courbot
2012-11-21 15:02                   ` Alexandre Courbot
2012-11-21 15:02                   ` Alexandre Courbot
2012-11-21 15:02                   ` Alexandre Courbot
2012-11-21 15:12                   ` Thierry Reding
2012-11-21 15:12                     ` Thierry Reding
2012-11-21 15:12                     ` Thierry Reding
2012-11-22  2:01                     ` Alexandre Courbot
2012-11-22  2:01                       ` Alexandre Courbot
2012-11-22  2:01                       ` Alexandre Courbot
2012-11-22  2:01                       ` Alexandre Courbot
2012-11-22  2:06                       ` Mark Brown
2012-11-22  2:06                         ` Mark Brown
2012-11-22  2:06                         ` Mark Brown
2012-11-22  2:06                         ` Mark Brown
2012-11-22  3:09                         ` Alexandre Courbot
2012-11-22  3:09                           ` Alexandre Courbot
2012-11-22  3:09                           ` Alexandre Courbot
2012-11-22  3:09                           ` Alexandre Courbot
2012-11-22 13:39                     ` Grant Likely
2012-11-22 13:39                       ` Grant Likely
2012-11-22 13:39                       ` Grant Likely
2012-11-22 13:39                       ` Grant Likely
2012-11-27 15:19               ` Laurent Pinchart
2012-11-27 15:19                 ` Laurent Pinchart
2012-11-27 15:19                 ` Laurent Pinchart
2012-11-27 15:08             ` Laurent Pinchart
2012-11-27 15:08               ` Laurent Pinchart
2012-11-27 15:08               ` Laurent Pinchart
2012-11-27 15:08               ` Laurent Pinchart
2012-11-27 15:08               ` Laurent Pinchart
2012-11-27 15:19               ` Tomi Valkeinen
2012-11-27 15:19                 ` Tomi Valkeinen
2012-11-27 15:19                 ` Tomi Valkeinen
2012-11-27 15:19                 ` Tomi Valkeinen
2012-11-27 15:37                 ` Laurent Pinchart
2012-11-27 15:37                   ` Laurent Pinchart
2012-11-27 15:37                   ` Laurent Pinchart
2012-11-27 16:46                   ` Mark Brown
2012-11-27 16:46                     ` Mark Brown
2012-11-27 16:46                     ` Mark Brown
2012-11-27 14:47           ` Laurent Pinchart
2012-11-27 14:47             ` Laurent Pinchart
2012-11-27 14:47             ` Laurent Pinchart
2012-11-27 14:47             ` Laurent Pinchart
2012-11-22 13:39       ` Grant Likely
2012-11-22 13:39         ` Grant Likely
2012-11-22 13:39         ` Grant Likely
2012-11-22 13:39         ` Grant Likely
2012-11-22 21:40         ` Thierry Reding
2012-11-22 21:40           ` Thierry Reding
2012-11-22 21:40           ` Thierry Reding
2012-11-22 21:40           ` Thierry Reding
2012-11-26 11:49           ` Alex Courbot
2012-11-26 11:49             ` Alex Courbot
2012-11-26 11:49             ` Alex Courbot
2012-11-26 11:49             ` Alex Courbot
2012-11-26 15:34           ` Grant Likely
2012-11-26 15:34             ` Grant Likely
2012-11-26 15:34             ` Grant Likely
2012-11-26 15:34             ` Grant Likely
2012-11-17 10:55 ` [PATCHv9 2/3] pwm_backlight: use power sequences Alexandre Courbot
2012-11-17 10:55   ` Alexandre Courbot
2012-11-17 10:55   ` Alexandre Courbot
2012-11-17 10:55   ` Alexandre Courbot
2012-11-17 10:55 ` [PATCHv9 3/3] Take maintainership of " Alexandre Courbot
2012-11-17 10:55   ` Alexandre Courbot
2012-11-17 10:55   ` Alexandre Courbot
2012-11-20 21:58 ` [PATCHv9 0/3] Runtime Interpreted Power Sequences Grant Likely
2012-11-20 21:58   ` Grant Likely
2012-11-20 21:58   ` Grant Likely
2012-11-20 21:58   ` Grant Likely

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=20121121164404.E04EF3E0AE2@localhost \
    --to=grant.likely@secretlab.ca \
    --cc=linux-arm-kernel@lists.infradead.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 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.