* Re: [linux-sunxi] [PATCH] regulator: axp20x: support AXP813 variant [not found] <5799d673.58a51c0a.97cf9.b9c0SMTPIN_ADDED_MISSING@gmr-mx.google.com> @ 2016-07-28 10:24 ` Julian Calaby 2016-07-28 20:21 ` Maxime Ripard 0 siblings, 1 reply; 2+ messages in thread From: Julian Calaby @ 2016-07-28 10:24 UTC (permalink / raw) To: moinejf Cc: Chen-Yu Tsai, Maxime Ripard, Mailing List, Arm, linux-kernel, linux-sunxi 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? > new_desc = devm_kzalloc(&pdev->dev, sizeof(*desc), > GFP_KERNEL); > *new_desc = regulators[i]; > @@ -505,7 +582,8 @@ static int axp20x_regulator_probe(struct platform_device *pdev) > * Save AXP22X DCDC1 / DCDC5 regulator names for later. > */ > if ((regulators == axp22x_regulators && i == AXP22X_DCDC1) || > - (regulators == axp809_regulators && i == AXP809_DCDC1)) > + (regulators == axp809_regulators && i == AXP809_DCDC1) || > + (regulators == axp813_regulators && i == AXP813_DCDC1)) Ditto. > of_property_read_string(rdev->dev.of_node, > "regulator-name", > &dcdc1_name); Thanks, -- Julian Calaby Email: julian.calaby@gmail.com Profile: http://www.google.com/profiles/julian.calaby/ ^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [linux-sunxi] [PATCH] regulator: axp20x: support AXP813 variant 2016-07-28 10:24 ` [linux-sunxi] [PATCH] regulator: axp20x: support AXP813 variant Julian Calaby @ 2016-07-28 20:21 ` Maxime Ripard 0 siblings, 0 replies; 2+ messages in thread From: Maxime Ripard @ 2016-07-28 20:21 UTC (permalink / raw) To: Julian Calaby Cc: moinejf, Chen-Yu Tsai, Mailing List, Arm, linux-kernel, linux-sunxi [-- 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 --] ^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-07-28 20:21 UTC | newest] Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [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 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).