Skip to contentSkip to conversation

mfd: lp87565: Add lp87565 PMIC support

PATCH Superseded Keerthy 4 participants 9 messages Jun 8, 2017 – Jun 15, 2017

Subsystems (2)

v4 of 5 Superseded Latest is v5 →

lore
Share & tools
lore

Keerthy

author
#0 lore raw

PATCH v4 1/1 mfd: lp87565: Add lp87565 PMIC support

The LP87565 chip is a power management IC for Portable Navigation Systems and Tablet Computing devices. It contains the following components:

- Configurable Bucks(Single and multi-phase).
- Configurable General Purpose Output Signals (GPO).

The LP87565-Q1 variant device uses two 2-phase outputs configuration, Buck0 is master for Buck0/1 output and Buck2 is master for Buck2/3 output.

---

The other patches are already pulled by Mark. Hence posting the remaining patch.

Changes in v4:

* Fixed device tree comments from Rob on the pmic node name.
* removed regulators from properties list as it is a node.

Changes in v3:

* Fixed License to GPL v2.
* Fixed an indentation issue.

Changes in v2:

* Fixed a bunch of whitespace errors.
* Changed the License to short form.
* Added the generic compatible lp87565
* Removed i2c_device_id table.
* Introduced probe_new function in place of probe.

 Documentation/devicetree/bindings/mfd/lp87565.txt |  43 ++++
 drivers/mfd/Kconfig                               |  14 ++
 drivers/mfd/Makefile                              |   1 +
 drivers/mfd/lp87565.c                             |  92 ++++++++
 include/linux/mfd/lp87565.h                       | 270 ++++++++++++++++++++++
 5 files changed, 420 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/mfd/lp87565.txt
 create mode 100644 drivers/mfd/lp87565.c
 create mode 100644 include/linux/mfd/lp87565.h
Documentation/devicetree/bindings/mfd/lp87565.txt new file +43 -0
new file mode 100644
index 0000000..a48df7c
@@ -0,0 +1,43 @@
+TI LP87565 PMIC MFD driver
+
+Required properties:
+  - compatible:	"ti,lp87565", "ti,lp87565-q1"
+  - reg:		I2C slave address.
+  - gpio-controller:	Marks the device node as a GPIO Controller.
+  - #gpio-cells:	Should be two.  The first cell is the pin number and
+			the second cell is used to specify flags.
+			See ../gpio/gpio.txt for more information.
+  - xxx-in-supply:	Phandle to parent supply node of each regulator
+			populated under regulators node. xxx should match
+			the supply_name populated in driver.
+Example:
+
+lp87565_pmic: pmic@60 {
+	compatible = "ti,lp87565-q1";
+	reg = <0x60>;
+	gpio-controller;
+	#gpio-cells = <2>;
+
+	buck10-in-supply = <&vsys_3v3>;
+	buck23-in-supply = <&vsys_3v3>;
+
+	regulators: regulators {
+		buck10_reg: buck10 {
+			/* VDD_MPU */
+			regulator-name = "buck10";
+			regulator-min-microvolt = <850000>;
+			regulator-max-microvolt = <1250000>;
+			regulator-always-on;
+			regulator-boot-on;
+		};
+
+		buck23_reg: buck23 {
+			/* VDD_GPU */
+			regulator-name = "buck23";
+			regulator-min-microvolt = <850000>;
+			regulator-max-microvolt = <1250000>;
+			regulator-boot-on;
+			regulator-always-on;
+		};
+	};
+};
drivers/mfd/Kconfig +14 -0
index 95e8683..568082f 100644
@@ -1354,6 +1354,20 @@ config MFD_TI_LP873X
 	  This driver can also be built as a module. If so, the module
 	  will be called lp873x.
 
+config MFD_TI_LP87565
+	tristate "TI LP87565 Power Management IC"
+	depends on I2C && OF
+	select MFD_CORE
+	select REGMAP_I2C
+	help
+	  If you say yes here then you get support for the LP87565 series of
+	  Power Management Integrated Circuits (PMIC).
+	  These include voltage regulators, thermal protection, configurable
+	  General Purpose Outputs (GPO) that are used in portable devices.
+
+	  This driver can also be built as a module. If so, the module
+	  will be called lp87565.
+
 config MFD_TPS65218
 	tristate "TI TPS65218 Power Management chips"
 	depends on I2C
drivers/mfd/Makefile +1 -0
index 6f6aed8..080793b 100644
@@ -25,6 +25,7 @@ obj-$(CONFIG_HTC_PASIC3)	+= htc-pasic3.o
 obj-$(CONFIG_HTC_I2CPLD)	+= htc-i2cpld.o
 
 obj-$(CONFIG_MFD_TI_LP873X)	+= lp873x.o
+obj-$(CONFIG_MFD_TI_LP87565)	+= lp87565.o
 
 obj-$(CONFIG_MFD_DAVINCI_VOICECODEC)	+= davinci_voicecodec.o
 obj-$(CONFIG_MFD_DM355EVM_MSP)	+= dm355evm_msp.o
drivers/mfd/lp87565.c new file +92 -0

92 lines not on this page · raw message

include/linux/mfd/lp87565.h new file +270 -0

270 lines not on this page · raw message

Signature · 1 line
1.9.1
maintainer Acked-by on v4 1/1
#1 lore raw
Quoted 28 lines · Keerthy

The LP87565 chip is a power management IC for Portable Navigation Systems and Tablet Computing devices. It contains the following components:

- Configurable Bucks(Single and multi-phase).
- Configurable General Purpose Output Signals (GPO).

The LP87565-Q1 variant device uses two 2-phase outputs configuration, Buck0 is master for Buck0/1 output and Buck2 is master for Buck2/3 output.

---

The other patches are already pulled by Mark. Hence posting the remaining patch.

Changes in v4:

* Fixed device tree comments from Rob on the pmic node name.
* removed regulators from properties list as it is a node.

Changes in v3:

* Fixed License to GPL v2.
* Fixed an indentation issue.

Changes in v2:

Quoted 7 lines

* Fixed a bunch of whitespace errors.
* Changed the License to short form.
* Added the generic compatible lp87565
* Removed i2c_device_id table.
* Introduced probe_new function in place of probe.

 Documentation/devicetree/bindings/mfd/lp87565.txt |  43 ++++
Quoted 8 lines
 drivers/mfd/Kconfig                               |  14 ++
 drivers/mfd/Makefile                              |   1 +
 drivers/mfd/lp87565.c                             |  92 ++++++++
 include/linux/mfd/lp87565.h                       | 270 ++++++++++++++++++++++
 5 files changed, 420 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/mfd/lp87565.txt
 create mode 100644 drivers/mfd/lp87565.c
 create mode 100644 include/linux/mfd/lp87565.h

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

author
#2 lore raw
Quoted 35 lines · Rob Herring
Quoted 34 lines · Keerthy

The LP87565 chip is a power management IC for Portable Navigation Systems and Tablet Computing devices. It contains the following components:

- Configurable Bucks(Single and multi-phase).
- Configurable General Purpose Output Signals (GPO).

The LP87565-Q1 variant device uses two 2-phase outputs configuration, Buck0 is master for Buck0/1 output and Buck2 is master for Buck2/3 output.

---

The other patches are already pulled by Mark. Hence posting the remaining patch.

Changes in v4:

* Fixed device tree comments from Rob on the pmic node name.
* removed regulators from properties list as it is a node.

Changes in v3:

* Fixed License to GPL v2.
* Fixed an indentation issue.

Changes in v2:

* Fixed a bunch of whitespace errors.
* Changed the License to short form.
* Added the generic compatible lp87565
* Removed i2c_device_id table.
* Introduced probe_new function in place of probe.

Quoted 3 lines
Quoted 1 line
 Documentation/devicetree/bindings/mfd/lp87565.txt |  43 ++++

Thanks Rob.

Quoted 9 lines
Quoted 9 lines
 drivers/mfd/Kconfig                               |  14 ++
 drivers/mfd/Makefile                              |   1 +
 drivers/mfd/lp87565.c                             |  92 ++++++++
 include/linux/mfd/lp87565.h                       | 270 ++++++++++++++++++++++
 5 files changed, 420 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/mfd/lp87565.txt
 create mode 100644 drivers/mfd/lp87565.c
 create mode 100644 include/linux/mfd/lp87565.h

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

author
#3 lore raw
Quoted 7 lines · Keerthy
Quoted 4 lines · Rob Herring
Quoted 3 lines · Keerthy

The LP87565 chip is a power management IC for Portable Navigation Systems and Tablet Computing devices. It contains the following components:

Quoted 7 lines
Quoted 7 lines
Quoted 7 lines

- Configurable Bucks(Single and multi-phase).
- Configurable General Purpose Output Signals (GPO).

The LP87565-Q1 variant device uses two 2-phase outputs configuration, Buck0 is master for Buck0/1 output and Buck2 is master for Buck2/3 output.

Lee Jones,

Shall i add back i2c_device_id as pointed here:
http://www.mail-archive.com/[email protected]/msg1417316.html

Best Regards,
Keerthy

Quoted 39 lines
Quoted 24 lines
Quoted 24 lines

---

The other patches are already pulled by Mark. Hence posting the remaining patch.

Changes in v4:

* Fixed device tree comments from Rob on the pmic node name.
* removed regulators from properties list as it is a node.

Changes in v3:

* Fixed License to GPL v2.
* Fixed an indentation issue.

Changes in v2:

* Fixed a bunch of whitespace errors.
* Changed the License to short form.
* Added the generic compatible lp87565
* Removed i2c_device_id table.
* Introduced probe_new function in place of probe.

Quoted 3 lines
Quoted 1 line
 Documentation/devicetree/bindings/mfd/lp87565.txt |  43 ++++

Thanks Rob.

Quoted 9 lines
Quoted 9 lines
 drivers/mfd/Kconfig                               |  14 ++
 drivers/mfd/Makefile                              |   1 +
 drivers/mfd/lp87565.c                             |  92 ++++++++
 include/linux/mfd/lp87565.h                       | 270 ++++++++++++++++++++++
 5 files changed, 420 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/mfd/lp87565.txt
 create mode 100644 drivers/mfd/lp87565.c
 create mode 100644 include/linux/mfd/lp87565.h
Quoted 5 lines

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

#4 lore raw
Quoted 18 lines · Keerthy
Quoted 7 lines · Keerthy
Quoted 4 lines · Rob Herring
Quoted 3 lines · Keerthy

The LP87565 chip is a power management IC for Portable Navigation Systems and Tablet Computing devices. It contains the following components:

Quoted 7 lines
Quoted 7 lines
Quoted 7 lines

- Configurable Bucks(Single and multi-phase).
- Configurable General Purpose Output Signals (GPO).

The LP87565-Q1 variant device uses two 2-phase outputs configuration, Buck0 is master for Buck0/1 output and Buck2 is master for Buck2/3 output.

Quoted 4 lines

Lee Jones,

Shall i add back i2c_device_id as pointed here:
http://www.mail-archive.com/[email protected]/msg1417316.html

Hasn't that been fixed yet?

I guess so then. :(

Quoted 39 lines
Quoted 39 lines
Quoted 24 lines
Quoted 24 lines

---

The other patches are already pulled by Mark. Hence posting the remaining patch.

Changes in v4:

* Fixed device tree comments from Rob on the pmic node name.
* removed regulators from properties list as it is a node.

Changes in v3:

* Fixed License to GPL v2.
* Fixed an indentation issue.

Changes in v2:

* Fixed a bunch of whitespace errors.
* Changed the License to short form.
* Added the generic compatible lp87565
* Removed i2c_device_id table.
* Introduced probe_new function in place of probe.

Quoted 3 lines
Quoted 1 line
 Documentation/devicetree/bindings/mfd/lp87565.txt |  43 ++++

Thanks Rob.

Quoted 9 lines
Quoted 9 lines
 drivers/mfd/Kconfig                               |  14 ++
 drivers/mfd/Makefile                              |   1 +
 drivers/mfd/lp87565.c                             |  92 ++++++++
 include/linux/mfd/lp87565.h                       | 270 ++++++++++++++++++++++
 5 files changed, 420 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/mfd/lp87565.txt
 create mode 100644 drivers/mfd/lp87565.c
 create mode 100644 include/linux/mfd/lp87565.h
Signature · 4 lines
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
author
#5 lore raw
Quoted 20 lines · Lee Jones
Quoted 18 lines · Keerthy
Quoted 14 lines · Keerthy
Quoted 11 lines · Rob Herring
Quoted 10 lines · Keerthy

The LP87565 chip is a power management IC for Portable Navigation Systems and Tablet Computing devices. It contains the following components:

- Configurable Bucks(Single and multi-phase).
- Configurable General Purpose Output Signals (GPO).

The LP87565-Q1 variant device uses two 2-phase outputs configuration, Buck0 is master for Buck0/1 output and Buck2 is master for Buck2/3 output.

Quoted 8 lines
Quoted 4 lines

Lee Jones,

Shall i add back i2c_device_id as pointed here:
http://www.mail-archive.com/[email protected]/msg1417316.html

Hasn't that been fixed yet?

I guess so then. :(

Okay. So with that i assume i should reintroduce probe instead of probe_new.

Quoted 32 lines
Quoted 32 lines
Quoted 32 lines
Quoted 25 lines
Quoted 25 lines

---

The other patches are already pulled by Mark. Hence posting the remaining patch.

Changes in v4:

* Fixed device tree comments from Rob on the pmic node name.
* removed regulators from properties list as it is a node.

Changes in v3:

* Fixed License to GPL v2.
* Fixed an indentation issue.

Changes in v2:

* Fixed a bunch of whitespace errors.
* Changed the License to short form.
* Added the generic compatible lp87565
* Removed i2c_device_id table.
* Introduced probe_new function in place of probe.

Quoted 3 lines
Quoted 1 line
 Documentation/devicetree/bindings/mfd/lp87565.txt |  43 ++++

Thanks Rob.

Quoted 1 line
Quoted 9 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
 drivers/mfd/Kconfig                               |  14 ++
 drivers/mfd/Makefile                              |   1 +
 drivers/mfd/lp87565.c                             |  92 ++++++++
 include/linux/mfd/lp87565.h                       | 270 ++++++++++++++++++++++
 5 files changed, 420 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/mfd/lp87565.txt
 create mode 100644 drivers/mfd/lp87565.c
 create mode 100644 include/linux/mfd/lp87565.h

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

#6 lore raw

Hello Lee and Keerthy,

Quoted 23 lines · Keerthy
Quoted 20 lines · Lee Jones
Quoted 18 lines · Keerthy
Quoted 14 lines · Keerthy
Quoted 11 lines · Rob Herring
Quoted 10 lines · Keerthy

The LP87565 chip is a power management IC for Portable Navigation Systems and Tablet Computing devices. It contains the following components:

- Configurable Bucks(Single and multi-phase).
- Configurable General Purpose Output Signals (GPO).

The LP87565-Q1 variant device uses two 2-phase outputs configuration, Buck0 is master for Buck0/1 output and Buck2 is master for Buck2/3 output.

Quoted 7 lines
Quoted 7 lines
Quoted 4 lines

Lee Jones,

Shall i add back i2c_device_id as pointed here:
http://www.mail-archive.com/[email protected]/msg1417316.html

Hasn't that been fixed yet?

There are only 2 patch series remaining to be merged so we can finally fix this in the I2C core, making sure that no drivers will be regressed. One of the series is for MFD and have been around for a while (it already contains all the relevant acks AFAICT), it would be very helpful if you can look at it and merge if you think is correct:

https://lkml.org/lkml/2017/5/4/11

Quoted 4 lines
Quoted 1 line

I guess so then. :(

Okay. So with that i assume i should reintroduce probe instead of probe_new.

It's orthogonal, you can have probe_new and also the I2C device ID table (the OF table will be used for matching, you just need the I2C table to export the aliases with MODULE_DEVICE_TABLE(i2c,.. ).

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

author
#7 lore raw
Quoted 42 lines · Javier Martinez Canillas

Hello Lee and Keerthy,

Quoted 23 lines · Keerthy
Quoted 20 lines · Lee Jones
Quoted 18 lines · Keerthy
Quoted 14 lines · Keerthy
Quoted 11 lines · Rob Herring
Quoted 10 lines · Keerthy

The LP87565 chip is a power management IC for Portable Navigation Systems and Tablet Computing devices. It contains the following components:

- Configurable Bucks(Single and multi-phase).
- Configurable General Purpose Output Signals (GPO).

The LP87565-Q1 variant device uses two 2-phase outputs configuration, Buck0 is master for Buck0/1 output and Buck2 is master for Buck2/3 output.

Quoted 7 lines
Quoted 7 lines
Quoted 4 lines

Lee Jones,

Shall i add back i2c_device_id as pointed here:
http://www.mail-archive.com/[email protected]/msg1417316.html

Hasn't that been fixed yet?

There are only 2 patch series remaining to be merged so we can finally fix this in the I2C core, making sure that no drivers will be regressed. One of the series is for MFD and have been around for a while (it already contains all the relevant acks AFAICT), it would be very helpful if you can look at it and merge if you think is correct:

https://lkml.org/lkml/2017/5/4/11

Quoted 8 lines
Quoted 4 lines
Quoted 1 line

I guess so then. :(

Okay. So with that i assume i should reintroduce probe instead of probe_new.

It's orthogonal, you can have probe_new and also the I2C device ID table (the OF table will be used for matching, you just need the I2C table to export the aliases with MODULE_DEVICE_TABLE(i2c,.. ).

I believe the whole purpose of comments on probe_new was to remove the i2c device ID. With that needed i will stick to probe for now and once the above series mentioned by you gets in and all the dependencies for probe_new are cleared i will send out a separate patch.

Quoted 4 lines

Best regards,
Javier

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

#8 lore raw
In reply to Javier Martinez Canillas
Quoted 34 lines · Javier Martinez Canillas

Hello Lee and Keerthy,

Quoted 23 lines · Keerthy
Quoted 20 lines · Lee Jones
Quoted 18 lines · Keerthy
Quoted 14 lines · Keerthy
Quoted 11 lines · Rob Herring
Quoted 10 lines · Keerthy

The LP87565 chip is a power management IC for Portable Navigation Systems and Tablet Computing devices. It contains the following components:

- Configurable Bucks(Single and multi-phase).
- Configurable General Purpose Output Signals (GPO).

The LP87565-Q1 variant device uses two 2-phase outputs configuration, Buck0 is master for Buck0/1 output and Buck2 is master for Buck2/3 output.

Quoted 7 lines
Quoted 7 lines
Quoted 4 lines

Lee Jones,

Shall i add back i2c_device_id as pointed here:
http://www.mail-archive.com/[email protected]/msg1417316.html

Hasn't that been fixed yet?

Quoted 7 lines

There are only 2 patch series remaining to be merged so we can finally fix this in the I2C core, making sure that no drivers will be regressed. One of the series is for MFD and have been around for a while (it already contains all the relevant acks AFAICT), it would be very helpful if you can look at it and merge if you think is correct:

https://lkml.org/lkml/2017/5/4/11

Please use the normal procedure and [RESEND].

Quoted 11 lines
Quoted 4 lines
Quoted 1 line

I guess so then. :(

Okay. So with that i assume i should reintroduce probe instead of probe_new.

It's orthogonal, you can have probe_new and also the I2C device ID table (the OF table will be used for matching, you just need the I2C table to export the aliases with MODULE_DEVICE_TABLE(i2c,.. ).

Best regards,
Javier

Signature · 8 lines
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html