public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Maxime Ripard <maxime.ripard@free-electrons.com>
To: Julian Calaby <julian.calaby@gmail.com>
Cc: moinejf@free.fr, Chen-Yu Tsai <wens@csie.org>,
	"Mailing List, Arm" <linux-arm-kernel@lists.infradead.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	linux-sunxi <linux-sunxi@googlegroups.com>
Subject: Re: [linux-sunxi] [PATCH] regulator: axp20x: support AXP813 variant
Date: Thu, 28 Jul 2016 22:21:18 +0200	[thread overview]
Message-ID: <20160728202118.GI6682@lukather> (raw)
In-Reply-To: <CAGRGNgUeORYesjLAeaO=GGhC1rv9FUU5ZUdjRx8+Pz=vCggsEw@mail.gmail.com>

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

On Thu, Jul 28, 2016 at 08:24:41PM +1000, Julian Calaby wrote:
> Hi All,
> 
> On Thu, Jul 28, 2016 at 5:28 PM, Jean-Francois Moine <moinejf@free.fr> wrote:
> > The X-Powers AXP813 PMIC is close enough to the AXP809 with some
> > more outputs.
> >
> > Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
> > ---
> >  Documentation/devicetree/bindings/mfd/axp20x.txt | 32 ++++++++-
> >  drivers/mfd/axp20x-rsb.c                         |  1 +
> >  drivers/mfd/axp20x.c                             |  3 +
> >  drivers/regulator/axp20x-regulator.c             | 82 +++++++++++++++++++++++-
> >  include/linux/mfd/axp20x.h                       | 38 +++++++++++
> >  5 files changed, 153 insertions(+), 3 deletions(-)
> >
> > diff --git a/drivers/regulator/axp20x-regulator.c b/drivers/regulator/axp20x-regulator.c
> > index 6d9ac76..c3287c9 100644
> > --- a/drivers/regulator/axp20x-regulator.c
> > +++ b/drivers/regulator/axp20x-regulator.c
> > @@ -467,7 +543,8 @@ static int axp20x_regulator_probe(struct platform_device *pdev)
> >                  * name.
> >                  */
> >                 if ((regulators == axp22x_regulators && i == AXP22X_DC1SW) ||
> > -                   (regulators == axp809_regulators && i == AXP809_DC1SW)) {
> > +                   (regulators == axp809_regulators && i == AXP809_DC1SW) ||
> > +                   (regulators == axp813_regulators && i == AXP813_DC1SW)) {
> 
> Are we getting to the point now where we need some other way to flag
> these? Maybe a set of flags per regulator?

I'd be inclined to say yes. We can also associate a structure to the
compatible, and store a bunch of infos there (like does it have a
DC1SW regulator in this case).

Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

      reply	other threads:[~2016-07-28 20:21 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <5799d673.58a51c0a.97cf9.b9c0SMTPIN_ADDED_MISSING@gmr-mx.google.com>
2016-07-28 10:24 ` [linux-sunxi] [PATCH] regulator: axp20x: support AXP813 variant Julian Calaby
2016-07-28 20:21   ` Maxime Ripard [this message]

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=20160728202118.GI6682@lukather \
    --to=maxime.ripard@free-electrons.com \
    --cc=julian.calaby@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sunxi@googlegroups.com \
    --cc=moinejf@free.fr \
    --cc=wens@csie.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