Hi Jonathan,
On Sun, Jan 21, 2018 at 12:26:55PM +, Jonathan Cameron wrote:
> On Mon, 15 Jan 2018 11:33:41 +0100
> Quentin Schulz wrote:
>
> > The X-Powers AXP813 PMIC is really close to what is already done for
> > AXP20X/AXP22X.
> >
> > There are two pairs
with
old DTs.
Signed-off-by: Quentin Schulz
---
drivers/iio/adc/axp20x_adc.c | 19 ++-
1 file changed, 18 insertions(+), 1 deletion(-)
diff --git a/drivers/iio/adc/axp20x_adc.c b/drivers/iio/adc/axp20x_adc.c
index 3fc1b06..3968053 100644
--- a/drivers/iio/adc/axp20x_adc.c
This adds a DT node for the ADC of the PMIC so that there can be
consumers of its IIO channels declaring their consumptions via DT.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/axp209.dtsi | 5 +
1 file changed, 5 insertions(+)
diff --git a/arch/arm/boot/dts/axp209.dtsi b/arch/arm
To prepare for a new comer that set a different register with different
values, move rate setting in a function that is specific to each AXP
variant.
Signed-off-by: Quentin Schulz
---
drivers/iio/adc/axp20x_adc.c | 18 +++---
1 file changed, 11 insertions(+), 7 deletions(-)
diff
pinctrl DT node,
v2:
- introduce data structure instead of ID for variant specific code in
battery driver,
- add DT binding for ADC driver,
- make mfd probe the ADC driver via DT as well so that its IIO channels
can be consumed by other drivers via DT mapping,
Thanks,
Quentin
Quentin Schulz
AXP20X/AXP22X.
GPIO0 can be used as an ADC (measuring Volts) unlike for AXP22X.
The scales to apply to the different inputs are unlike the ones from
AXP20X and AXP22X.
Signed-off-by: Quentin Schulz
Acked-by: Jonathan Cameron
---
drivers/iio/adc/axp20x_adc.c | 123
X-Powers PMICs have several ADC channels that can be used for different
purposes, e.g. PMIC internal temperature, battery voltage or AC current.
This is the documentation for AXP209, AXP221/223 and AXP813 ADC
bindings.
Signed-off-by: Quentin Schulz
Reviewed-by: Rob Herring
---
Documentation
The AXP813 can have a battery as power supply, so let's add it to the
list of compatibles.
Signed-off-by: Quentin Schulz
Reviewed-by: Rob Herring
---
Documentation/devicetree/bindings/power/supply/axp20x_battery.txt | 8 +++
1 file changed, 4 insertions(+), 4 deletions(-)
diff --
This makes the axp20x_adc driver probe with platform device id
"axp813-adc".
Signed-off-by: Quentin Schulz
---
drivers/mfd/axp20x.c | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/mfd/axp20x.c b/drivers/mfd/axp20x.c
index 1977a03..e5516aa 100644
--- a/d
the
PMIC is valid.
Signed-off-by: Quentin Schulz
---
drivers/power/supply/axp20x_battery.c | 42 -
1 file changed, 42 insertions(+)
diff --git a/drivers/power/supply/axp20x_battery.c
b/drivers/power/supply/axp20x_battery.c
index d73c78f..e75fa90 100644
--- a/drivers
As axp20x-battery-power-supply now supports AXP813, add a cell for it.
Signed-off-by: Quentin Schulz
Acked-for-MFD-by: Lee Jones
---
drivers/mfd/axp20x.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/mfd/axp20x.c b/drivers/mfd/axp20x.c
index e5516aa..aaf2acb 100644
--- a
and update the code to use it.
Signed-off-by: Quentin Schulz
---
drivers/power/supply/axp20x_battery.c | 100 +--
1 file changed, 66 insertions(+), 34 deletions(-)
diff --git a/drivers/power/supply/axp20x_battery.c
b/drivers/power/supply/axp20x_battery.c
index 7494f0f.
supply subnode for AXP81X PMIC.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/axp81x.dtsi | 5 +
1 file changed, 5 insertions(+)
diff --git a/arch/arm/boot/dts/axp81x.dtsi b/arch/arm/boot/dts/axp81x.dtsi
index 6b5e7bc..1b05c7f 100644
--- a/arch/arm/boot/dts/axp81x.dtsi
+++ b/arch/arm
The TBS A711 has an AXP813 PMIC and a soldered battery, thus, we enable
the battery power supply subnode in its Device Tree.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/sun8i-a83t-tbs-a711.dts | 4
1 file changed, 4 insertions(+)
diff --git a/arch/arm/boot/dts/sun8i-a83t-tbs-a711
This adds a DT node for the ADC of the PMIC so that there can be
consumers of its IIO channels declaring their consumptions via DT.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/axp81x.dtsi | 5 +
1 file changed, 5 insertions(+)
diff --git a/arch/arm/boot/dts/axp81x.dtsi b/arch/arm
This adds a DT node for the ADC of the PMIC so that there can be
consumers of its IIO channels declaring their consumptions via DT.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/axp22x.dtsi | 5 +
1 file changed, 5 insertions(+)
diff --git a/arch/arm/boot/dts/axp22x.dtsi b/arch/arm
This makes AXP209 and AXP22x ADCs probe first via DT and then by
fallback via platform.
Signed-off-by: Quentin Schulz
---
drivers/mfd/axp20x.c | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/mfd/axp20x.c b/drivers/mfd/axp20x.c
index e94c72c..1977a03 100644
--- a
The DT node should be named after its functionality and not after the
IP it's defining.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/axp81x.dtsi | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm/boot/dts/axp81x.dtsi b/arch/arm/boot/dts/axp81x.dtsi
index 1b
This adds a DT node for the ADC of the PMIC so that there can be
consumers of its IIO channels declaring their consumptions via DT.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/axp209.dtsi | 5 +
1 file changed, 5 insertions(+)
diff --git a/arch/arm/boot/dts/axp209.dtsi b/arch/arm
This adds a DT node for the ADC of the PMIC so that there can be
consumers of its IIO channels declaring their consumptions via DT.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/axp22x.dtsi | 5 +
1 file changed, 5 insertions(+)
diff --git a/arch/arm/boot/dts/axp22x.dtsi b/arch/arm
To prepare for a new comer that set a different register with different
values, move rate setting in a function that is specific to each AXP
variant.
Signed-off-by: Quentin Schulz
---
drivers/iio/adc/axp20x_adc.c | 18 +++---
1 file changed, 11 insertions(+), 7 deletions(-)
diff
X-Powers PMICs have several ADC channels that can be used for different
purposes, e.g. PMIC internal temperature, battery voltage or AC current.
This is the documentation for AXP209, AXP221/223 ADC bindings.
Signed-off-by: Quentin Schulz
---
Documentation/devicetree/bindings/iio/adc
well so that its IIO channels
can be consumed by other drivers via DT mapping,
Thanks,
Quentin
Quentin Schulz (16):
iio: adc: axp20x_adc: put ADC rate setting in a per-variant function
dt-bindings: iio: adc: add binding for X-Powers AXP PMICs ADC
iio: adc: axp20x_adc: make it possible to
As axp20x-battery-power-supply now supports AXP813, add a cell for it.
Signed-off-by: Quentin Schulz
---
drivers/mfd/axp20x.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/mfd/axp20x.c b/drivers/mfd/axp20x.c
index d112414..1175091 100644
--- a/drivers/mfd/axp20x.c
+++ b/drivers
This makes AXP209 and AXP22x ADCs probe first via DT and then by
fallback via platform.
Signed-off-by: Quentin Schulz
---
drivers/mfd/axp20x.c | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/mfd/axp20x.c b/drivers/mfd/axp20x.c
index d8c92fb..e0cbaea 100644
--- a
supply subnode for AXP81X PMIC.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/axp81x.dtsi | 5 +
1 file changed, 5 insertions(+)
diff --git a/arch/arm/boot/dts/axp81x.dtsi b/arch/arm/boot/dts/axp81x.dtsi
index dd25bfe..5fb396e 100644
--- a/arch/arm/boot/dts/axp81x.dtsi
+++ b/arch/arm
AXP813 is now supported so add documentation for this compatible.
Signed-off-by: Quentin Schulz
---
Documentation/devicetree/bindings/iio/adc/axp20x_adc.txt | 9 +-
1 file changed, 9 insertions(+)
diff --git a/Documentation/devicetree/bindings/iio/adc/axp20x_adc.txt
b/Documentation
This makes the axp20x_adc driver probe with platform device id
"axp813-adc".
Signed-off-by: Quentin Schulz
---
drivers/mfd/axp20x.c | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/mfd/axp20x.c b/drivers/mfd/axp20x.c
index e0cbaea..d112414 100644
--- a/d
The TBS A711 has an AXP813 PMIC and a soldered battery, thus, we enable
the battery power supply subnode in its Device Tree.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/sun8i-a83t-tbs-a711.dts | 4
1 file changed, 4 insertions(+)
diff --git a/arch/arm/boot/dts/sun8i-a83t-tbs-a711
This adds a DT node for the ADC of the PMIC so that there can be
consumers of its IIO channels declaring their consumptions via DT.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/axp81x.dtsi | 5 +
1 file changed, 5 insertions(+)
diff --git a/arch/arm/boot/dts/axp81x.dtsi b/arch/arm
AXP20X/AXP22X.
GPIO0 can be used as an ADC (measuring Volts) unlike for AXP22X.
The scales to apply to the different inputs are unlike the ones from
AXP20X and AXP22X.
Signed-off-by: Quentin Schulz
---
drivers/iio/adc/axp20x_adc.c | 123 -
include/linux/mfd
the
PMIC is valid.
Signed-off-by: Quentin Schulz
---
drivers/power/supply/axp20x_battery.c | 42 -
1 file changed, 42 insertions(+)
diff --git a/drivers/power/supply/axp20x_battery.c
b/drivers/power/supply/axp20x_battery.c
index d73c78f..dad72a5 100644
--- a/drivers
and update the code to use it.
Signed-off-by: Quentin Schulz
---
drivers/power/supply/axp20x_battery.c | 100 +--
1 file changed, 66 insertions(+), 34 deletions(-)
diff --git a/drivers/power/supply/axp20x_battery.c
b/drivers/power/supply/axp20x_battery.c
index 7494f0f.
with
old DTs.
Signed-off-by: Quentin Schulz
---
drivers/iio/adc/axp20x_adc.c | 19 ++-
1 file changed, 18 insertions(+), 1 deletion(-)
diff --git a/drivers/iio/adc/axp20x_adc.c b/drivers/iio/adc/axp20x_adc.c
index 3fc1b06..f8c4c62 100644
--- a/drivers/iio/adc/axp20x_adc.c
The AXP813 can have a battery as power supply, so let's add it to the
list of compatibles.
Signed-off-by: Quentin Schulz
---
Documentation/devicetree/bindings/power/supply/axp20x_battery.txt | 8 +++
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/Documentation/devic
209 PMIC pinctrl and GPIO Support"
> - depends on MFD_AXP20X
> + depends on MFD_AXP20X && OF
> help
> AXP PMICs provides multiple GPIOs that can be muxed for different
> functions. This driver bundles a pinctrl driver to select the fu
This fixes some compilation issues.
GENERIC_PINCONF and OF at least for pinconf_generic_dt_*, PINMUX at
least for pinmux_ops and GPIOLIB for at least gpio_chip.
Fixes: 23f75d7dfa92 ("pinctrl: axp209: add pinctrl features")
Reported-by: Randy Dunlab
Signed-off-by: Quentin Schulz
--
pport for AXP813 GPIOs")
Signed-off-by: Quentin Schulz
Reported-by: Mylène Josserand
---
drivers/pinctrl/pinctrl-axp209.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/pinctrl/pinctrl-axp209.c b/drivers/pinctrl/pinctrl-axp209.c
index 22d3bb0bf927..510a2821e
Hi Jonathan,
On 10/12/2017 17:49, Jonathan Cameron wrote:
> On Mon, 4 Dec 2017 15:12:51 +0100
> Quentin Schulz wrote:
>
>> The X-Powers AXP813 PMIC has got some slight differences from
>> AXP20X/AXP22X PMICs:
>> - the maximum voltage supplied by the PMIC is 4.35 i
Hi Jonathan,
On 10/12/2017 17:36, Jonathan Cameron wrote:
> On Mon, 4 Dec 2017 15:12:48 +0100
> Quentin Schulz wrote:
>
>> The X-Powers AXP813 PMIC is really close to what is already done for
>> AXP20X/AXP22X.
>>
>> There are two pairs of bits to set the
Hi all,
There is a bug below.
On 05/12/2017 15:46, Quentin Schulz wrote:
> The AXP813 has only two GPIOs. GPIO0 can either be used as a GPIO, an
> LDO regulator or an ADC. GPIO1 can be used either as a GPIO or an LDO
> regulator.
>
> Moreover, the status bit of the GPIOs when i
Hi Chen-Yu,
On 07/12/2017 09:54, Chen-Yu Tsai wrote:
> On Thu, Dec 7, 2017 at 4:51 PM, Quentin Schulz
> wrote:
>> Hi Maxime,
>>
>> On 05/12/2017 09:08, Maxime Ripard wrote:
>>> On Mon, Dec 04, 2017 at 03:12:49PM +0100, Quentin Schulz wrote:
>>>>
Hi Maxime,
On 05/12/2017 09:08, Maxime Ripard wrote:
> On Mon, Dec 04, 2017 at 03:12:49PM +0100, Quentin Schulz wrote:
>> This makes the axp20x_adc driver probe with platform device id
>> "axp813-adc".
>>
>> Signed-off-by: Quentin Schulz
>> ---
&
Hi all,
Copy pasting of the cover letter done wrong, there are only 9 patches in
this patch series unlike what's specified in the title of the cover
letter for this patch series.
Sorry for the noise.
Quentin
On 05/12/2017 15:46, Quentin Schulz wrote:
> The AXP209 and AXP813 PMICs have
The X-Powers AXP209 has 3 GPIOs. GPIO0/1 can each act either as a GPIO,
an ADC or a LDO regulator. GPIO2 can only act as a GPIO.
This adds the pinctrl features to the driver so GPIO0/1 can be used as
ADC or LDO regulator.
Signed-off-by: Quentin Schulz
Acked-by: Maxime Ripard
---
drivers
The X-Powers AXP209 has 3 GPIOs. GPIO0/1 can each act either as a GPIO,
an ADC or a LDO regulator. GPIO2 can only act as a GPIO.
This adds the pinctrl features to the driver so GPIO0/1 can be used as
ADC or LDO regulator.
Signed-off-by: Quentin Schulz
Acked-by: Rob Herring
Acked-by: Maxime
To prepare for patches that will add support for a new PMIC that has a
different GPIO adc muxing value, add an adc_mux within axp20x_pctl
structure and use it.
Signed-off-by: Quentin Schulz
Acked-by: Maxime Ripard
---
drivers/pinctrl/pinctrl-axp209.c | 4 +++-
1 file changed, 3 insertions
As GPIO/pinctrl driver now supports AXP813, add a cell for it.
Signed-off-by: Quentin Schulz
Acked-by: Maxime Ripard
Acked-by: Linus Walleij
Acked-for-MFD-by: Lee Jones
---
drivers/mfd/axp20x.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/mfd/axp20x.c b/drivers/mfd/axp20x.c
register all pins within the same range instead of a range per pin,
Thanks,
Quentin
Quentin Schulz (9):
gpio: axp209: switch unsigned variables to unsigned int
pinctrl: move gpio-axp209 to pinctrl
pinctrl: axp209: add pinctrl features
dt-bindings: gpio: gpio-axp209: add pinctrl features
p
The AXP813 has only two GPIOs. GPIO0 can either be used as a GPIO, an
LDO regulator or an ADC. GPIO1 can be used either as a GPIO or an LDO
regulator.
Moreover, the status bit of the GPIOs when in input mode is not offset
by 4 unlike the AXP209.
Signed-off-by: Quentin Schulz
Acked-by: Maxime
To prepare the driver for the upcoming pinctrl features, move the GPIO
driver AXP209 from GPIO to pinctrl subsystem.
Signed-off-by: Quentin Schulz
Acked-by: Maxime Ripard
Acked-by: Chen-Yu Tsai
---
drivers/gpio/Kconfig | 6 --
drivers/gpio/Makefile
Checkpatch complains with the following message:
WARNING: Prefer 'unsigned int' to bare use of 'unsigned'
Let's make it happy by switching over to unsigned int.
Signed-off-by: Quentin Schulz
---
drivers/gpio/gpio-axp209.c | 13 +++--
1 file changed, 7 i
To prepare for patches that will add support for a new PMIC that has a
different GPIO input status register, add a gpio_status_offset within
axp20x_pctl structure and use it.
Signed-off-by: Quentin Schulz
Acked-by: Maxime Ripard
Acked-by: Chen-Yu Tsai
---
drivers/pinctrl/pinctrl-axp209.c | 4
.
Signed-off-by: Quentin Schulz
Acked-by: Maxime Ripard
---
drivers/pinctrl/pinctrl-axp209.c | 176 +++
1 file changed, 88 insertions(+), 88 deletions(-)
diff --git a/drivers/pinctrl/pinctrl-axp209.c b/drivers/pinctrl/pinctrl-axp209.c
index 48cb57dcc575
(kthread+0x120/0x150)
> [] (kthread) from [] (ret_from_fork+0x14/0x2c)
>
> Solve both issues by moving to
> devm_rtc_allocate_device()/rtc_register_device()
>
> Signed-off-by: Alexandre Belloni
Tested-by: Quentin Schulz
Thanks,
Quentin
--
Quentin Schulz, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
AXP20X/AXP22X.
GPIO0 can be used as an ADC (measuring Volts) unlike for AXP22X.
The scales to apply to the different inputs are unlike the ones from
AXP20X and AXP22X.
Signed-off-by: Quentin Schulz
---
drivers/iio/adc/axp20x_adc.c | 122 -
include/linux/mfd
The TBS A711 has an AXP813 PMIC and a soldered battery, thus, we enable
the battery power supply subnode in its Device Tree.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/sun8i-a83t-tbs-a711.dts | 4
1 file changed, 4 insertions(+)
diff --git a/arch/arm/boot/dts/sun8i-a83t-tbs-a711
supply subnode for AXP81X PMIC.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/axp81x.dtsi | 5 +
1 file changed, 5 insertions(+)
diff --git a/arch/arm/boot/dts/axp81x.dtsi b/arch/arm/boot/dts/axp81x.dtsi
index 73b761f..f7401c3 100644
--- a/arch/arm/boot/dts/axp81x.dtsi
+++ b/arch/arm
As axp20x-battery-power-supply now supports AXP813, add a cell for it.
Signed-off-by: Quentin Schulz
---
drivers/mfd/axp20x.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/mfd/axp20x.c b/drivers/mfd/axp20x.c
index 42e54d1..7566358 100644
--- a/drivers/mfd/axp20x.c
+++ b/drivers
the
PMIC is valid.
Signed-off-by: Quentin Schulz
---
drivers/power/supply/axp20x_battery.c | 44 +++-
1 file changed, 43 insertions(+), 1 deletion(-)
diff --git a/drivers/power/supply/axp20x_battery.c
b/drivers/power/supply/axp20x_battery.c
index 7494f0f..cb30302 100644
The AXP813 can have a battery as power supply, so let's add it to the
list of compatibles.
Signed-off-by: Quentin Schulz
---
Documentation/devicetree/bindings/power/supply/axp20x_battery.txt | 8 +++
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/Documentation/devic
This makes the axp20x_adc driver probe with platform device id
"axp813-adc".
Signed-off-by: Quentin Schulz
---
drivers/mfd/axp20x.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/mfd/axp20x.c b/drivers/mfd/axp20x.c
index 2468b43..42e54d1 100644
--- a/d
To prepare for a new comer that set a different register with different
values, move rate setting in a function that is specific to each AXP
variant.
Signed-off-by: Quentin Schulz
---
drivers/iio/adc/axp20x_adc.c | 17 ++---
1 file changed, 10 insertions(+), 7 deletions(-)
diff
e ADC driver, add the battery
power supply node in axp81x node and enable it for the TBS A711 since it
has a soldered battery.
Q: The BananaPi M3 has two solder balls for battery, should the battery
power supply node be enabled for this board as well?
Thanks,
Quentin
Quentin Schulz (8):
iio
Hi Maxime,
On 01/12/2017 16:57, Maxime Ripard wrote:
> On Fri, Dec 01, 2017 at 02:44:43PM +0100, Quentin Schulz wrote:
>> +static void axp20x_gpio_set(struct gpio_chip *chip, unsigned offset,
>> +int value)
>> +{
>
> checkpatch output:
> WAR
cations,
- reorder of some patches,
- register all pins within the same range instead of a range per pin,
Thanks,
Quentin
Quentin Schulz (10):
pinctrl: move gpio-axp209 to pinctrl
pinctrl: axp209: add pinctrl features
dt-bindings: gpio: gpio-axp209: add pinctrl features
pinctrl: ax
To prepare for patches that will add support for a new PMIC that has a
different GPIO adc muxing value, add an adc_mux within axp20x_pctl
structure and use it.
Signed-off-by: Quentin Schulz
---
drivers/pinctrl/pinctrl-axp209.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git
The AXP813 has only two GPIOs. GPIO0 can either be used as a GPIO, an
LDO regulator or an ADC. GPIO1 can be used either as a GPIO or an LDO
regulator.
Moreover, the status bit of the GPIOs when in input mode is not offset
by 4 unlike the AXP209.
Signed-off-by: Quentin Schulz
Acked-by: Maxime
The X-Powers AXP209 has 3 GPIOs. GPIO0/1 can each act either as a GPIO,
an ADC or a LDO regulator. GPIO2 can only act as a GPIO.
This adds the pinctrl features to the driver so GPIO0/1 can be used as
ADC or LDO regulator.
Signed-off-by: Quentin Schulz
---
drivers/pinctrl/pinctrl-axp209.c | 306
The X-Powers AXP209 has 3 GPIOs. GPIO0/1 can each act either as a GPIO,
an ADC or a LDO regulator. GPIO2 can only act as a GPIO.
This adds the pinctrl features to the driver so GPIO0/1 can be used as
ADC or LDO regulator.
Signed-off-by: Quentin Schulz
Acked-by: Rob Herring
---
Documentation
To prepare the driver for the upcoming pinctrl features, move the GPIO
driver AXP209 from GPIO to pinctrl subsystem.
Signed-off-by: Quentin Schulz
Acked-by: Maxime Ripard
Acked-by: Chen-Yu Tsai
---
drivers/gpio/Kconfig | 6 +-
drivers/gpio/Makefile| 1 +-
drivers
As GPIO/pinctrl driver now supports AXP813, add a cell for it.
Signed-off-by: Quentin Schulz
Acked-by: Maxime Ripard
---
drivers/mfd/axp20x.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/mfd/axp20x.c b/drivers/mfd/axp20x.c
index 2468b43..d8c92fb 100644
--- a/drivers/mfd
.
Signed-off-by: Quentin Schulz
---
drivers/pinctrl/pinctrl-axp209.c | 180
1 file changed, 90 insertions(+), 90 deletions(-)
diff --git a/drivers/pinctrl/pinctrl-axp209.c b/drivers/pinctrl/pinctrl-axp209.c
index 2dc286f..6201d2b 100644
--- a/drivers/pinctrl/pinctrl
This adds DT node for the GPIO/pinctrl part present in AXP813/AXP818.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/axp81x.dtsi | 6 ++
1 file changed, 6 insertions(+)
diff --git a/arch/arm/boot/dts/axp81x.dtsi b/arch/arm/boot/dts/axp81x.dtsi
index 73b761f..0ef959d 100644
--- a/arch
To prepare for patches that will add support for a new PMIC that has a
different GPIO input status register, add a gpio_status_offset within
axp20x_pctl structure and use it.
Signed-off-by: Quentin Schulz
Acked-by: Maxime Ripard
Acked-by: Chen-Yu Tsai
---
drivers/pinctrl/pinctrl-axp209.c | 4
On AXP813/818, GPIO0 and GPIO1 can be used as LDO as (respectively)
ldo_io0 and ldo_io1.
Let's add the pinctrl properties to the said regulators.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/axp81x.dtsi | 14 ++
1 file changed, 14 insertions(+)
diff --git a/arch/arm
Hi Chen-Yu, Linus,
On 03/10/2017 17:08, Chen-Yu Tsai wrote:
> On Tue, Oct 3, 2017 at 10:47 PM, Maxime Ripard
> wrote:
>> Hi Linus,
>>
>> On Tue, Oct 03, 2017 at 09:27:17AM +, Linus Walleij wrote:
>>> On Mon, Oct 2, 2017 at 2:08 PM, Quentin Schulz
>>>
To prepare for patches that will add support for a new PMIC that has a
different GPIO input status register, add a gpio_status_offset within
axp20x_pctl structure and use it.
Signed-off-by: Quentin Schulz
---
drivers/pinctrl/pinctrl-axp209.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion
.
Signed-off-by: Quentin Schulz
---
drivers/pinctrl/pinctrl-axp209.c | 178 +++
1 file changed, 89 insertions(+), 89 deletions(-)
diff --git a/drivers/pinctrl/pinctrl-axp209.c b/drivers/pinctrl/pinctrl-axp209.c
index 96ef0cc28762..3ddeba45feed 100644
--- a/drivers
As GPIO/pinctrl driver now supports AXP813, add a cell for it.
Signed-off-by: Quentin Schulz
---
drivers/mfd/axp20x.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/mfd/axp20x.c b/drivers/mfd/axp20x.c
index 2468b431bb22..d8c92fbbd170 100644
--- a/drivers/mfd/axp20x.c
+++ b
The AXP813 has only two GPIOs. GPIO0 can either be used as a GPIO, an
LDO regulator or an ADC. GPIO1 can be used either as a GPIO or an LDO
regulator.
Moreover, the status bit of the GPIOs when in input mode is not offset
by 4 unlike the AXP209.
Signed-off-by: Quentin Schulz
---
.../devicetree
This board has an AXP813 PMIC so let's include its dtsi.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/sun8i-a83t-tbs-a711.dts | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/arch/arm/boot/dts/sun8i-a83t-tbs-a711.dts
b/arch/arm/boot/dts/sun8i-a83t-tbs-a71
On AXP813/818, GPIO0 and GPIO1 can be used as LDO as (respectively)
ldo_io0 and ldo_io1.
Let's add the pinctrl properties to the said regulators.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/axp81x.dtsi | 14 ++
1 file changed, 14 insertions(+)
diff --git a/arch/arm
This board has an AXP818 PMIC so let's include its dtsi.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/sun8i-a83t-allwinner-h8homlet-v2.dts | 2 ++
1 file changed, 2 insertions(+)
diff --git a/arch/arm/boot/dts/sun8i-a83t-allwinner-h8homlet-v2.dts
b/arch/arm/boot/dts/sun8i
This board has an AXP818 PMIC so let's include its dtsi.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/sun8i-a83t-cubietruck-plus.dts | 2 ++
1 file changed, 2 insertions(+)
diff --git a/arch/arm/boot/dts/sun8i-a83t-cubietruck-plus.dts
b/arch/arm/boot/dts/sun8i-a83t-cubietruck-plu
This adds DT node for the GPIO/pinctrl part present in AXP813/AXP818.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/axp81x.dtsi | 6 ++
1 file changed, 6 insertions(+)
diff --git a/arch/arm/boot/dts/axp81x.dtsi b/arch/arm/boot/dts/axp81x.dtsi
index 73b761f850c5..f90f257130d5 100644
To prepare the driver for the upcoming pinctrl features, move the GPIO
driver AXP209 from GPIO to pinctrl subsystem.
Signed-off-by: Quentin Schulz
---
.../bindings/{gpio/gpio-axp209.txt => pinctrl/pinctrl-axp209.txt} | 0
drivers/gpio/Kconfig
egulators,
v2:
- add support for AXP813 pins,
- split into more patches so it is easier to follow the modifications,
- reorder of some patches,
- register all pins within the same range instead of a range per pin,
[1] https://www.spinics.net/lists/arm-kernel/msg608384.html
Thanks,
Quentin
Q
The X-Powers AXP209 has 3 GPIOs. GPIO0/1 can each act either as a GPIO,
an ADC or a LDO regulator. GPIO2 can only act as a GPIO.
This adds the pinctrl features to the driver so GPIO0/1 can be used as
ADC or LDO regulator.
Signed-off-by: Quentin Schulz
---
.../devicetree/bindings/pinctrl
This board has an AXP813 PMIC so let's include its dtsi.
Signed-off-by: Quentin Schulz
---
arch/arm/boot/dts/sun8i-a83t-bananapi-m3.dts | 2 ++
1 file changed, 2 insertions(+)
diff --git a/arch/arm/boot/dts/sun8i-a83t-bananapi-m3.dts
b/arch/arm/boot/dts/sun8i-a83t-bananapi-m3.dts
---
> Date: Fri, 29 Sep 2017 20:00:03 +0800
> From: kbuild test robot
> To: kbu...@01.org
> Cc: Julia Lawall
> Subject: Re: [PATCH v2 02/10] pinctrl: axp209: add pinctrl features
>
> Hi Quentin,
>
> [auto build test WARNING on ]
>
> url:
> https://github.
On 26/09/2017 15:27, Maxime Ripard wrote:
> On Tue, Sep 26, 2017 at 01:08:21PM +0000, Quentin Schulz wrote:
>> Hi Maxime,
>>
>> On 26/09/2017 15:00, Maxime Ripard wrote:
>>> On Tue, Sep 26, 2017 at 12:17:12PM +, Quentin Schulz wrote:
>>>> +stati
Hi Maxime,
On 26/09/2017 15:01, Maxime Ripard wrote:
> On Tue, Sep 26, 2017 at 12:17:13PM +0000, Quentin Schulz wrote:
>> Instead of using a function to retrieve each pin's correct control
>> register, use drv_data within pinctrl_pin_desc to store the ctrl reg.
>>
>
Hi Maxime,
On 26/09/2017 15:00, Maxime Ripard wrote:
> On Tue, Sep 26, 2017 at 12:17:12PM +0000, Quentin Schulz wrote:
>> +static const struct axp20x_desc_pin axp209_pins[] = {
>> +AXP20X_PIN(AXP20X_PINCTRL_PIN(0, "GPIO0"),
>> +
Hi Maxime,
On 26/09/2017 14:55, Maxime Ripard wrote:
> On Tue, Sep 26, 2017 at 12:17:11PM +0000, Quentin Schulz wrote:
>> To prepare the driver for the upcoming pinctrl features, move the GPIO
>> driver AXP209 from GPIO to pinctrl subsystem.
>>
>> Signed-off-by: Quenti
hot temperature,
forcing the thermal framework to shutdown the board.
Signed-off-by: Quentin Schulz
---
drivers/iio/adc/sun4i-gpadc-iio.c | 34 ++--
1 file changed, 15 insertions(+), 19 deletions(-)
diff --git a/drivers/iio/adc/sun4i-gpadc-iio.c
b/drivers/iio/adc/sun4i-gp
eason (waiting for other drivers
for example) so check on ENODEV only.
Signed-off-by: Quentin Schulz
---
drivers/iio/adc/sun4i-gpadc-iio.c | 6 +-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/drivers/iio/adc/sun4i-gpadc-iio.c
b/drivers/iio/adc/sun4i-gpadc-iio.c
index 392d47f..46
Instead of using a function to retrieve each pin's correct control
register, use drv_data within pinctrl_pin_desc to store the ctrl reg.
Remove axp20x_gpio_get_reg and replace every occurrence by a get from
drv_data.
Signed-off-by: Quentin Schulz
---
drivers/pinctrl/pinctrl-axp209.c
.
Signed-off-by: Quentin Schulz
---
drivers/pinctrl/pinctrl-axp209.c | 198
1 file changed, 99 insertions(+), 99 deletions(-)
diff --git a/drivers/pinctrl/pinctrl-axp209.c b/drivers/pinctrl/pinctrl-axp209.c
index 4bbcba2..4be1aca 100644
--- a/drivers/pinctrl/pinctrl
The X-Powers AXP209 has 3 GPIOs. GPIO0/1 can each act either as a GPIO,
an ADC or a LDO regulator. GPIO2 can only act as a GPIO.
This adds the pinctrl features to the driver so GPIO0/1 can be used as
ADC or LDO regulator.
Signed-off-by: Quentin Schulz
---
Documentation/devicetree/bindings
101 - 200 of 655 matches
Mail list logo