All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 00/11] OMAP4: Add DT support for i2c and twl6030
@ 2011-12-20 16:27 ` Benoit Cousson
  0 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: rob.herring, tony
  Cc: linux-omap, linux-arm-kernel, devicetree-discuss, grant.likely,
	Benoit Cousson

Hi Tony and Rob,

Here is the updated version of the i2c + twl DT adaptation series.

This update, compared to v2 [1], is adding some dedicated dtsi files for
the twl PMIC and audio IC. These devices will contain a huge amount of
regulator nodes and thus deserve a dedicated file to avoid every boards
to redefine the same data.
The twl patch is now included in Samuel's for-next branch and thus dropped
from this update.
The i2c binding was cleaned as suggested by Rob to avoid all the ugly
hexa flags inside the DTS.

The pm.c was updated to prevent the SR / VP initialization in the DT
context since none of them is DT aware for the moment.

A couple of basic i2c devices are added for panda, beagle and sdp board.

Patches are based on for_3.3/2_dt_irq, to get the latest GIC binding,
and are available here:
git://gitorious.org/omap-pm/linux.git for_3.3/3_omap_dt_i2c_twl

Tested on Beagle and sdp4430.

Comments are welcome.

Regards,
Benoit

[1] http://www.spinics.net/lists/linux-omap/msg61260.html


Benoit Cousson (11):
  ARM: OMAP2+: pm: Do not init statically the SR and voltage layer with DT
  i2c: OMAP: Add DT support for i2c controller
  rtc: rtc-twl: Add DT support for RTC inside twl4030/twl6030
  arm/dts: OMAP4: Add i2c controller nodes
  arm/dts: OMAP3: Add i2c controller nodes
  arm/dts: twl6030: Add DTS file for twl6030 PMIC
  arm/dts: twl4030: Add DTS file for twl4030 PM + Audio IC
  arm/dts: omap4-panda: Add twl6030 and i2c EEPROM
  arm/dts: omap4-sdp: Add twl6030, i2c3 and i2c4 devices
  arm/dts: omap3-beagle: Add twl4030 and i2c EEPROM
  ARM: OMAP2+: board-generic: Remove i2c static init

 Documentation/devicetree/bindings/i2c/omap-i2c.txt |   30 ++++++
 Documentation/devicetree/bindings/rtc/twl-rtc.txt  |   12 +++
 arch/arm/boot/dts/omap3-beagle.dts                 |   29 ++++++
 arch/arm/boot/dts/omap3.dtsi                       |   21 ++++
 arch/arm/boot/dts/omap4-panda.dts                  |   34 +++++++
 arch/arm/boot/dts/omap4-sdp.dts                    |   53 ++++++++++
 arch/arm/boot/dts/omap4.dtsi                       |   28 ++++++
 arch/arm/boot/dts/twl4030.dtsi                     |   21 ++++
 arch/arm/boot/dts/twl6030.dtsi                     |   22 ++++
 arch/arm/mach-omap2/board-generic.c                |   48 +---------
 arch/arm/mach-omap2/pm.c                           |    8 ++
 drivers/i2c/busses/i2c-omap.c                      |  101 +++++++++++++-------
 drivers/rtc/rtc-twl.c                              |   10 ++-
 13 files changed, 334 insertions(+), 83 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/i2c/omap-i2c.txt
 create mode 100644 Documentation/devicetree/bindings/rtc/twl-rtc.txt
 create mode 100644 arch/arm/boot/dts/twl4030.dtsi
 create mode 100644 arch/arm/boot/dts/twl6030.dtsi


^ permalink raw reply	[flat|nested] 40+ messages in thread

* [PATCH v3 00/11] OMAP4: Add DT support for i2c and twl6030
@ 2011-12-20 16:27 ` Benoit Cousson
  0 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Tony and Rob,

Here is the updated version of the i2c + twl DT adaptation series.

This update, compared to v2 [1], is adding some dedicated dtsi files for
the twl PMIC and audio IC. These devices will contain a huge amount of
regulator nodes and thus deserve a dedicated file to avoid every boards
to redefine the same data.
The twl patch is now included in Samuel's for-next branch and thus dropped
from this update.
The i2c binding was cleaned as suggested by Rob to avoid all the ugly
hexa flags inside the DTS.

The pm.c was updated to prevent the SR / VP initialization in the DT
context since none of them is DT aware for the moment.

A couple of basic i2c devices are added for panda, beagle and sdp board.

Patches are based on for_3.3/2_dt_irq, to get the latest GIC binding,
and are available here:
git://gitorious.org/omap-pm/linux.git for_3.3/3_omap_dt_i2c_twl

Tested on Beagle and sdp4430.

Comments are welcome.

Regards,
Benoit

[1] http://www.spinics.net/lists/linux-omap/msg61260.html


Benoit Cousson (11):
  ARM: OMAP2+: pm: Do not init statically the SR and voltage layer with DT
  i2c: OMAP: Add DT support for i2c controller
  rtc: rtc-twl: Add DT support for RTC inside twl4030/twl6030
  arm/dts: OMAP4: Add i2c controller nodes
  arm/dts: OMAP3: Add i2c controller nodes
  arm/dts: twl6030: Add DTS file for twl6030 PMIC
  arm/dts: twl4030: Add DTS file for twl4030 PM + Audio IC
  arm/dts: omap4-panda: Add twl6030 and i2c EEPROM
  arm/dts: omap4-sdp: Add twl6030, i2c3 and i2c4 devices
  arm/dts: omap3-beagle: Add twl4030 and i2c EEPROM
  ARM: OMAP2+: board-generic: Remove i2c static init

 Documentation/devicetree/bindings/i2c/omap-i2c.txt |   30 ++++++
 Documentation/devicetree/bindings/rtc/twl-rtc.txt  |   12 +++
 arch/arm/boot/dts/omap3-beagle.dts                 |   29 ++++++
 arch/arm/boot/dts/omap3.dtsi                       |   21 ++++
 arch/arm/boot/dts/omap4-panda.dts                  |   34 +++++++
 arch/arm/boot/dts/omap4-sdp.dts                    |   53 ++++++++++
 arch/arm/boot/dts/omap4.dtsi                       |   28 ++++++
 arch/arm/boot/dts/twl4030.dtsi                     |   21 ++++
 arch/arm/boot/dts/twl6030.dtsi                     |   22 ++++
 arch/arm/mach-omap2/board-generic.c                |   48 +---------
 arch/arm/mach-omap2/pm.c                           |    8 ++
 drivers/i2c/busses/i2c-omap.c                      |  101 +++++++++++++-------
 drivers/rtc/rtc-twl.c                              |   10 ++-
 13 files changed, 334 insertions(+), 83 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/i2c/omap-i2c.txt
 create mode 100644 Documentation/devicetree/bindings/rtc/twl-rtc.txt
 create mode 100644 arch/arm/boot/dts/twl4030.dtsi
 create mode 100644 arch/arm/boot/dts/twl6030.dtsi

^ permalink raw reply	[flat|nested] 40+ messages in thread

* [PATCH v3 01/11] ARM: OMAP2+: pm: Do not init statically the SR and voltage layer with DT
  2011-12-20 16:27 ` Benoit Cousson
@ 2011-12-20 16:27   ` Benoit Cousson
  -1 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: rob.herring, tony
  Cc: linux-omap, linux-arm-kernel, devicetree-discuss, grant.likely,
	Benoit Cousson

In the case of DT, the PMIC and SR initialization will be done using
a completely different mechanism.

Disable this part if a DT blob is available.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Acked-by: Kevin Hilman <khilman@ti.com>
---
 arch/arm/mach-omap2/pm.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/arch/arm/mach-omap2/pm.c b/arch/arm/mach-omap2/pm.c
index 1881fe9..ad4f693 100644
--- a/arch/arm/mach-omap2/pm.c
+++ b/arch/arm/mach-omap2/pm.c
@@ -227,6 +227,14 @@ postcore_initcall(omap2_common_pm_init);
 
 static int __init omap2_common_pm_late_init(void)
 {
+	/*
+	 * In the case of DT, the PMIC and SR initialization will be done using
+	 * a completely different mechanism.
+	 * Disable this part if a DT blob is available.
+	 */
+	if (of_have_populated_dt())
+		return 0;
+
 	/* Init the voltage layer */
 	omap_pmic_late_init();
 	omap_voltage_late_init();
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 01/11] ARM: OMAP2+: pm: Do not init statically the SR and voltage layer with DT
@ 2011-12-20 16:27   ` Benoit Cousson
  0 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: linux-arm-kernel

In the case of DT, the PMIC and SR initialization will be done using
a completely different mechanism.

Disable this part if a DT blob is available.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Acked-by: Kevin Hilman <khilman@ti.com>
---
 arch/arm/mach-omap2/pm.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/arch/arm/mach-omap2/pm.c b/arch/arm/mach-omap2/pm.c
index 1881fe9..ad4f693 100644
--- a/arch/arm/mach-omap2/pm.c
+++ b/arch/arm/mach-omap2/pm.c
@@ -227,6 +227,14 @@ postcore_initcall(omap2_common_pm_init);
 
 static int __init omap2_common_pm_late_init(void)
 {
+	/*
+	 * In the case of DT, the PMIC and SR initialization will be done using
+	 * a completely different mechanism.
+	 * Disable this part if a DT blob is available.
+	 */
+	if (of_have_populated_dt())
+		return 0;
+
 	/* Init the voltage layer */
 	omap_pmic_late_init();
 	omap_voltage_late_init();
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 02/11] i2c: OMAP: Add DT support for i2c controller
  2011-12-20 16:27 ` Benoit Cousson
@ 2011-12-20 16:27   ` Benoit Cousson
  -1 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: rob.herring, tony
  Cc: linux-omap, linux-arm-kernel, devicetree-discuss, grant.likely,
	Benoit Cousson, Ben Dooks, Kevin Hilman

Add initial DT support to retrieve the frequency using a
DT attribute instead of the pdata pointer if of_node exist.

Add documentation for omap i2c controller binding.

Based on original patches from Manju and Grant.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Ben Dooks <ben-linux@fluff.org>
Cc: Kevin Hilman <khilman@ti.com>
---
 Documentation/devicetree/bindings/i2c/omap-i2c.txt |   30 ++++++
 drivers/i2c/busses/i2c-omap.c                      |  101 +++++++++++++-------
 2 files changed, 96 insertions(+), 35 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/i2c/omap-i2c.txt

diff --git a/Documentation/devicetree/bindings/i2c/omap-i2c.txt b/Documentation/devicetree/bindings/i2c/omap-i2c.txt
new file mode 100644
index 0000000..56564aa
--- /dev/null
+++ b/Documentation/devicetree/bindings/i2c/omap-i2c.txt
@@ -0,0 +1,30 @@
+I2C for OMAP platforms
+
+Required properties :
+- compatible : Must be "ti,omap3-i2c" or "ti,omap4-i2c"
+- ti,hwmods : Must be "i2c<n>", n being the instance number (1-based)
+- #address-cells = <1>;
+- #size-cells = <0>;
+
+Recommended properties :
+- clock-frequency : Desired I2C bus clock frequency in Hz. Otherwise
+  the default 100 kHz frequency will be used.
+
+Optional properties:
+- Child nodes conforming to i2c bus binding
+
+Note: Current implementation will fetch base address, irq and dma
+from omap hwmod data base during device registration.
+Future plan is to migrate hwmod data base contents into device tree
+blob so that, all the required data will be used from device tree dts
+file.
+
+Examples :
+
+i2c1: i2c@0 {
+    compatible = "ti,omap3-i2c";
+    #address-cells = <1>;
+    #size-cells = <0>;
+    ti,hwmods = "i2c1";
+    clock-frequency = <400000>;
+};
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index a43d002..dcbc1ec 100644
--- a/drivers/i2c/busses/i2c-omap.c
+++ b/drivers/i2c/busses/i2c-omap.c
@@ -37,6 +37,8 @@
 #include <linux/platform_device.h>
 #include <linux/clk.h>
 #include <linux/io.h>
+#include <linux/of_i2c.h>
+#include <linux/of_device.h>
 #include <linux/slab.h>
 #include <linux/i2c-omap.h>
 #include <linux/pm_runtime.h>
@@ -182,7 +184,9 @@ struct omap_i2c_dev {
 	u32			latency;	/* maximum mpu wkup latency */
 	void			(*set_mpu_wkup_lat)(struct device *dev,
 						    long latency);
-	u32			speed;		/* Speed of bus in Khz */
+	u32			speed;		/* Speed of bus in kHz */
+	u32			dtrev;		/* extra revision from DT */
+	u32			flags;
 	u16			cmd_err;
 	u8			*buf;
 	u8			*regs;
@@ -266,11 +270,7 @@ static inline u16 omap_i2c_read_reg(struct omap_i2c_dev *i2c_dev, int reg)
 
 static void omap_i2c_unidle(struct omap_i2c_dev *dev)
 {
-	struct omap_i2c_bus_platform_data *pdata;
-
-	pdata = dev->dev->platform_data;
-
-	if (pdata->flags & OMAP_I2C_FLAG_RESET_REGS_POSTIDLE) {
+	if (dev->flags & OMAP_I2C_FLAG_RESET_REGS_POSTIDLE) {
 		omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, 0);
 		omap_i2c_write_reg(dev, OMAP_I2C_PSC_REG, dev->pscstate);
 		omap_i2c_write_reg(dev, OMAP_I2C_SCLL_REG, dev->scllstate);
@@ -291,13 +291,10 @@ static void omap_i2c_unidle(struct omap_i2c_dev *dev)
 
 static void omap_i2c_idle(struct omap_i2c_dev *dev)
 {
-	struct omap_i2c_bus_platform_data *pdata;
 	u16 iv;
 
-	pdata = dev->dev->platform_data;
-
 	dev->iestate = omap_i2c_read_reg(dev, OMAP_I2C_IE_REG);
-	if (pdata->rev == OMAP_I2C_IP_VERSION_2)
+	if (dev->dtrev == OMAP_I2C_IP_VERSION_2)
 		omap_i2c_write_reg(dev, OMAP_I2C_IP_V2_IRQENABLE_CLR, 1);
 	else
 		omap_i2c_write_reg(dev, OMAP_I2C_IE_REG, 0);
@@ -320,9 +317,6 @@ static int omap_i2c_init(struct omap_i2c_dev *dev)
 	unsigned long timeout;
 	unsigned long internal_clk = 0;
 	struct clk *fclk;
-	struct omap_i2c_bus_platform_data *pdata;
-
-	pdata = dev->dev->platform_data;
 
 	if (dev->rev >= OMAP_I2C_OMAP1_REV_2) {
 		/* Disable I2C controller before soft reset */
@@ -373,7 +367,7 @@ static int omap_i2c_init(struct omap_i2c_dev *dev)
 	}
 	omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, 0);
 
-	if (pdata->flags & OMAP_I2C_FLAG_ALWAYS_ARMXOR_CLK) {
+	if (dev->flags & OMAP_I2C_FLAG_ALWAYS_ARMXOR_CLK) {
 		/*
 		 * The I2C functional clock is the armxor_ck, so there's
 		 * no need to get "armxor_ck" separately.  Now, if OMAP2420
@@ -397,7 +391,7 @@ static int omap_i2c_init(struct omap_i2c_dev *dev)
 			psc = fclk_rate / 12000000;
 	}
 
-	if (!(pdata->flags & OMAP_I2C_FLAG_SIMPLE_CLOCK)) {
+	if (!(dev->flags & OMAP_I2C_FLAG_SIMPLE_CLOCK)) {
 
 		/*
 		 * HSI2C controller internal clk rate should be 19.2 Mhz for
@@ -406,7 +400,7 @@ static int omap_i2c_init(struct omap_i2c_dev *dev)
 		 * The filter is iclk (fclk for HS) period.
 		 */
 		if (dev->speed > 400 ||
-			       pdata->flags & OMAP_I2C_FLAG_FORCE_19200_INT_CLK)
+			       dev->flags & OMAP_I2C_FLAG_FORCE_19200_INT_CLK)
 			internal_clk = 19200;
 		else if (dev->speed > 100)
 			internal_clk = 9600;
@@ -475,7 +469,7 @@ static int omap_i2c_init(struct omap_i2c_dev *dev)
 
 	dev->errata = 0;
 
-	if (pdata->flags & OMAP_I2C_FLAG_APPLY_ERRATA_I207)
+	if (dev->flags & OMAP_I2C_FLAG_APPLY_ERRATA_I207)
 		dev->errata |= I2C_OMAP_ERRATA_I207;
 
 	/* Enable interrupts */
@@ -484,7 +478,7 @@ static int omap_i2c_init(struct omap_i2c_dev *dev)
 			OMAP_I2C_IE_AL)  | ((dev->fifo_size) ?
 				(OMAP_I2C_IE_RDR | OMAP_I2C_IE_XDR) : 0);
 	omap_i2c_write_reg(dev, OMAP_I2C_IE_REG, dev->iestate);
-	if (pdata->flags & OMAP_I2C_FLAG_RESET_REGS_POSTIDLE) {
+	if (dev->flags & OMAP_I2C_FLAG_RESET_REGS_POSTIDLE) {
 		dev->pscstate = psc;
 		dev->scllstate = scll;
 		dev->sclhstate = sclh;
@@ -804,9 +798,6 @@ omap_i2c_isr(int this_irq, void *dev_id)
 	u16 bits;
 	u16 stat, w;
 	int err, count = 0;
-	struct omap_i2c_bus_platform_data *pdata;
-
-	pdata = dev->dev->platform_data;
 
 	if (pm_runtime_suspended(dev->dev))
 		return IRQ_NONE;
@@ -875,7 +866,7 @@ complete:
 					 * Data reg in 2430, omap3 and
 					 * omap4 is 8 bit wide
 					 */
-					if (pdata->flags &
+					if (dev->flags &
 						 OMAP_I2C_FLAG_16BIT_DATA_REG) {
 						if (dev->buf_len) {
 							*dev->buf++ = w >> 8;
@@ -918,7 +909,7 @@ complete:
 					 * Data reg in 2430, omap3 and
 					 * omap4 is 8 bit wide
 					 */
-					if (pdata->flags &
+					if (dev->flags &
 						 OMAP_I2C_FLAG_16BIT_DATA_REG) {
 						if (dev->buf_len) {
 							w |= *dev->buf++ << 8;
@@ -965,6 +956,32 @@ static const struct i2c_algorithm omap_i2c_algo = {
 	.functionality	= omap_i2c_func,
 };
 
+#ifdef CONFIG_OF
+static struct omap_i2c_bus_platform_data omap3_pdata = {
+	.rev = OMAP_I2C_IP_VERSION_1,
+	.flags = OMAP_I2C_FLAG_APPLY_ERRATA_I207 |
+		 OMAP_I2C_FLAG_RESET_REGS_POSTIDLE |
+		 OMAP_I2C_FLAG_BUS_SHIFT_2,
+};
+
+static struct omap_i2c_bus_platform_data omap4_pdata = {
+	.rev = OMAP_I2C_IP_VERSION_2,
+};
+
+static const struct of_device_id omap_i2c_of_match[] = {
+	{
+		.compatible = "ti,omap4-i2c",
+		.data = &omap4_pdata,
+	},
+	{
+		.compatible = "ti,omap3-i2c",
+		.data = &omap3_pdata,
+	},
+	{ },
+};
+MODULE_DEVICE_TABLE(of, omap_i2c_of_match);
+#endif
+
 static int __devinit
 omap_i2c_probe(struct platform_device *pdev)
 {
@@ -972,9 +989,10 @@ omap_i2c_probe(struct platform_device *pdev)
 	struct i2c_adapter	*adap;
 	struct resource		*mem, *irq, *ioarea;
 	struct omap_i2c_bus_platform_data *pdata = pdev->dev.platform_data;
+	struct device_node	*node = pdev->dev.of_node;
+	const struct of_device_id *match;
 	irq_handler_t isr;
 	int r;
-	u32 speed = 0;
 
 	/* NOTE: driver uses the static register mapping */
 	mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
@@ -1001,15 +1019,24 @@ omap_i2c_probe(struct platform_device *pdev)
 		goto err_release_region;
 	}
 
-	if (pdata != NULL) {
-		speed = pdata->clkrate;
+	match = of_match_device(omap_i2c_of_match, &pdev->dev);
+	if (match) {
+		u32 freq = 100000; /* default to 100000 Hz */
+
+		pdata = match->data;
+		dev->dtrev = pdata->rev;
+		dev->flags = pdata->flags;
+
+		of_property_read_u32(node, "clock-frequency", &freq);
+		/* convert DT freq value in Hz into kHz for speed */
+		dev->speed = freq / 1000;
+	} else if (pdata != NULL) {
+		dev->speed = pdata->clkrate;
+		dev->flags = pdata->flags;
 		dev->set_mpu_wkup_lat = pdata->set_mpu_wkup_lat;
-	} else {
-		speed = 100;	/* Default speed */
-		dev->set_mpu_wkup_lat = NULL;
+		dev->dtrev = pdata->rev;
 	}
 
-	dev->speed = speed;
 	dev->dev = &pdev->dev;
 	dev->irq = irq->start;
 	dev->base = ioremap(mem->start, resource_size(mem));
@@ -1020,9 +1047,9 @@ omap_i2c_probe(struct platform_device *pdev)
 
 	platform_set_drvdata(pdev, dev);
 
-	dev->reg_shift = (pdata->flags >> OMAP_I2C_FLAG_BUS_SHIFT__SHIFT) & 3;
+	dev->reg_shift = (dev->flags >> OMAP_I2C_FLAG_BUS_SHIFT__SHIFT) & 3;
 
-	if (pdata->rev == OMAP_I2C_IP_VERSION_2)
+	if (dev->dtrev == OMAP_I2C_IP_VERSION_2)
 		dev->regs = (u8 *)reg_map_ip_v2;
 	else
 		dev->regs = (u8 *)reg_map_ip_v1;
@@ -1035,7 +1062,7 @@ omap_i2c_probe(struct platform_device *pdev)
 	if (dev->rev <= OMAP_I2C_REV_ON_3430)
 		dev->errata |= I2C_OMAP3_1P153;
 
-	if (!(pdata->flags & OMAP_I2C_FLAG_NO_FIFO)) {
+	if (!(dev->flags & OMAP_I2C_FLAG_NO_FIFO)) {
 		u16 s;
 
 		/* Set up the fifo size - Get total size */
@@ -1057,7 +1084,7 @@ omap_i2c_probe(struct platform_device *pdev)
 		/* calculate wakeup latency constraint for MPU */
 		if (dev->set_mpu_wkup_lat != NULL)
 			dev->latency = (1000000 * dev->fifo_size) /
-				       (1000 * speed / 8);
+				       (1000 * dev->speed / 8);
 	}
 
 	/* reset ASAP, clearing any IRQs */
@@ -1073,7 +1100,7 @@ omap_i2c_probe(struct platform_device *pdev)
 	}
 
 	dev_info(dev->dev, "bus %d rev%d.%d.%d at %d kHz\n", pdev->id,
-		 pdata->rev, dev->rev >> 4, dev->rev & 0xf, dev->speed);
+		 dev->dtrev, dev->rev >> 4, dev->rev & 0xf, dev->speed);
 
 	pm_runtime_put(dev->dev);
 
@@ -1084,6 +1111,7 @@ omap_i2c_probe(struct platform_device *pdev)
 	strlcpy(adap->name, "OMAP I2C adapter", sizeof(adap->name));
 	adap->algo = &omap_i2c_algo;
 	adap->dev.parent = &pdev->dev;
+	adap->dev.of_node = pdev->dev.of_node;
 
 	/* i2c device drivers may be active on return from add_adapter() */
 	adap->nr = pdev->id;
@@ -1093,6 +1121,8 @@ omap_i2c_probe(struct platform_device *pdev)
 		goto err_free_irq;
 	}
 
+	of_i2c_register_devices(adap);
+
 	return 0;
 
 err_free_irq:
@@ -1165,6 +1195,7 @@ static struct platform_driver omap_i2c_driver = {
 		.name	= "omap_i2c",
 		.owner	= THIS_MODULE,
 		.pm	= OMAP_I2C_PM_OPS,
+		.of_match_table = of_match_ptr(omap_i2c_of_match),
 	},
 };
 
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 02/11] i2c: OMAP: Add DT support for i2c controller
@ 2011-12-20 16:27   ` Benoit Cousson
  0 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: linux-arm-kernel

Add initial DT support to retrieve the frequency using a
DT attribute instead of the pdata pointer if of_node exist.

Add documentation for omap i2c controller binding.

Based on original patches from Manju and Grant.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Ben Dooks <ben-linux@fluff.org>
Cc: Kevin Hilman <khilman@ti.com>
---
 Documentation/devicetree/bindings/i2c/omap-i2c.txt |   30 ++++++
 drivers/i2c/busses/i2c-omap.c                      |  101 +++++++++++++-------
 2 files changed, 96 insertions(+), 35 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/i2c/omap-i2c.txt

diff --git a/Documentation/devicetree/bindings/i2c/omap-i2c.txt b/Documentation/devicetree/bindings/i2c/omap-i2c.txt
new file mode 100644
index 0000000..56564aa
--- /dev/null
+++ b/Documentation/devicetree/bindings/i2c/omap-i2c.txt
@@ -0,0 +1,30 @@
+I2C for OMAP platforms
+
+Required properties :
+- compatible : Must be "ti,omap3-i2c" or "ti,omap4-i2c"
+- ti,hwmods : Must be "i2c<n>", n being the instance number (1-based)
+- #address-cells = <1>;
+- #size-cells = <0>;
+
+Recommended properties :
+- clock-frequency : Desired I2C bus clock frequency in Hz. Otherwise
+  the default 100 kHz frequency will be used.
+
+Optional properties:
+- Child nodes conforming to i2c bus binding
+
+Note: Current implementation will fetch base address, irq and dma
+from omap hwmod data base during device registration.
+Future plan is to migrate hwmod data base contents into device tree
+blob so that, all the required data will be used from device tree dts
+file.
+
+Examples :
+
+i2c1: i2c at 0 {
+    compatible = "ti,omap3-i2c";
+    #address-cells = <1>;
+    #size-cells = <0>;
+    ti,hwmods = "i2c1";
+    clock-frequency = <400000>;
+};
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index a43d002..dcbc1ec 100644
--- a/drivers/i2c/busses/i2c-omap.c
+++ b/drivers/i2c/busses/i2c-omap.c
@@ -37,6 +37,8 @@
 #include <linux/platform_device.h>
 #include <linux/clk.h>
 #include <linux/io.h>
+#include <linux/of_i2c.h>
+#include <linux/of_device.h>
 #include <linux/slab.h>
 #include <linux/i2c-omap.h>
 #include <linux/pm_runtime.h>
@@ -182,7 +184,9 @@ struct omap_i2c_dev {
 	u32			latency;	/* maximum mpu wkup latency */
 	void			(*set_mpu_wkup_lat)(struct device *dev,
 						    long latency);
-	u32			speed;		/* Speed of bus in Khz */
+	u32			speed;		/* Speed of bus in kHz */
+	u32			dtrev;		/* extra revision from DT */
+	u32			flags;
 	u16			cmd_err;
 	u8			*buf;
 	u8			*regs;
@@ -266,11 +270,7 @@ static inline u16 omap_i2c_read_reg(struct omap_i2c_dev *i2c_dev, int reg)
 
 static void omap_i2c_unidle(struct omap_i2c_dev *dev)
 {
-	struct omap_i2c_bus_platform_data *pdata;
-
-	pdata = dev->dev->platform_data;
-
-	if (pdata->flags & OMAP_I2C_FLAG_RESET_REGS_POSTIDLE) {
+	if (dev->flags & OMAP_I2C_FLAG_RESET_REGS_POSTIDLE) {
 		omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, 0);
 		omap_i2c_write_reg(dev, OMAP_I2C_PSC_REG, dev->pscstate);
 		omap_i2c_write_reg(dev, OMAP_I2C_SCLL_REG, dev->scllstate);
@@ -291,13 +291,10 @@ static void omap_i2c_unidle(struct omap_i2c_dev *dev)
 
 static void omap_i2c_idle(struct omap_i2c_dev *dev)
 {
-	struct omap_i2c_bus_platform_data *pdata;
 	u16 iv;
 
-	pdata = dev->dev->platform_data;
-
 	dev->iestate = omap_i2c_read_reg(dev, OMAP_I2C_IE_REG);
-	if (pdata->rev == OMAP_I2C_IP_VERSION_2)
+	if (dev->dtrev == OMAP_I2C_IP_VERSION_2)
 		omap_i2c_write_reg(dev, OMAP_I2C_IP_V2_IRQENABLE_CLR, 1);
 	else
 		omap_i2c_write_reg(dev, OMAP_I2C_IE_REG, 0);
@@ -320,9 +317,6 @@ static int omap_i2c_init(struct omap_i2c_dev *dev)
 	unsigned long timeout;
 	unsigned long internal_clk = 0;
 	struct clk *fclk;
-	struct omap_i2c_bus_platform_data *pdata;
-
-	pdata = dev->dev->platform_data;
 
 	if (dev->rev >= OMAP_I2C_OMAP1_REV_2) {
 		/* Disable I2C controller before soft reset */
@@ -373,7 +367,7 @@ static int omap_i2c_init(struct omap_i2c_dev *dev)
 	}
 	omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, 0);
 
-	if (pdata->flags & OMAP_I2C_FLAG_ALWAYS_ARMXOR_CLK) {
+	if (dev->flags & OMAP_I2C_FLAG_ALWAYS_ARMXOR_CLK) {
 		/*
 		 * The I2C functional clock is the armxor_ck, so there's
 		 * no need to get "armxor_ck" separately.  Now, if OMAP2420
@@ -397,7 +391,7 @@ static int omap_i2c_init(struct omap_i2c_dev *dev)
 			psc = fclk_rate / 12000000;
 	}
 
-	if (!(pdata->flags & OMAP_I2C_FLAG_SIMPLE_CLOCK)) {
+	if (!(dev->flags & OMAP_I2C_FLAG_SIMPLE_CLOCK)) {
 
 		/*
 		 * HSI2C controller internal clk rate should be 19.2 Mhz for
@@ -406,7 +400,7 @@ static int omap_i2c_init(struct omap_i2c_dev *dev)
 		 * The filter is iclk (fclk for HS) period.
 		 */
 		if (dev->speed > 400 ||
-			       pdata->flags & OMAP_I2C_FLAG_FORCE_19200_INT_CLK)
+			       dev->flags & OMAP_I2C_FLAG_FORCE_19200_INT_CLK)
 			internal_clk = 19200;
 		else if (dev->speed > 100)
 			internal_clk = 9600;
@@ -475,7 +469,7 @@ static int omap_i2c_init(struct omap_i2c_dev *dev)
 
 	dev->errata = 0;
 
-	if (pdata->flags & OMAP_I2C_FLAG_APPLY_ERRATA_I207)
+	if (dev->flags & OMAP_I2C_FLAG_APPLY_ERRATA_I207)
 		dev->errata |= I2C_OMAP_ERRATA_I207;
 
 	/* Enable interrupts */
@@ -484,7 +478,7 @@ static int omap_i2c_init(struct omap_i2c_dev *dev)
 			OMAP_I2C_IE_AL)  | ((dev->fifo_size) ?
 				(OMAP_I2C_IE_RDR | OMAP_I2C_IE_XDR) : 0);
 	omap_i2c_write_reg(dev, OMAP_I2C_IE_REG, dev->iestate);
-	if (pdata->flags & OMAP_I2C_FLAG_RESET_REGS_POSTIDLE) {
+	if (dev->flags & OMAP_I2C_FLAG_RESET_REGS_POSTIDLE) {
 		dev->pscstate = psc;
 		dev->scllstate = scll;
 		dev->sclhstate = sclh;
@@ -804,9 +798,6 @@ omap_i2c_isr(int this_irq, void *dev_id)
 	u16 bits;
 	u16 stat, w;
 	int err, count = 0;
-	struct omap_i2c_bus_platform_data *pdata;
-
-	pdata = dev->dev->platform_data;
 
 	if (pm_runtime_suspended(dev->dev))
 		return IRQ_NONE;
@@ -875,7 +866,7 @@ complete:
 					 * Data reg in 2430, omap3 and
 					 * omap4 is 8 bit wide
 					 */
-					if (pdata->flags &
+					if (dev->flags &
 						 OMAP_I2C_FLAG_16BIT_DATA_REG) {
 						if (dev->buf_len) {
 							*dev->buf++ = w >> 8;
@@ -918,7 +909,7 @@ complete:
 					 * Data reg in 2430, omap3 and
 					 * omap4 is 8 bit wide
 					 */
-					if (pdata->flags &
+					if (dev->flags &
 						 OMAP_I2C_FLAG_16BIT_DATA_REG) {
 						if (dev->buf_len) {
 							w |= *dev->buf++ << 8;
@@ -965,6 +956,32 @@ static const struct i2c_algorithm omap_i2c_algo = {
 	.functionality	= omap_i2c_func,
 };
 
+#ifdef CONFIG_OF
+static struct omap_i2c_bus_platform_data omap3_pdata = {
+	.rev = OMAP_I2C_IP_VERSION_1,
+	.flags = OMAP_I2C_FLAG_APPLY_ERRATA_I207 |
+		 OMAP_I2C_FLAG_RESET_REGS_POSTIDLE |
+		 OMAP_I2C_FLAG_BUS_SHIFT_2,
+};
+
+static struct omap_i2c_bus_platform_data omap4_pdata = {
+	.rev = OMAP_I2C_IP_VERSION_2,
+};
+
+static const struct of_device_id omap_i2c_of_match[] = {
+	{
+		.compatible = "ti,omap4-i2c",
+		.data = &omap4_pdata,
+	},
+	{
+		.compatible = "ti,omap3-i2c",
+		.data = &omap3_pdata,
+	},
+	{ },
+};
+MODULE_DEVICE_TABLE(of, omap_i2c_of_match);
+#endif
+
 static int __devinit
 omap_i2c_probe(struct platform_device *pdev)
 {
@@ -972,9 +989,10 @@ omap_i2c_probe(struct platform_device *pdev)
 	struct i2c_adapter	*adap;
 	struct resource		*mem, *irq, *ioarea;
 	struct omap_i2c_bus_platform_data *pdata = pdev->dev.platform_data;
+	struct device_node	*node = pdev->dev.of_node;
+	const struct of_device_id *match;
 	irq_handler_t isr;
 	int r;
-	u32 speed = 0;
 
 	/* NOTE: driver uses the static register mapping */
 	mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
@@ -1001,15 +1019,24 @@ omap_i2c_probe(struct platform_device *pdev)
 		goto err_release_region;
 	}
 
-	if (pdata != NULL) {
-		speed = pdata->clkrate;
+	match = of_match_device(omap_i2c_of_match, &pdev->dev);
+	if (match) {
+		u32 freq = 100000; /* default to 100000 Hz */
+
+		pdata = match->data;
+		dev->dtrev = pdata->rev;
+		dev->flags = pdata->flags;
+
+		of_property_read_u32(node, "clock-frequency", &freq);
+		/* convert DT freq value in Hz into kHz for speed */
+		dev->speed = freq / 1000;
+	} else if (pdata != NULL) {
+		dev->speed = pdata->clkrate;
+		dev->flags = pdata->flags;
 		dev->set_mpu_wkup_lat = pdata->set_mpu_wkup_lat;
-	} else {
-		speed = 100;	/* Default speed */
-		dev->set_mpu_wkup_lat = NULL;
+		dev->dtrev = pdata->rev;
 	}
 
-	dev->speed = speed;
 	dev->dev = &pdev->dev;
 	dev->irq = irq->start;
 	dev->base = ioremap(mem->start, resource_size(mem));
@@ -1020,9 +1047,9 @@ omap_i2c_probe(struct platform_device *pdev)
 
 	platform_set_drvdata(pdev, dev);
 
-	dev->reg_shift = (pdata->flags >> OMAP_I2C_FLAG_BUS_SHIFT__SHIFT) & 3;
+	dev->reg_shift = (dev->flags >> OMAP_I2C_FLAG_BUS_SHIFT__SHIFT) & 3;
 
-	if (pdata->rev == OMAP_I2C_IP_VERSION_2)
+	if (dev->dtrev == OMAP_I2C_IP_VERSION_2)
 		dev->regs = (u8 *)reg_map_ip_v2;
 	else
 		dev->regs = (u8 *)reg_map_ip_v1;
@@ -1035,7 +1062,7 @@ omap_i2c_probe(struct platform_device *pdev)
 	if (dev->rev <= OMAP_I2C_REV_ON_3430)
 		dev->errata |= I2C_OMAP3_1P153;
 
-	if (!(pdata->flags & OMAP_I2C_FLAG_NO_FIFO)) {
+	if (!(dev->flags & OMAP_I2C_FLAG_NO_FIFO)) {
 		u16 s;
 
 		/* Set up the fifo size - Get total size */
@@ -1057,7 +1084,7 @@ omap_i2c_probe(struct platform_device *pdev)
 		/* calculate wakeup latency constraint for MPU */
 		if (dev->set_mpu_wkup_lat != NULL)
 			dev->latency = (1000000 * dev->fifo_size) /
-				       (1000 * speed / 8);
+				       (1000 * dev->speed / 8);
 	}
 
 	/* reset ASAP, clearing any IRQs */
@@ -1073,7 +1100,7 @@ omap_i2c_probe(struct platform_device *pdev)
 	}
 
 	dev_info(dev->dev, "bus %d rev%d.%d.%d at %d kHz\n", pdev->id,
-		 pdata->rev, dev->rev >> 4, dev->rev & 0xf, dev->speed);
+		 dev->dtrev, dev->rev >> 4, dev->rev & 0xf, dev->speed);
 
 	pm_runtime_put(dev->dev);
 
@@ -1084,6 +1111,7 @@ omap_i2c_probe(struct platform_device *pdev)
 	strlcpy(adap->name, "OMAP I2C adapter", sizeof(adap->name));
 	adap->algo = &omap_i2c_algo;
 	adap->dev.parent = &pdev->dev;
+	adap->dev.of_node = pdev->dev.of_node;
 
 	/* i2c device drivers may be active on return from add_adapter() */
 	adap->nr = pdev->id;
@@ -1093,6 +1121,8 @@ omap_i2c_probe(struct platform_device *pdev)
 		goto err_free_irq;
 	}
 
+	of_i2c_register_devices(adap);
+
 	return 0;
 
 err_free_irq:
@@ -1165,6 +1195,7 @@ static struct platform_driver omap_i2c_driver = {
 		.name	= "omap_i2c",
 		.owner	= THIS_MODULE,
 		.pm	= OMAP_I2C_PM_OPS,
+		.of_match_table = of_match_ptr(omap_i2c_of_match),
 	},
 };
 
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 03/11] rtc: rtc-twl: Add DT support for RTC inside twl4030/twl6030
  2011-12-20 16:27 ` Benoit Cousson
@ 2011-12-20 16:27     ` Benoit Cousson
  -1 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: rob.herring-bsGFqQB8/DxBDgjK7y7TUQ, tony-4v6yS6AI5VpBDgjK7y7TUQ
  Cc: Alessandro Zummo, devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ,
	linux-omap-u79uwXL29TY76Z2rM5mHXA,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

Add the DT support for the TI rtc-twl present in the twl4030
and twl6030 devices.

Signed-off-by: Benoit Cousson <b-cousson-l0cyMroinI0@public.gmane.org>
Cc: Alessandro Zummo <a.zummo-BfzFCNDTiLLj+vYz1yj4TQ@public.gmane.org>
---
 Documentation/devicetree/bindings/rtc/twl-rtc.txt |   12 ++++++++++++
 drivers/rtc/rtc-twl.c                             |   10 ++++++++--
 2 files changed, 20 insertions(+), 2 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/rtc/twl-rtc.txt

diff --git a/Documentation/devicetree/bindings/rtc/twl-rtc.txt b/Documentation/devicetree/bindings/rtc/twl-rtc.txt
new file mode 100644
index 0000000..596e0c9
--- /dev/null
+++ b/Documentation/devicetree/bindings/rtc/twl-rtc.txt
@@ -0,0 +1,12 @@
+* TI twl RTC
+
+The TWL family (twl4030/6030) contains a RTC.
+
+Required properties:
+- compatible : Should be twl4030-rtc
+
+Examples:
+
+rtc@0 {
+    compatible = "ti,twl4030-rtc";
+};
diff --git a/drivers/rtc/rtc-twl.c b/drivers/rtc/rtc-twl.c
index 20687d5..d43b4f6 100644
--- a/drivers/rtc/rtc-twl.c
+++ b/drivers/rtc/rtc-twl.c
@@ -550,6 +550,11 @@ static int twl_rtc_resume(struct platform_device *pdev)
 #define twl_rtc_resume  NULL
 #endif
 
+static const struct of_device_id twl_rtc_of_match[] = {
+	{.compatible = "ti,twl4030-rtc", },
+	{ },
+};
+MODULE_DEVICE_TABLE(of, twl_rtc_of_match);
 MODULE_ALIAS("platform:twl_rtc");
 
 static struct platform_driver twl4030rtc_driver = {
@@ -559,8 +564,9 @@ static struct platform_driver twl4030rtc_driver = {
 	.suspend	= twl_rtc_suspend,
 	.resume		= twl_rtc_resume,
 	.driver		= {
-		.owner	= THIS_MODULE,
-		.name	= "twl_rtc",
+		.owner		= THIS_MODULE,
+		.name		= "twl_rtc",
+		.of_match_table = twl_rtc_of_match,
 	},
 };
 
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 03/11] rtc: rtc-twl: Add DT support for RTC inside twl4030/twl6030
@ 2011-12-20 16:27     ` Benoit Cousson
  0 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: linux-arm-kernel

Add the DT support for the TI rtc-twl present in the twl4030
and twl6030 devices.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Alessandro Zummo <a.zummo@towertech.it>
---
 Documentation/devicetree/bindings/rtc/twl-rtc.txt |   12 ++++++++++++
 drivers/rtc/rtc-twl.c                             |   10 ++++++++--
 2 files changed, 20 insertions(+), 2 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/rtc/twl-rtc.txt

diff --git a/Documentation/devicetree/bindings/rtc/twl-rtc.txt b/Documentation/devicetree/bindings/rtc/twl-rtc.txt
new file mode 100644
index 0000000..596e0c9
--- /dev/null
+++ b/Documentation/devicetree/bindings/rtc/twl-rtc.txt
@@ -0,0 +1,12 @@
+* TI twl RTC
+
+The TWL family (twl4030/6030) contains a RTC.
+
+Required properties:
+- compatible : Should be twl4030-rtc
+
+Examples:
+
+rtc at 0 {
+    compatible = "ti,twl4030-rtc";
+};
diff --git a/drivers/rtc/rtc-twl.c b/drivers/rtc/rtc-twl.c
index 20687d5..d43b4f6 100644
--- a/drivers/rtc/rtc-twl.c
+++ b/drivers/rtc/rtc-twl.c
@@ -550,6 +550,11 @@ static int twl_rtc_resume(struct platform_device *pdev)
 #define twl_rtc_resume  NULL
 #endif
 
+static const struct of_device_id twl_rtc_of_match[] = {
+	{.compatible = "ti,twl4030-rtc", },
+	{ },
+};
+MODULE_DEVICE_TABLE(of, twl_rtc_of_match);
 MODULE_ALIAS("platform:twl_rtc");
 
 static struct platform_driver twl4030rtc_driver = {
@@ -559,8 +564,9 @@ static struct platform_driver twl4030rtc_driver = {
 	.suspend	= twl_rtc_suspend,
 	.resume		= twl_rtc_resume,
 	.driver		= {
-		.owner	= THIS_MODULE,
-		.name	= "twl_rtc",
+		.owner		= THIS_MODULE,
+		.name		= "twl_rtc",
+		.of_match_table = twl_rtc_of_match,
 	},
 };
 
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 04/11] arm/dts: OMAP4: Add i2c controller nodes
  2011-12-20 16:27 ` Benoit Cousson
@ 2011-12-20 16:27   ` Benoit Cousson
  -1 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: rob.herring, tony
  Cc: linux-omap, linux-arm-kernel, devicetree-discuss, grant.likely,
	Benoit Cousson

Add i2c controllers nodes into the main ocp bus.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
Cc: Rob Herring <rob.herring@calxeda.com>
---
 arch/arm/boot/dts/omap4.dtsi |   28 ++++++++++++++++++++++++++++
 1 files changed, 28 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap4.dtsi b/arch/arm/boot/dts/omap4.dtsi
index bede009..9872283 100644
--- a/arch/arm/boot/dts/omap4.dtsi
+++ b/arch/arm/boot/dts/omap4.dtsi
@@ -100,5 +100,33 @@
 			reg = <0x48241000 0x1000>,
 			      <0x48240100 0x0100>;
 		};
+
+		i2c1: i2c@1 {
+			compatible = "ti,omap4-i2c";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			ti,hwmods = "i2c1";
+		};
+
+		i2c2: i2c@2 {
+			compatible = "ti,omap4-i2c";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			ti,hwmods = "i2c2";
+		};
+
+		i2c3: i2c@3 {
+			compatible = "ti,omap4-i2c";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			ti,hwmods = "i2c3";
+		};
+
+		i2c4: i2c@4 {
+			compatible = "ti,omap4-i2c";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			ti,hwmods = "i2c4";
+		};
 	};
 };
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 04/11] arm/dts: OMAP4: Add i2c controller nodes
@ 2011-12-20 16:27   ` Benoit Cousson
  0 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: linux-arm-kernel

Add i2c controllers nodes into the main ocp bus.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
Cc: Rob Herring <rob.herring@calxeda.com>
---
 arch/arm/boot/dts/omap4.dtsi |   28 ++++++++++++++++++++++++++++
 1 files changed, 28 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap4.dtsi b/arch/arm/boot/dts/omap4.dtsi
index bede009..9872283 100644
--- a/arch/arm/boot/dts/omap4.dtsi
+++ b/arch/arm/boot/dts/omap4.dtsi
@@ -100,5 +100,33 @@
 			reg = <0x48241000 0x1000>,
 			      <0x48240100 0x0100>;
 		};
+
+		i2c1: i2c at 1 {
+			compatible = "ti,omap4-i2c";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			ti,hwmods = "i2c1";
+		};
+
+		i2c2: i2c at 2 {
+			compatible = "ti,omap4-i2c";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			ti,hwmods = "i2c2";
+		};
+
+		i2c3: i2c at 3 {
+			compatible = "ti,omap4-i2c";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			ti,hwmods = "i2c3";
+		};
+
+		i2c4: i2c at 4 {
+			compatible = "ti,omap4-i2c";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			ti,hwmods = "i2c4";
+		};
 	};
 };
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 05/11] arm/dts: OMAP3: Add i2c controller nodes
  2011-12-20 16:27 ` Benoit Cousson
@ 2011-12-20 16:27   ` Benoit Cousson
  -1 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: rob.herring, tony
  Cc: linux-omap, linux-arm-kernel, devicetree-discuss, grant.likely,
	Benoit Cousson

Add i2c controllers nodes into the main ocp bus.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
Cc: Rob Herring <rob.herring@calxeda.com>
---
 arch/arm/boot/dts/omap3.dtsi |   21 +++++++++++++++++++++
 1 files changed, 21 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap3.dtsi b/arch/arm/boot/dts/omap3.dtsi
index 6866dc7..697b210 100644
--- a/arch/arm/boot/dts/omap3.dtsi
+++ b/arch/arm/boot/dts/omap3.dtsi
@@ -61,5 +61,26 @@
 			ti,intc-size = <96>;
 			reg = <0x48200000 0x1000>;
 		};
+
+		i2c1: i2c@1 {
+			compatible = "ti,omap3-i2c";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			ti,hwmods = "i2c1";
+		};
+
+		i2c2: i2c@2 {
+			compatible = "ti,omap3-i2c";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			ti,hwmods = "i2c2";
+		};
+
+		i2c3: i2c@3 {
+			compatible = "ti,omap3-i2c";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			ti,hwmods = "i2c3";
+		};
 	};
 };
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 05/11] arm/dts: OMAP3: Add i2c controller nodes
@ 2011-12-20 16:27   ` Benoit Cousson
  0 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: linux-arm-kernel

Add i2c controllers nodes into the main ocp bus.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
Cc: Rob Herring <rob.herring@calxeda.com>
---
 arch/arm/boot/dts/omap3.dtsi |   21 +++++++++++++++++++++
 1 files changed, 21 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap3.dtsi b/arch/arm/boot/dts/omap3.dtsi
index 6866dc7..697b210 100644
--- a/arch/arm/boot/dts/omap3.dtsi
+++ b/arch/arm/boot/dts/omap3.dtsi
@@ -61,5 +61,26 @@
 			ti,intc-size = <96>;
 			reg = <0x48200000 0x1000>;
 		};
+
+		i2c1: i2c at 1 {
+			compatible = "ti,omap3-i2c";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			ti,hwmods = "i2c1";
+		};
+
+		i2c2: i2c at 2 {
+			compatible = "ti,omap3-i2c";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			ti,hwmods = "i2c2";
+		};
+
+		i2c3: i2c at 3 {
+			compatible = "ti,omap3-i2c";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			ti,hwmods = "i2c3";
+		};
 	};
 };
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 06/11] arm/dts: twl6030: Add DTS file for twl6030 PMIC
  2011-12-20 16:27 ` Benoit Cousson
@ 2011-12-20 16:27   ` Benoit Cousson
  -1 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: rob.herring, tony
  Cc: linux-omap, linux-arm-kernel, devicetree-discuss, grant.likely,
	Benoit Cousson

Add a dedicated DTS file for the twl6030 Power IC.
This chip is a big SoC that will be reused in a lot of various
OMAP4+ boards.

Note: This file is supposed to be included in a board DTS that will
create the twl node in order to allow the &twl reference to work.

Exmaple:
...
&i2c1 {
    twl: twl@48 {
        reg = <0x48>;
        interrupts = <0 7 4>;
        interrupt-controller;
        interrupt-parent = <&gic>;
    };
};

/include/ "twl6030.dtsi"
...

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
Cc: Rob Herring <rob.herring@calxeda.com>
---
 arch/arm/boot/dts/twl6030.dtsi |   22 ++++++++++++++++++++++
 1 files changed, 22 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/boot/dts/twl6030.dtsi

diff --git a/arch/arm/boot/dts/twl6030.dtsi b/arch/arm/boot/dts/twl6030.dtsi
new file mode 100644
index 0000000..b7b4e5e
--- /dev/null
+++ b/arch/arm/boot/dts/twl6030.dtsi
@@ -0,0 +1,22 @@
+/*
+ * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+/*
+ * Integrated Power Management Chip
+ * http://www.ti.com/lit/ds/symlink/twl6030.pdf
+ */
+&twl {
+	compatible = "ti,twl6030";
+	interrupt-controller;
+	#interrupt-cells = <1>;
+
+	rtc {
+		compatible = "ti,twl4030-rtc";
+		interrupts = <11>;
+	};
+};
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 06/11] arm/dts: twl6030: Add DTS file for twl6030 PMIC
@ 2011-12-20 16:27   ` Benoit Cousson
  0 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: linux-arm-kernel

Add a dedicated DTS file for the twl6030 Power IC.
This chip is a big SoC that will be reused in a lot of various
OMAP4+ boards.

Note: This file is supposed to be included in a board DTS that will
create the twl node in order to allow the &twl reference to work.

Exmaple:
...
&i2c1 {
    twl: twl at 48 {
        reg = <0x48>;
        interrupts = <0 7 4>;
        interrupt-controller;
        interrupt-parent = <&gic>;
    };
};

/include/ "twl6030.dtsi"
...

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
Cc: Rob Herring <rob.herring@calxeda.com>
---
 arch/arm/boot/dts/twl6030.dtsi |   22 ++++++++++++++++++++++
 1 files changed, 22 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/boot/dts/twl6030.dtsi

diff --git a/arch/arm/boot/dts/twl6030.dtsi b/arch/arm/boot/dts/twl6030.dtsi
new file mode 100644
index 0000000..b7b4e5e
--- /dev/null
+++ b/arch/arm/boot/dts/twl6030.dtsi
@@ -0,0 +1,22 @@
+/*
+ * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+/*
+ * Integrated Power Management Chip
+ * http://www.ti.com/lit/ds/symlink/twl6030.pdf
+ */
+&twl {
+	compatible = "ti,twl6030";
+	interrupt-controller;
+	#interrupt-cells = <1>;
+
+	rtc {
+		compatible = "ti,twl4030-rtc";
+		interrupts = <11>;
+	};
+};
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 07/11] arm/dts: twl4030: Add DTS file for twl4030 PM + Audio IC
  2011-12-20 16:27 ` Benoit Cousson
@ 2011-12-20 16:27   ` Benoit Cousson
  -1 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: rob.herring, tony
  Cc: linux-omap, linux-arm-kernel, devicetree-discuss, grant.likely,
	Benoit Cousson

Add a dedicated DTS file for the twl4030/5030 Power + Audio IC.
This chip is a big SoC that will be reused in a lot of various
OMAP3 boards.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
Cc: Rob Herring <rob.herring@calxeda.com>
---
 arch/arm/boot/dts/twl4030.dtsi |   21 +++++++++++++++++++++
 1 files changed, 21 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/boot/dts/twl4030.dtsi

diff --git a/arch/arm/boot/dts/twl4030.dtsi b/arch/arm/boot/dts/twl4030.dtsi
new file mode 100644
index 0000000..8be5223
--- /dev/null
+++ b/arch/arm/boot/dts/twl4030.dtsi
@@ -0,0 +1,21 @@
+/*
+ * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+/*
+ * Integrated Power Management Chip
+ */
+&twl {
+	compatible = "ti,twl4030";
+	interrupt-controller;
+	#interrupt-cells = <1>;
+
+	rtc {
+		compatible = "ti,twl4030-rtc";
+		interrupts = <11>;
+	};
+};
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 07/11] arm/dts: twl4030: Add DTS file for twl4030 PM + Audio IC
@ 2011-12-20 16:27   ` Benoit Cousson
  0 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: linux-arm-kernel

Add a dedicated DTS file for the twl4030/5030 Power + Audio IC.
This chip is a big SoC that will be reused in a lot of various
OMAP3 boards.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
Cc: Rob Herring <rob.herring@calxeda.com>
---
 arch/arm/boot/dts/twl4030.dtsi |   21 +++++++++++++++++++++
 1 files changed, 21 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/boot/dts/twl4030.dtsi

diff --git a/arch/arm/boot/dts/twl4030.dtsi b/arch/arm/boot/dts/twl4030.dtsi
new file mode 100644
index 0000000..8be5223
--- /dev/null
+++ b/arch/arm/boot/dts/twl4030.dtsi
@@ -0,0 +1,21 @@
+/*
+ * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+/*
+ * Integrated Power Management Chip
+ */
+&twl {
+	compatible = "ti,twl4030";
+	interrupt-controller;
+	#interrupt-cells = <1>;
+
+	rtc {
+		compatible = "ti,twl4030-rtc";
+		interrupts = <11>;
+	};
+};
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 08/11] arm/dts: omap4-panda: Add twl6030 and i2c EEPROM
  2011-12-20 16:27 ` Benoit Cousson
@ 2011-12-20 16:27   ` Benoit Cousson
  -1 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: rob.herring, tony
  Cc: linux-omap, linux-arm-kernel, devicetree-discuss, grant.likely,
	Benoit Cousson

Update pandaboard dts file with required clock frequencies
for the i2c client devices existing on pandaboard.

Add the twl6030 node in i2c1 controller.

This is the minimal support needed to boot OMAP4 boards
without any crash.
The support for all the features included in this MFD will be
added later.

Add a generic i2c EEPROM entry.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
---
 arch/arm/boot/dts/omap4-panda.dts |   34 ++++++++++++++++++++++++++++++++++
 1 files changed, 34 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap4-panda.dts b/arch/arm/boot/dts/omap4-panda.dts
index 9755ad5..29646dc 100644
--- a/arch/arm/boot/dts/omap4-panda.dts
+++ b/arch/arm/boot/dts/omap4-panda.dts
@@ -18,3 +18,37 @@
 		reg = <0x80000000 0x40000000>; /* 1 GB */
 	};
 };
+
+&i2c1 {
+	clock-frequency = <400000>;
+
+	twl: twl@48 {
+		reg = <0x48>;
+		/* SPI = 0, IRQ# = 7, 4 = active high level-sensitive */
+		interrupts = <0 7 4>; /* IRQ_SYS_1N cascaded to gic */
+		interrupt-parent = <&gic>;
+	};
+};
+
+/include/ "twl6030.dtsi"
+
+&i2c2 {
+	clock-frequency = <400000>;
+};
+
+&i2c3 {
+	clock-frequency = <100000>;
+
+	/*
+	 * Display monitor features are burnt in their EEPROM as EDID data.
+	 * The EEPROM is connected as I2C slave device.
+	 */
+	eeprom@50 {
+		compatible = "ti,eeprom";
+		reg = <0x50>;
+	};
+};
+
+&i2c4 {
+	clock-frequency = <400000>;
+};
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 08/11] arm/dts: omap4-panda: Add twl6030 and i2c EEPROM
@ 2011-12-20 16:27   ` Benoit Cousson
  0 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: linux-arm-kernel

Update pandaboard dts file with required clock frequencies
for the i2c client devices existing on pandaboard.

Add the twl6030 node in i2c1 controller.

This is the minimal support needed to boot OMAP4 boards
without any crash.
The support for all the features included in this MFD will be
added later.

Add a generic i2c EEPROM entry.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
---
 arch/arm/boot/dts/omap4-panda.dts |   34 ++++++++++++++++++++++++++++++++++
 1 files changed, 34 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap4-panda.dts b/arch/arm/boot/dts/omap4-panda.dts
index 9755ad5..29646dc 100644
--- a/arch/arm/boot/dts/omap4-panda.dts
+++ b/arch/arm/boot/dts/omap4-panda.dts
@@ -18,3 +18,37 @@
 		reg = <0x80000000 0x40000000>; /* 1 GB */
 	};
 };
+
+&i2c1 {
+	clock-frequency = <400000>;
+
+	twl: twl at 48 {
+		reg = <0x48>;
+		/* SPI = 0, IRQ# = 7, 4 = active high level-sensitive */
+		interrupts = <0 7 4>; /* IRQ_SYS_1N cascaded to gic */
+		interrupt-parent = <&gic>;
+	};
+};
+
+/include/ "twl6030.dtsi"
+
+&i2c2 {
+	clock-frequency = <400000>;
+};
+
+&i2c3 {
+	clock-frequency = <100000>;
+
+	/*
+	 * Display monitor features are burnt in their EEPROM as EDID data.
+	 * The EEPROM is connected as I2C slave device.
+	 */
+	eeprom at 50 {
+		compatible = "ti,eeprom";
+		reg = <0x50>;
+	};
+};
+
+&i2c4 {
+	clock-frequency = <400000>;
+};
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 09/11] arm/dts: omap4-sdp: Add twl6030, i2c3 and i2c4 devices
  2011-12-20 16:27 ` Benoit Cousson
@ 2011-12-20 16:27   ` Benoit Cousson
  -1 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: rob.herring, tony
  Cc: linux-omap, linux-arm-kernel, devicetree-discuss, grant.likely,
	Benoit Cousson

Update DTS file with required clock frequencies
for the i2c client devices existing on sdp4430.

Add the twl6030 node inside the i2c1 controller node.
This is the minimal support needed to boot OMAP4 boards
without any crash.
The support for all the features included in this MFD will be
added later.

Add the RTC submodule inside the twl node.

Add tmp105 temperature sensor in i2c3
Add bh1780 Ambient Light Sensor in i2c3
Add hmc5843 3-Axis Digital Compass in i2c4

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
---
 arch/arm/boot/dts/omap4-sdp.dts |   53 +++++++++++++++++++++++++++++++++++++++
 1 files changed, 53 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap4-sdp.dts b/arch/arm/boot/dts/omap4-sdp.dts
index 63c6b2b..17e829a 100644
--- a/arch/arm/boot/dts/omap4-sdp.dts
+++ b/arch/arm/boot/dts/omap4-sdp.dts
@@ -18,3 +18,56 @@
 		reg = <0x80000000 0x40000000>; /* 1 GB */
 	};
 };
+
+&i2c1 {
+	clock-frequency = <400000>;
+
+	twl: twl@48 {
+		reg = <0x48>;
+		/* SPI = 0, IRQ# = 7, 4 = active high level-sensitive */
+		interrupts = <0 7 4>; /* IRQ_SYS_1N cascaded to gic */
+		interrupt-parent = <&gic>;
+	};
+};
+
+/include/ "twl6030.dtsi"
+
+&i2c2 {
+	clock-frequency = <400000>;
+	reg = <0x48072000 0x100>, <0x48072100 0x100>, <0x48072200 0x100>;
+};
+
+&i2c3 {
+	clock-frequency = <400000>;
+
+	/*
+	 * Temperature Sensor
+	 * http://www.ti.com/lit/ds/symlink/tmp105.pdf
+	 */
+	tmp105@48 {
+		compatible = "ti,tmp105";
+		reg = <0x48>;
+	};
+
+	/*
+	 * Ambient Light Sensor
+	 * http://www.rohm.com/products/databook/sensor/pdf/bh1780gli-e.pdf
+	 */
+	bh1780@29 {
+		compatible = "rohm,bh1780";
+		reg = <0x29>;
+	};
+};
+
+&i2c4 {
+	clock-frequency = <400000>;
+
+	/*
+	 * 3-Axis Digital Compass
+	 * http://www.sparkfun.com/datasheets/Sensors/Magneto/HMC5843.pdf
+	 */
+	hmc5843@1e {
+		compatible = "honeywell,hmc5843";
+		reg = <0x1e>;
+	};
+};
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 09/11] arm/dts: omap4-sdp: Add twl6030, i2c3 and i2c4 devices
@ 2011-12-20 16:27   ` Benoit Cousson
  0 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: linux-arm-kernel

Update DTS file with required clock frequencies
for the i2c client devices existing on sdp4430.

Add the twl6030 node inside the i2c1 controller node.
This is the minimal support needed to boot OMAP4 boards
without any crash.
The support for all the features included in this MFD will be
added later.

Add the RTC submodule inside the twl node.

Add tmp105 temperature sensor in i2c3
Add bh1780 Ambient Light Sensor in i2c3
Add hmc5843 3-Axis Digital Compass in i2c4

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
---
 arch/arm/boot/dts/omap4-sdp.dts |   53 +++++++++++++++++++++++++++++++++++++++
 1 files changed, 53 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap4-sdp.dts b/arch/arm/boot/dts/omap4-sdp.dts
index 63c6b2b..17e829a 100644
--- a/arch/arm/boot/dts/omap4-sdp.dts
+++ b/arch/arm/boot/dts/omap4-sdp.dts
@@ -18,3 +18,56 @@
 		reg = <0x80000000 0x40000000>; /* 1 GB */
 	};
 };
+
+&i2c1 {
+	clock-frequency = <400000>;
+
+	twl: twl at 48 {
+		reg = <0x48>;
+		/* SPI = 0, IRQ# = 7, 4 = active high level-sensitive */
+		interrupts = <0 7 4>; /* IRQ_SYS_1N cascaded to gic */
+		interrupt-parent = <&gic>;
+	};
+};
+
+/include/ "twl6030.dtsi"
+
+&i2c2 {
+	clock-frequency = <400000>;
+	reg = <0x48072000 0x100>, <0x48072100 0x100>, <0x48072200 0x100>;
+};
+
+&i2c3 {
+	clock-frequency = <400000>;
+
+	/*
+	 * Temperature Sensor
+	 * http://www.ti.com/lit/ds/symlink/tmp105.pdf
+	 */
+	tmp105 at 48 {
+		compatible = "ti,tmp105";
+		reg = <0x48>;
+	};
+
+	/*
+	 * Ambient Light Sensor
+	 * http://www.rohm.com/products/databook/sensor/pdf/bh1780gli-e.pdf
+	 */
+	bh1780 at 29 {
+		compatible = "rohm,bh1780";
+		reg = <0x29>;
+	};
+};
+
+&i2c4 {
+	clock-frequency = <400000>;
+
+	/*
+	 * 3-Axis Digital Compass
+	 * http://www.sparkfun.com/datasheets/Sensors/Magneto/HMC5843.pdf
+	 */
+	hmc5843 at 1e {
+		compatible = "honeywell,hmc5843";
+		reg = <0x1e>;
+	};
+};
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 10/11] arm/dts: omap3-beagle: Add twl4030 and i2c EEPROM
  2011-12-20 16:27 ` Benoit Cousson
@ 2011-12-20 16:27   ` Benoit Cousson
  -1 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: rob.herring, tony
  Cc: linux-omap, linux-arm-kernel, devicetree-discuss, grant.likely,
	Benoit Cousson

Add required clock frequencies for the i2c client devices existing
on beagle board.

Add the twl4030 basic description with only the twl_rtc module.

Add the EEPROM node.

Based on original patch from Manju:
http://www.spinics.net/lists/linux-omap/msg55831.html

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
Cc: Rob Herring <rob.herring@calxeda.com>
---
 arch/arm/boot/dts/omap3-beagle.dts |   29 +++++++++++++++++++++++++++++
 1 files changed, 29 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-beagle.dts b/arch/arm/boot/dts/omap3-beagle.dts
index 9f72cd4..714ba5d 100644
--- a/arch/arm/boot/dts/omap3-beagle.dts
+++ b/arch/arm/boot/dts/omap3-beagle.dts
@@ -18,3 +18,32 @@
 		reg = <0x80000000 0x20000000>; /* 512 MB */
 	};
 };
+
+&i2c1 {
+	clock-frequency = <2600000>;
+
+	twl: twl@48 {
+		reg = <0x48>;
+		interrupts = <7>; /* SYS_NIRQ cascaded to intc */
+		interrupt-parent = <&intc>;
+	};
+};
+
+/include/ "twl4030.dtsi"
+
+&i2c2 {
+	clock-frequency = <400000>;
+};
+
+&i2c3 {
+	clock-frequency = <100000>;
+
+	/*
+	 * Display monitor features are burnt in the EEPROM
+	 * as EDID data.
+	 */
+	eeprom@50 {
+		compatible = "ti,eeprom";
+		reg = <0x50>;
+	};
+};
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 10/11] arm/dts: omap3-beagle: Add twl4030 and i2c EEPROM
@ 2011-12-20 16:27   ` Benoit Cousson
  0 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: linux-arm-kernel

Add required clock frequencies for the i2c client devices existing
on beagle board.

Add the twl4030 basic description with only the twl_rtc module.

Add the EEPROM node.

Based on original patch from Manju:
http://www.spinics.net/lists/linux-omap/msg55831.html

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
Cc: Rob Herring <rob.herring@calxeda.com>
---
 arch/arm/boot/dts/omap3-beagle.dts |   29 +++++++++++++++++++++++++++++
 1 files changed, 29 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-beagle.dts b/arch/arm/boot/dts/omap3-beagle.dts
index 9f72cd4..714ba5d 100644
--- a/arch/arm/boot/dts/omap3-beagle.dts
+++ b/arch/arm/boot/dts/omap3-beagle.dts
@@ -18,3 +18,32 @@
 		reg = <0x80000000 0x20000000>; /* 512 MB */
 	};
 };
+
+&i2c1 {
+	clock-frequency = <2600000>;
+
+	twl: twl at 48 {
+		reg = <0x48>;
+		interrupts = <7>; /* SYS_NIRQ cascaded to intc */
+		interrupt-parent = <&intc>;
+	};
+};
+
+/include/ "twl4030.dtsi"
+
+&i2c2 {
+	clock-frequency = <400000>;
+};
+
+&i2c3 {
+	clock-frequency = <100000>;
+
+	/*
+	 * Display monitor features are burnt in the EEPROM
+	 * as EDID data.
+	 */
+	eeprom at 50 {
+		compatible = "ti,eeprom";
+		reg = <0x50>;
+	};
+};
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 11/11] ARM: OMAP2+: board-generic: Remove i2c static init
  2011-12-20 16:27 ` Benoit Cousson
@ 2011-12-20 16:27   ` Benoit Cousson
  -1 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: rob.herring, tony
  Cc: linux-omap, linux-arm-kernel, devicetree-discuss, grant.likely,
	Benoit Cousson

This mainly reverts the commit that was adding the i2c static init.

Since the i2c and twl nodes are now present, there is no need
for the static initialization anymore.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Tony Lindgren <tony@atomide.com>
---
 arch/arm/mach-omap2/board-generic.c |   48 +---------------------------------
 1 files changed, 2 insertions(+), 46 deletions(-)

diff --git a/arch/arm/mach-omap2/board-generic.c b/arch/arm/mach-omap2/board-generic.c
index 2529017..38f105d 100644
--- a/arch/arm/mach-omap2/board-generic.c
+++ b/arch/arm/mach-omap2/board-generic.c
@@ -15,7 +15,6 @@
 #include <linux/of_irq.h>
 #include <linux/of_platform.h>
 #include <linux/irqdomain.h>
-#include <linux/i2c/twl.h>
 
 #include <mach/hardware.h>
 #include <asm/hardware/gic.h>
@@ -36,34 +35,6 @@ static void __init omap_init_irq(void)
 	of_irq_init(irq_match);
 }
 
-/*
- * XXX: Still needed to boot until the i2c & twl driver is adapted to
- * device-tree
- */
-#ifdef CONFIG_ARCH_OMAP4
-static struct twl4030_platform_data sdp4430_twldata = {
-	.irq_base	= TWL6030_IRQ_BASE,
-	.irq_end	= TWL6030_IRQ_END,
-};
-
-static void __init omap4_i2c_init(void)
-{
-	omap4_pmic_init("twl6030", &sdp4430_twldata);
-}
-#endif
-
-#ifdef CONFIG_ARCH_OMAP3
-static struct twl4030_platform_data beagle_twldata = {
-	.irq_base	= TWL4030_IRQ_BASE,
-	.irq_end	= TWL4030_IRQ_END,
-};
-
-static void __init omap3_i2c_init(void)
-{
-	omap3_pmic_init("twl4030", &beagle_twldata);
-}
-#endif
-
 static struct of_device_id omap_dt_match_table[] __initdata = {
 	{ .compatible = "simple-bus", },
 	{ .compatible = "ti,omap-infra", },
@@ -78,21 +49,6 @@ static void __init omap_generic_init(void)
 	of_platform_populate(NULL, omap_dt_match_table, NULL, NULL);
 }
 
-#ifdef CONFIG_ARCH_OMAP4
-static void __init omap4_init(void)
-{
-	omap4_i2c_init();
-	omap_generic_init();
-}
-#endif
-
-#ifdef CONFIG_ARCH_OMAP3
-static void __init omap3_init(void)
-{
-	omap3_i2c_init();
-	omap_generic_init();
-}
-#endif
 
 #if defined(CONFIG_SOC_OMAP2420)
 static const char *omap242x_boards_compat[] __initdata = {
@@ -145,7 +101,7 @@ DT_MACHINE_START(OMAP3_DT, "Generic OMAP3 (Flattened Device Tree)")
 	.init_early	= omap3430_init_early,
 	.init_irq	= omap_init_irq,
 	.handle_irq	= omap3_intc_handle_irq,
-	.init_machine	= omap3_init,
+	.init_machine	= omap_generic_init,
 	.timer		= &omap3_timer,
 	.dt_compat	= omap3_boards_compat,
 MACHINE_END
@@ -164,7 +120,7 @@ DT_MACHINE_START(OMAP4_DT, "Generic OMAP4 (Flattened Device Tree)")
 	.init_early	= omap4430_init_early,
 	.init_irq	= omap_init_irq,
 	.handle_irq	= gic_handle_irq,
-	.init_machine	= omap4_init,
+	.init_machine	= omap_generic_init,
 	.timer		= &omap4_timer,
 	.dt_compat	= omap4_boards_compat,
 MACHINE_END
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 40+ messages in thread

* [PATCH v3 11/11] ARM: OMAP2+: board-generic: Remove i2c static init
@ 2011-12-20 16:27   ` Benoit Cousson
  0 siblings, 0 replies; 40+ messages in thread
From: Benoit Cousson @ 2011-12-20 16:27 UTC (permalink / raw)
  To: linux-arm-kernel

This mainly reverts the commit that was adding the i2c static init.

Since the i2c and twl nodes are now present, there is no need
for the static initialization anymore.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Cc: Tony Lindgren <tony@atomide.com>
---
 arch/arm/mach-omap2/board-generic.c |   48 +---------------------------------
 1 files changed, 2 insertions(+), 46 deletions(-)

diff --git a/arch/arm/mach-omap2/board-generic.c b/arch/arm/mach-omap2/board-generic.c
index 2529017..38f105d 100644
--- a/arch/arm/mach-omap2/board-generic.c
+++ b/arch/arm/mach-omap2/board-generic.c
@@ -15,7 +15,6 @@
 #include <linux/of_irq.h>
 #include <linux/of_platform.h>
 #include <linux/irqdomain.h>
-#include <linux/i2c/twl.h>
 
 #include <mach/hardware.h>
 #include <asm/hardware/gic.h>
@@ -36,34 +35,6 @@ static void __init omap_init_irq(void)
 	of_irq_init(irq_match);
 }
 
-/*
- * XXX: Still needed to boot until the i2c & twl driver is adapted to
- * device-tree
- */
-#ifdef CONFIG_ARCH_OMAP4
-static struct twl4030_platform_data sdp4430_twldata = {
-	.irq_base	= TWL6030_IRQ_BASE,
-	.irq_end	= TWL6030_IRQ_END,
-};
-
-static void __init omap4_i2c_init(void)
-{
-	omap4_pmic_init("twl6030", &sdp4430_twldata);
-}
-#endif
-
-#ifdef CONFIG_ARCH_OMAP3
-static struct twl4030_platform_data beagle_twldata = {
-	.irq_base	= TWL4030_IRQ_BASE,
-	.irq_end	= TWL4030_IRQ_END,
-};
-
-static void __init omap3_i2c_init(void)
-{
-	omap3_pmic_init("twl4030", &beagle_twldata);
-}
-#endif
-
 static struct of_device_id omap_dt_match_table[] __initdata = {
 	{ .compatible = "simple-bus", },
 	{ .compatible = "ti,omap-infra", },
@@ -78,21 +49,6 @@ static void __init omap_generic_init(void)
 	of_platform_populate(NULL, omap_dt_match_table, NULL, NULL);
 }
 
-#ifdef CONFIG_ARCH_OMAP4
-static void __init omap4_init(void)
-{
-	omap4_i2c_init();
-	omap_generic_init();
-}
-#endif
-
-#ifdef CONFIG_ARCH_OMAP3
-static void __init omap3_init(void)
-{
-	omap3_i2c_init();
-	omap_generic_init();
-}
-#endif
 
 #if defined(CONFIG_SOC_OMAP2420)
 static const char *omap242x_boards_compat[] __initdata = {
@@ -145,7 +101,7 @@ DT_MACHINE_START(OMAP3_DT, "Generic OMAP3 (Flattened Device Tree)")
 	.init_early	= omap3430_init_early,
 	.init_irq	= omap_init_irq,
 	.handle_irq	= omap3_intc_handle_irq,
-	.init_machine	= omap3_init,
+	.init_machine	= omap_generic_init,
 	.timer		= &omap3_timer,
 	.dt_compat	= omap3_boards_compat,
 MACHINE_END
@@ -164,7 +120,7 @@ DT_MACHINE_START(OMAP4_DT, "Generic OMAP4 (Flattened Device Tree)")
 	.init_early	= omap4430_init_early,
 	.init_irq	= omap_init_irq,
 	.handle_irq	= gic_handle_irq,
-	.init_machine	= omap4_init,
+	.init_machine	= omap_generic_init,
 	.timer		= &omap4_timer,
 	.dt_compat	= omap4_boards_compat,
 MACHINE_END
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 40+ messages in thread

* Re: [PATCH v3 02/11] i2c: OMAP: Add DT support for i2c controller
  2011-12-20 16:27   ` Benoit Cousson
@ 2011-12-20 16:42     ` Rob Herring
  -1 siblings, 0 replies; 40+ messages in thread
From: Rob Herring @ 2011-12-20 16:42 UTC (permalink / raw)
  To: Benoit Cousson
  Cc: tony, linux-omap, linux-arm-kernel, devicetree-discuss,
	grant.likely, Ben Dooks, Kevin Hilman

On 12/20/2011 10:27 AM, Benoit Cousson wrote:
> Add initial DT support to retrieve the frequency using a
> DT attribute instead of the pdata pointer if of_node exist.
> 
> Add documentation for omap i2c controller binding.
> 
> Based on original patches from Manju and Grant.
> 
> Signed-off-by: Benoit Cousson <b-cousson@ti.com>
> Cc: Ben Dooks <ben-linux@fluff.org>
> Cc: Kevin Hilman <khilman@ti.com>

One issue below, otherwise:

Reviewed-by: Rob Herring <rob.herring@calxeda.com>


> @@ -1001,15 +1019,24 @@ omap_i2c_probe(struct platform_device *pdev)
>  		goto err_release_region;
>  	}
>  
> -	if (pdata != NULL) {
> -		speed = pdata->clkrate;
> +	match = of_match_device(omap_i2c_of_match, &pdev->dev);
> +	if (match) {
> +		u32 freq = 100000; /* default to 100000 Hz */
> +
> +		pdata = match->data;
> +		dev->dtrev = pdata->rev;
> +		dev->flags = pdata->flags;
> +
> +		of_property_read_u32(node, "clock-frequency", &freq);
> +		/* convert DT freq value in Hz into kHz for speed */
> +		dev->speed = freq / 1000;
> +	} else if (pdata != NULL) {
> +		dev->speed = pdata->clkrate;
> +		dev->flags = pdata->flags;
>  		dev->set_mpu_wkup_lat = pdata->set_mpu_wkup_lat;
> -	} else {
> -		speed = 100;	/* Default speed */
> -		dev->set_mpu_wkup_lat = NULL;
> +		dev->dtrev = pdata->rev;

If you get here, pdata is NULL.

Rob

^ permalink raw reply	[flat|nested] 40+ messages in thread

* [PATCH v3 02/11] i2c: OMAP: Add DT support for i2c controller
@ 2011-12-20 16:42     ` Rob Herring
  0 siblings, 0 replies; 40+ messages in thread
From: Rob Herring @ 2011-12-20 16:42 UTC (permalink / raw)
  To: linux-arm-kernel

On 12/20/2011 10:27 AM, Benoit Cousson wrote:
> Add initial DT support to retrieve the frequency using a
> DT attribute instead of the pdata pointer if of_node exist.
> 
> Add documentation for omap i2c controller binding.
> 
> Based on original patches from Manju and Grant.
> 
> Signed-off-by: Benoit Cousson <b-cousson@ti.com>
> Cc: Ben Dooks <ben-linux@fluff.org>
> Cc: Kevin Hilman <khilman@ti.com>

One issue below, otherwise:

Reviewed-by: Rob Herring <rob.herring@calxeda.com>


> @@ -1001,15 +1019,24 @@ omap_i2c_probe(struct platform_device *pdev)
>  		goto err_release_region;
>  	}
>  
> -	if (pdata != NULL) {
> -		speed = pdata->clkrate;
> +	match = of_match_device(omap_i2c_of_match, &pdev->dev);
> +	if (match) {
> +		u32 freq = 100000; /* default to 100000 Hz */
> +
> +		pdata = match->data;
> +		dev->dtrev = pdata->rev;
> +		dev->flags = pdata->flags;
> +
> +		of_property_read_u32(node, "clock-frequency", &freq);
> +		/* convert DT freq value in Hz into kHz for speed */
> +		dev->speed = freq / 1000;
> +	} else if (pdata != NULL) {
> +		dev->speed = pdata->clkrate;
> +		dev->flags = pdata->flags;
>  		dev->set_mpu_wkup_lat = pdata->set_mpu_wkup_lat;
> -	} else {
> -		speed = 100;	/* Default speed */
> -		dev->set_mpu_wkup_lat = NULL;
> +		dev->dtrev = pdata->rev;

If you get here, pdata is NULL.

Rob

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v3 07/11] arm/dts: twl4030: Add DTS file for twl4030 PM + Audio IC
  2011-12-20 16:27   ` Benoit Cousson
@ 2011-12-20 16:47     ` Rob Herring
  -1 siblings, 0 replies; 40+ messages in thread
From: Rob Herring @ 2011-12-20 16:47 UTC (permalink / raw)
  To: Benoit Cousson
  Cc: tony, linux-omap, linux-arm-kernel, devicetree-discuss, grant.likely

On 12/20/2011 10:27 AM, Benoit Cousson wrote:
> Add a dedicated DTS file for the twl4030/5030 Power + Audio IC.
> This chip is a big SoC that will be reused in a lot of various
> OMAP3 boards.
> 
> Signed-off-by: Benoit Cousson <b-cousson@ti.com>
> Cc: Grant Likely <grant.likely@secretlab.ca>
> Cc: Rob Herring <rob.herring@calxeda.com>
> ---
>  arch/arm/boot/dts/twl4030.dtsi |   21 +++++++++++++++++++++
>  1 files changed, 21 insertions(+), 0 deletions(-)
>  create mode 100644 arch/arm/boot/dts/twl4030.dtsi
> 
> diff --git a/arch/arm/boot/dts/twl4030.dtsi b/arch/arm/boot/dts/twl4030.dtsi
> new file mode 100644
> index 0000000..8be5223
> --- /dev/null
> +++ b/arch/arm/boot/dts/twl4030.dtsi
> @@ -0,0 +1,21 @@
> +/*
> + * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License version 2 as
> + * published by the Free Software Foundation.
> + */
> +
> +/*
> + * Integrated Power Management Chip
> + */
> +&twl {
> +	compatible = "ti,twl4030";
> +	interrupt-controller;
> +	#interrupt-cells = <1>;
> +
> +	rtc {
> +		compatible = "ti,twl4030-rtc";
> +		interrupts = <11>;

Can't this vary? Not only the irq#, but the parent controller's number
of cells can vary.

Rob

^ permalink raw reply	[flat|nested] 40+ messages in thread

* [PATCH v3 07/11] arm/dts: twl4030: Add DTS file for twl4030 PM + Audio IC
@ 2011-12-20 16:47     ` Rob Herring
  0 siblings, 0 replies; 40+ messages in thread
From: Rob Herring @ 2011-12-20 16:47 UTC (permalink / raw)
  To: linux-arm-kernel

On 12/20/2011 10:27 AM, Benoit Cousson wrote:
> Add a dedicated DTS file for the twl4030/5030 Power + Audio IC.
> This chip is a big SoC that will be reused in a lot of various
> OMAP3 boards.
> 
> Signed-off-by: Benoit Cousson <b-cousson@ti.com>
> Cc: Grant Likely <grant.likely@secretlab.ca>
> Cc: Rob Herring <rob.herring@calxeda.com>
> ---
>  arch/arm/boot/dts/twl4030.dtsi |   21 +++++++++++++++++++++
>  1 files changed, 21 insertions(+), 0 deletions(-)
>  create mode 100644 arch/arm/boot/dts/twl4030.dtsi
> 
> diff --git a/arch/arm/boot/dts/twl4030.dtsi b/arch/arm/boot/dts/twl4030.dtsi
> new file mode 100644
> index 0000000..8be5223
> --- /dev/null
> +++ b/arch/arm/boot/dts/twl4030.dtsi
> @@ -0,0 +1,21 @@
> +/*
> + * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License version 2 as
> + * published by the Free Software Foundation.
> + */
> +
> +/*
> + * Integrated Power Management Chip
> + */
> +&twl {
> +	compatible = "ti,twl4030";
> +	interrupt-controller;
> +	#interrupt-cells = <1>;
> +
> +	rtc {
> +		compatible = "ti,twl4030-rtc";
> +		interrupts = <11>;

Can't this vary? Not only the irq#, but the parent controller's number
of cells can vary.

Rob

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v3 07/11] arm/dts: twl4030: Add DTS file for twl4030 PM + Audio IC
  2011-12-20 16:47     ` Rob Herring
@ 2011-12-20 16:51       ` Rob Herring
  -1 siblings, 0 replies; 40+ messages in thread
From: Rob Herring @ 2011-12-20 16:51 UTC (permalink / raw)
  To: Benoit Cousson
  Cc: tony, linux-omap, linux-arm-kernel, devicetree-discuss, grant.likely



On 12/20/2011 10:47 AM, Rob Herring wrote:
> On 12/20/2011 10:27 AM, Benoit Cousson wrote:
>> Add a dedicated DTS file for the twl4030/5030 Power + Audio IC.
>> This chip is a big SoC that will be reused in a lot of various
>> OMAP3 boards.
>>
>> Signed-off-by: Benoit Cousson <b-cousson@ti.com>
>> Cc: Grant Likely <grant.likely@secretlab.ca>
>> Cc: Rob Herring <rob.herring@calxeda.com>
>> ---
>>  arch/arm/boot/dts/twl4030.dtsi |   21 +++++++++++++++++++++
>>  1 files changed, 21 insertions(+), 0 deletions(-)
>>  create mode 100644 arch/arm/boot/dts/twl4030.dtsi
>>
>> diff --git a/arch/arm/boot/dts/twl4030.dtsi b/arch/arm/boot/dts/twl4030.dtsi
>> new file mode 100644
>> index 0000000..8be5223
>> --- /dev/null
>> +++ b/arch/arm/boot/dts/twl4030.dtsi
>> @@ -0,0 +1,21 @@
>> +/*
>> + * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/
>> + *
>> + * This program is free software; you can redistribute it and/or modify
>> + * it under the terms of the GNU General Public License version 2 as
>> + * published by the Free Software Foundation.
>> + */
>> +
>> +/*
>> + * Integrated Power Management Chip
>> + */
>> +&twl {
>> +	compatible = "ti,twl4030";
>> +	interrupt-controller;
>> +	#interrupt-cells = <1>;
>> +
>> +	rtc {
>> +		compatible = "ti,twl4030-rtc";
>> +		interrupts = <11>;
> 
> Can't this vary? Not only the irq#, but the parent controller's number
> of cells can vary.

Never mind. I see this is the RTC interrupt within the twl4030 chip.

Rob

^ permalink raw reply	[flat|nested] 40+ messages in thread

* [PATCH v3 07/11] arm/dts: twl4030: Add DTS file for twl4030 PM + Audio IC
@ 2011-12-20 16:51       ` Rob Herring
  0 siblings, 0 replies; 40+ messages in thread
From: Rob Herring @ 2011-12-20 16:51 UTC (permalink / raw)
  To: linux-arm-kernel



On 12/20/2011 10:47 AM, Rob Herring wrote:
> On 12/20/2011 10:27 AM, Benoit Cousson wrote:
>> Add a dedicated DTS file for the twl4030/5030 Power + Audio IC.
>> This chip is a big SoC that will be reused in a lot of various
>> OMAP3 boards.
>>
>> Signed-off-by: Benoit Cousson <b-cousson@ti.com>
>> Cc: Grant Likely <grant.likely@secretlab.ca>
>> Cc: Rob Herring <rob.herring@calxeda.com>
>> ---
>>  arch/arm/boot/dts/twl4030.dtsi |   21 +++++++++++++++++++++
>>  1 files changed, 21 insertions(+), 0 deletions(-)
>>  create mode 100644 arch/arm/boot/dts/twl4030.dtsi
>>
>> diff --git a/arch/arm/boot/dts/twl4030.dtsi b/arch/arm/boot/dts/twl4030.dtsi
>> new file mode 100644
>> index 0000000..8be5223
>> --- /dev/null
>> +++ b/arch/arm/boot/dts/twl4030.dtsi
>> @@ -0,0 +1,21 @@
>> +/*
>> + * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/
>> + *
>> + * This program is free software; you can redistribute it and/or modify
>> + * it under the terms of the GNU General Public License version 2 as
>> + * published by the Free Software Foundation.
>> + */
>> +
>> +/*
>> + * Integrated Power Management Chip
>> + */
>> +&twl {
>> +	compatible = "ti,twl4030";
>> +	interrupt-controller;
>> +	#interrupt-cells = <1>;
>> +
>> +	rtc {
>> +		compatible = "ti,twl4030-rtc";
>> +		interrupts = <11>;
> 
> Can't this vary? Not only the irq#, but the parent controller's number
> of cells can vary.

Never mind. I see this is the RTC interrupt within the twl4030 chip.

Rob

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v3 02/11] i2c: OMAP: Add DT support for i2c controller
  2011-12-20 16:27   ` Benoit Cousson
@ 2011-12-20 21:24     ` Olof Johansson
  -1 siblings, 0 replies; 40+ messages in thread
From: Olof Johansson @ 2011-12-20 21:24 UTC (permalink / raw)
  To: Benoit Cousson
  Cc: rob.herring, tony, Kevin Hilman, devicetree-discuss, Ben Dooks,
	linux-omap, linux-arm-kernel

Hi,

On Tue, Dec 20, 2011 at 8:27 AM, Benoit Cousson <b-cousson@ti.com> wrote:


> diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
> index a43d002..dcbc1ec 100644
> --- a/drivers/i2c/busses/i2c-omap.c
> +++ b/drivers/i2c/busses/i2c-omap.c
> @@ -37,6 +37,8 @@
>  #include <linux/platform_device.h>
>  #include <linux/clk.h>
>  #include <linux/io.h>
> +#include <linux/of_i2c.h>
> +#include <linux/of_device.h>
>  #include <linux/slab.h>
>  #include <linux/i2c-omap.h>
>  #include <linux/pm_runtime.h>
[...]
> @@ -1165,6 +1195,7 @@ static struct platform_driver omap_i2c_driver = {
>                .name   = "omap_i2c",
>                .owner  = THIS_MODULE,
>                .pm     = OMAP_I2C_PM_OPS,
> +               .of_match_table = of_match_ptr(omap_i2c_of_match),
>        },
>  };

of_match_ptr() comes from <linux/of.h>, so you need to include that to
not break !CONFIG_OF builds.


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

^ permalink raw reply	[flat|nested] 40+ messages in thread

* [PATCH v3 02/11] i2c: OMAP: Add DT support for i2c controller
@ 2011-12-20 21:24     ` Olof Johansson
  0 siblings, 0 replies; 40+ messages in thread
From: Olof Johansson @ 2011-12-20 21:24 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

On Tue, Dec 20, 2011 at 8:27 AM, Benoit Cousson <b-cousson@ti.com> wrote:


> diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
> index a43d002..dcbc1ec 100644
> --- a/drivers/i2c/busses/i2c-omap.c
> +++ b/drivers/i2c/busses/i2c-omap.c
> @@ -37,6 +37,8 @@
> ?#include <linux/platform_device.h>
> ?#include <linux/clk.h>
> ?#include <linux/io.h>
> +#include <linux/of_i2c.h>
> +#include <linux/of_device.h>
> ?#include <linux/slab.h>
> ?#include <linux/i2c-omap.h>
> ?#include <linux/pm_runtime.h>
[...]
> @@ -1165,6 +1195,7 @@ static struct platform_driver omap_i2c_driver = {
> ? ? ? ? ? ? ? ?.name ? = "omap_i2c",
> ? ? ? ? ? ? ? ?.owner ?= THIS_MODULE,
> ? ? ? ? ? ? ? ?.pm ? ? = OMAP_I2C_PM_OPS,
> + ? ? ? ? ? ? ? .of_match_table = of_match_ptr(omap_i2c_of_match),
> ? ? ? ?},
> ?};

of_match_ptr() comes from <linux/of.h>, so you need to include that to
not break !CONFIG_OF builds.


-Olof

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v3 02/11] i2c: OMAP: Add DT support for i2c controller
  2011-12-20 16:42     ` Rob Herring
@ 2011-12-22  8:55         ` Cousson, Benoit
  -1 siblings, 0 replies; 40+ messages in thread
From: Cousson, Benoit @ 2011-12-22  8:55 UTC (permalink / raw)
  To: Rob Herring
  Cc: Kevin Hilman, tony-4v6yS6AI5VpBDgjK7y7TUQ,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ, Ben Dooks,
	linux-omap-u79uwXL29TY76Z2rM5mHXA,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

Hi Rob,

On 12/20/2011 5:42 PM, Rob Herring wrote:
> On 12/20/2011 10:27 AM, Benoit Cousson wrote:
>> Add initial DT support to retrieve the frequency using a
>> DT attribute instead of the pdata pointer if of_node exist.
>>
>> Add documentation for omap i2c controller binding.
>>
>> Based on original patches from Manju and Grant.
>>
>> Signed-off-by: Benoit Cousson<b-cousson-l0cyMroinI0@public.gmane.org>
>> Cc: Ben Dooks<ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org>
>> Cc: Kevin Hilman<khilman-l0cyMroinI0@public.gmane.org>
>
> One issue below, otherwise:
>
> Reviewed-by: Rob Herring<rob.herring-bsGFqQB8/DxBDgjK7y7TUQ@public.gmane.org>
>
>
>> @@ -1001,15 +1019,24 @@ omap_i2c_probe(struct platform_device *pdev)
>>   		goto err_release_region;
>>   	}
>>
>> -	if (pdata != NULL) {
>> -		speed = pdata->clkrate;
>> +	match = of_match_device(omap_i2c_of_match,&pdev->dev);
>> +	if (match) {
>> +		u32 freq = 100000; /* default to 100000 Hz */
>> +
>> +		pdata = match->data;
>> +		dev->dtrev = pdata->rev;
>> +		dev->flags = pdata->flags;
>> +
>> +		of_property_read_u32(node, "clock-frequency",&freq);
>> +		/* convert DT freq value in Hz into kHz for speed */
>> +		dev->speed = freq / 1000;
>> +	} else if (pdata != NULL) {
>> +		dev->speed = pdata->clkrate;
>> +		dev->flags = pdata->flags;
>>   		dev->set_mpu_wkup_lat = pdata->set_mpu_wkup_lat;
>> -	} else {
>> -		speed = 100;	/* Default speed */
>> -		dev->set_mpu_wkup_lat = NULL;
>> +		dev->dtrev = pdata->rev;
>
> If you get here, pdata is NULL.

Mmm, it should not. It's true that the patch is not super readable, but 
here is the result:

	if (match) {
		u32 freq = 100000; /* default to 100000 Hz */

		pdata = match->data;
		dev->dtrev = pdata->rev;
		dev->flags = pdata->flags;

		of_property_read_u32(node, "clock-frequency", &freq);
		/* convert DT freq value in Hz into kHz for speed */
		dev->speed = freq / 1000;
	} else if (pdata != NULL) {
		dev->speed = pdata->clkrate;
		dev->flags = pdata->flags;
		dev->set_mpu_wkup_lat = pdata->set_mpu_wkup_lat;
		dev->dtrev = pdata->rev;
	}

I removed every other pdata reference after this point.

Regards,
Benoit

^ permalink raw reply	[flat|nested] 40+ messages in thread

* [PATCH v3 02/11] i2c: OMAP: Add DT support for i2c controller
@ 2011-12-22  8:55         ` Cousson, Benoit
  0 siblings, 0 replies; 40+ messages in thread
From: Cousson, Benoit @ 2011-12-22  8:55 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Rob,

On 12/20/2011 5:42 PM, Rob Herring wrote:
> On 12/20/2011 10:27 AM, Benoit Cousson wrote:
>> Add initial DT support to retrieve the frequency using a
>> DT attribute instead of the pdata pointer if of_node exist.
>>
>> Add documentation for omap i2c controller binding.
>>
>> Based on original patches from Manju and Grant.
>>
>> Signed-off-by: Benoit Cousson<b-cousson@ti.com>
>> Cc: Ben Dooks<ben-linux@fluff.org>
>> Cc: Kevin Hilman<khilman@ti.com>
>
> One issue below, otherwise:
>
> Reviewed-by: Rob Herring<rob.herring@calxeda.com>
>
>
>> @@ -1001,15 +1019,24 @@ omap_i2c_probe(struct platform_device *pdev)
>>   		goto err_release_region;
>>   	}
>>
>> -	if (pdata != NULL) {
>> -		speed = pdata->clkrate;
>> +	match = of_match_device(omap_i2c_of_match,&pdev->dev);
>> +	if (match) {
>> +		u32 freq = 100000; /* default to 100000 Hz */
>> +
>> +		pdata = match->data;
>> +		dev->dtrev = pdata->rev;
>> +		dev->flags = pdata->flags;
>> +
>> +		of_property_read_u32(node, "clock-frequency",&freq);
>> +		/* convert DT freq value in Hz into kHz for speed */
>> +		dev->speed = freq / 1000;
>> +	} else if (pdata != NULL) {
>> +		dev->speed = pdata->clkrate;
>> +		dev->flags = pdata->flags;
>>   		dev->set_mpu_wkup_lat = pdata->set_mpu_wkup_lat;
>> -	} else {
>> -		speed = 100;	/* Default speed */
>> -		dev->set_mpu_wkup_lat = NULL;
>> +		dev->dtrev = pdata->rev;
>
> If you get here, pdata is NULL.

Mmm, it should not. It's true that the patch is not super readable, but 
here is the result:

	if (match) {
		u32 freq = 100000; /* default to 100000 Hz */

		pdata = match->data;
		dev->dtrev = pdata->rev;
		dev->flags = pdata->flags;

		of_property_read_u32(node, "clock-frequency", &freq);
		/* convert DT freq value in Hz into kHz for speed */
		dev->speed = freq / 1000;
	} else if (pdata != NULL) {
		dev->speed = pdata->clkrate;
		dev->flags = pdata->flags;
		dev->set_mpu_wkup_lat = pdata->set_mpu_wkup_lat;
		dev->dtrev = pdata->rev;
	}

I removed every other pdata reference after this point.

Regards,
Benoit

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v3 02/11] i2c: OMAP: Add DT support for i2c controller
  2011-12-20 21:24     ` Olof Johansson
@ 2011-12-22 14:01         ` Cousson, Benoit
  -1 siblings, 0 replies; 40+ messages in thread
From: Cousson, Benoit @ 2011-12-22 14:01 UTC (permalink / raw)
  To: Olof Johansson
  Cc: Kevin Hilman, tony-4v6yS6AI5VpBDgjK7y7TUQ,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ,
	rob.herring-bsGFqQB8/DxBDgjK7y7TUQ, Ben Dooks,
	linux-omap-u79uwXL29TY76Z2rM5mHXA,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

Hi Olof,

On 12/20/2011 10:24 PM, Olof Johansson wrote:
> Hi,
>
> On Tue, Dec 20, 2011 at 8:27 AM, Benoit Cousson<b-cousson-l0cyMroinI0@public.gmane.org>  wrote:
>
>> diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
>> index a43d002..dcbc1ec 100644
>> --- a/drivers/i2c/busses/i2c-omap.c
>> +++ b/drivers/i2c/busses/i2c-omap.c
>> @@ -37,6 +37,8 @@
>>   #include<linux/platform_device.h>
>>   #include<linux/clk.h>
>>   #include<linux/io.h>
>> +#include<linux/of_i2c.h>
>> +#include<linux/of_device.h>
>>   #include<linux/slab.h>
>>   #include<linux/i2c-omap.h>
>>   #include<linux/pm_runtime.h>
> [...]
>> @@ -1165,6 +1195,7 @@ static struct platform_driver omap_i2c_driver = {
>>                 .name   = "omap_i2c",
>>                 .owner  = THIS_MODULE,
>>                 .pm     = OMAP_I2C_PM_OPS,
>> +               .of_match_table = of_match_ptr(omap_i2c_of_match),
>>         },
>>   };
>
> of_match_ptr() comes from<linux/of.h>, so you need to include that to
> not break !CONFIG_OF builds.

Good point, I'll fix that.

Thanks,
Benoit

^ permalink raw reply	[flat|nested] 40+ messages in thread

* [PATCH v3 02/11] i2c: OMAP: Add DT support for i2c controller
@ 2011-12-22 14:01         ` Cousson, Benoit
  0 siblings, 0 replies; 40+ messages in thread
From: Cousson, Benoit @ 2011-12-22 14:01 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Olof,

On 12/20/2011 10:24 PM, Olof Johansson wrote:
> Hi,
>
> On Tue, Dec 20, 2011 at 8:27 AM, Benoit Cousson<b-cousson@ti.com>  wrote:
>
>> diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
>> index a43d002..dcbc1ec 100644
>> --- a/drivers/i2c/busses/i2c-omap.c
>> +++ b/drivers/i2c/busses/i2c-omap.c
>> @@ -37,6 +37,8 @@
>>   #include<linux/platform_device.h>
>>   #include<linux/clk.h>
>>   #include<linux/io.h>
>> +#include<linux/of_i2c.h>
>> +#include<linux/of_device.h>
>>   #include<linux/slab.h>
>>   #include<linux/i2c-omap.h>
>>   #include<linux/pm_runtime.h>
> [...]
>> @@ -1165,6 +1195,7 @@ static struct platform_driver omap_i2c_driver = {
>>                 .name   = "omap_i2c",
>>                 .owner  = THIS_MODULE,
>>                 .pm     = OMAP_I2C_PM_OPS,
>> +               .of_match_table = of_match_ptr(omap_i2c_of_match),
>>         },
>>   };
>
> of_match_ptr() comes from<linux/of.h>, so you need to include that to
> not break !CONFIG_OF builds.

Good point, I'll fix that.

Thanks,
Benoit

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v3 00/11] OMAP4: Add DT support for i2c and twl6030
  2011-12-20 16:27 ` Benoit Cousson
@ 2011-12-22 15:07   ` Rob Herring
  -1 siblings, 0 replies; 40+ messages in thread
From: Rob Herring @ 2011-12-22 15:07 UTC (permalink / raw)
  To: Benoit Cousson; +Cc: tony, devicetree-discuss, linux-omap, linux-arm-kernel

On 12/20/2011 10:27 AM, Benoit Cousson wrote:
> Hi Tony and Rob,
> 
> Here is the updated version of the i2c + twl DT adaptation series.
> 
> This update, compared to v2 [1], is adding some dedicated dtsi files for
> the twl PMIC and audio IC. These devices will contain a huge amount of
> regulator nodes and thus deserve a dedicated file to avoid every boards
> to redefine the same data.
> The twl patch is now included in Samuel's for-next branch and thus dropped
> from this update.
> The i2c binding was cleaned as suggested by Rob to avoid all the ugly
> hexa flags inside the DTS.
> 
> The pm.c was updated to prevent the SR / VP initialization in the DT
> context since none of them is DT aware for the moment.
> 
> A couple of basic i2c devices are added for panda, beagle and sdp board.
> 
> Patches are based on for_3.3/2_dt_irq, to get the latest GIC binding,
> and are available here:
> git://gitorious.org/omap-pm/linux.git for_3.3/3_omap_dt_i2c_twl
> 
> Tested on Beagle and sdp4430.
> 
> Comments are welcome.
> 
> Regards,
> Benoit
> 
> [1] http://www.spinics.net/lists/linux-omap/msg61260.html
> 
> 
> Benoit Cousson (11):
>   ARM: OMAP2+: pm: Do not init statically the SR and voltage layer with DT
>   i2c: OMAP: Add DT support for i2c controller
>   rtc: rtc-twl: Add DT support for RTC inside twl4030/twl6030
>   arm/dts: OMAP4: Add i2c controller nodes
>   arm/dts: OMAP3: Add i2c controller nodes
>   arm/dts: twl6030: Add DTS file for twl6030 PMIC
>   arm/dts: twl4030: Add DTS file for twl4030 PM + Audio IC
>   arm/dts: omap4-panda: Add twl6030 and i2c EEPROM
>   arm/dts: omap4-sdp: Add twl6030, i2c3 and i2c4 devices
>   arm/dts: omap3-beagle: Add twl4030 and i2c EEPROM
>   ARM: OMAP2+: board-generic: Remove i2c static init
> 
>  Documentation/devicetree/bindings/i2c/omap-i2c.txt |   30 ++++++
>  Documentation/devicetree/bindings/rtc/twl-rtc.txt  |   12 +++
>  arch/arm/boot/dts/omap3-beagle.dts                 |   29 ++++++
>  arch/arm/boot/dts/omap3.dtsi                       |   21 ++++
>  arch/arm/boot/dts/omap4-panda.dts                  |   34 +++++++
>  arch/arm/boot/dts/omap4-sdp.dts                    |   53 ++++++++++
>  arch/arm/boot/dts/omap4.dtsi                       |   28 ++++++
>  arch/arm/boot/dts/twl4030.dtsi                     |   21 ++++
>  arch/arm/boot/dts/twl6030.dtsi                     |   22 ++++
>  arch/arm/mach-omap2/board-generic.c                |   48 +---------
>  arch/arm/mach-omap2/pm.c                           |    8 ++
>  drivers/i2c/busses/i2c-omap.c                      |  101 +++++++++++++-------
>  drivers/rtc/rtc-twl.c                              |   10 ++-
>  13 files changed, 334 insertions(+), 83 deletions(-)
>  create mode 100644 Documentation/devicetree/bindings/i2c/omap-i2c.txt
>  create mode 100644 Documentation/devicetree/bindings/rtc/twl-rtc.txt
>  create mode 100644 arch/arm/boot/dts/twl4030.dtsi
>  create mode 100644 arch/arm/boot/dts/twl6030.dtsi

For the series:

Acked-by: Rob Herring <rob.herring@calxeda.com>

^ permalink raw reply	[flat|nested] 40+ messages in thread

* [PATCH v3 00/11] OMAP4: Add DT support for i2c and twl6030
@ 2011-12-22 15:07   ` Rob Herring
  0 siblings, 0 replies; 40+ messages in thread
From: Rob Herring @ 2011-12-22 15:07 UTC (permalink / raw)
  To: linux-arm-kernel

On 12/20/2011 10:27 AM, Benoit Cousson wrote:
> Hi Tony and Rob,
> 
> Here is the updated version of the i2c + twl DT adaptation series.
> 
> This update, compared to v2 [1], is adding some dedicated dtsi files for
> the twl PMIC and audio IC. These devices will contain a huge amount of
> regulator nodes and thus deserve a dedicated file to avoid every boards
> to redefine the same data.
> The twl patch is now included in Samuel's for-next branch and thus dropped
> from this update.
> The i2c binding was cleaned as suggested by Rob to avoid all the ugly
> hexa flags inside the DTS.
> 
> The pm.c was updated to prevent the SR / VP initialization in the DT
> context since none of them is DT aware for the moment.
> 
> A couple of basic i2c devices are added for panda, beagle and sdp board.
> 
> Patches are based on for_3.3/2_dt_irq, to get the latest GIC binding,
> and are available here:
> git://gitorious.org/omap-pm/linux.git for_3.3/3_omap_dt_i2c_twl
> 
> Tested on Beagle and sdp4430.
> 
> Comments are welcome.
> 
> Regards,
> Benoit
> 
> [1] http://www.spinics.net/lists/linux-omap/msg61260.html
> 
> 
> Benoit Cousson (11):
>   ARM: OMAP2+: pm: Do not init statically the SR and voltage layer with DT
>   i2c: OMAP: Add DT support for i2c controller
>   rtc: rtc-twl: Add DT support for RTC inside twl4030/twl6030
>   arm/dts: OMAP4: Add i2c controller nodes
>   arm/dts: OMAP3: Add i2c controller nodes
>   arm/dts: twl6030: Add DTS file for twl6030 PMIC
>   arm/dts: twl4030: Add DTS file for twl4030 PM + Audio IC
>   arm/dts: omap4-panda: Add twl6030 and i2c EEPROM
>   arm/dts: omap4-sdp: Add twl6030, i2c3 and i2c4 devices
>   arm/dts: omap3-beagle: Add twl4030 and i2c EEPROM
>   ARM: OMAP2+: board-generic: Remove i2c static init
> 
>  Documentation/devicetree/bindings/i2c/omap-i2c.txt |   30 ++++++
>  Documentation/devicetree/bindings/rtc/twl-rtc.txt  |   12 +++
>  arch/arm/boot/dts/omap3-beagle.dts                 |   29 ++++++
>  arch/arm/boot/dts/omap3.dtsi                       |   21 ++++
>  arch/arm/boot/dts/omap4-panda.dts                  |   34 +++++++
>  arch/arm/boot/dts/omap4-sdp.dts                    |   53 ++++++++++
>  arch/arm/boot/dts/omap4.dtsi                       |   28 ++++++
>  arch/arm/boot/dts/twl4030.dtsi                     |   21 ++++
>  arch/arm/boot/dts/twl6030.dtsi                     |   22 ++++
>  arch/arm/mach-omap2/board-generic.c                |   48 +---------
>  arch/arm/mach-omap2/pm.c                           |    8 ++
>  drivers/i2c/busses/i2c-omap.c                      |  101 +++++++++++++-------
>  drivers/rtc/rtc-twl.c                              |   10 ++-
>  13 files changed, 334 insertions(+), 83 deletions(-)
>  create mode 100644 Documentation/devicetree/bindings/i2c/omap-i2c.txt
>  create mode 100644 Documentation/devicetree/bindings/rtc/twl-rtc.txt
>  create mode 100644 arch/arm/boot/dts/twl4030.dtsi
>  create mode 100644 arch/arm/boot/dts/twl6030.dtsi

For the series:

Acked-by: Rob Herring <rob.herring@calxeda.com>

^ permalink raw reply	[flat|nested] 40+ messages in thread

* Re: [PATCH v3 00/11] OMAP4: Add DT support for i2c and twl6030
  2011-12-22 15:07   ` Rob Herring
@ 2011-12-23  9:18     ` Cousson, Benoit
  -1 siblings, 0 replies; 40+ messages in thread
From: Cousson, Benoit @ 2011-12-23  9:18 UTC (permalink / raw)
  To: Rob Herring; +Cc: tony, devicetree-discuss, linux-omap, linux-arm-kernel

On 12/22/2011 4:07 PM, Rob Herring wrote:
> For the series:
>
> Acked-by: Rob Herring<rob.herring@calxeda.com>

Thanks Rob.

Regards,
Benoit


^ permalink raw reply	[flat|nested] 40+ messages in thread

* [PATCH v3 00/11] OMAP4: Add DT support for i2c and twl6030
@ 2011-12-23  9:18     ` Cousson, Benoit
  0 siblings, 0 replies; 40+ messages in thread
From: Cousson, Benoit @ 2011-12-23  9:18 UTC (permalink / raw)
  To: linux-arm-kernel

On 12/22/2011 4:07 PM, Rob Herring wrote:
> For the series:
>
> Acked-by: Rob Herring<rob.herring@calxeda.com>

Thanks Rob.

Regards,
Benoit

^ permalink raw reply	[flat|nested] 40+ messages in thread

end of thread, other threads:[~2011-12-23  9:18 UTC | newest]

Thread overview: 40+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-12-20 16:27 [PATCH v3 00/11] OMAP4: Add DT support for i2c and twl6030 Benoit Cousson
2011-12-20 16:27 ` Benoit Cousson
2011-12-20 16:27 ` [PATCH v3 01/11] ARM: OMAP2+: pm: Do not init statically the SR and voltage layer with DT Benoit Cousson
2011-12-20 16:27   ` Benoit Cousson
2011-12-20 16:27 ` [PATCH v3 02/11] i2c: OMAP: Add DT support for i2c controller Benoit Cousson
2011-12-20 16:27   ` Benoit Cousson
2011-12-20 16:42   ` Rob Herring
2011-12-20 16:42     ` Rob Herring
     [not found]     ` <4EF0BB03.6040906-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2011-12-22  8:55       ` Cousson, Benoit
2011-12-22  8:55         ` Cousson, Benoit
2011-12-20 21:24   ` Olof Johansson
2011-12-20 21:24     ` Olof Johansson
     [not found]     ` <CAOesGMiwg9gVDDwCjuCcAPX6hc2E6OgH-c_nAqhCHmj7y5oCeQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-12-22 14:01       ` Cousson, Benoit
2011-12-22 14:01         ` Cousson, Benoit
     [not found] ` <1324398444-23296-1-git-send-email-b-cousson-l0cyMroinI0@public.gmane.org>
2011-12-20 16:27   ` [PATCH v3 03/11] rtc: rtc-twl: Add DT support for RTC inside twl4030/twl6030 Benoit Cousson
2011-12-20 16:27     ` Benoit Cousson
2011-12-20 16:27 ` [PATCH v3 04/11] arm/dts: OMAP4: Add i2c controller nodes Benoit Cousson
2011-12-20 16:27   ` Benoit Cousson
2011-12-20 16:27 ` [PATCH v3 05/11] arm/dts: OMAP3: " Benoit Cousson
2011-12-20 16:27   ` Benoit Cousson
2011-12-20 16:27 ` [PATCH v3 06/11] arm/dts: twl6030: Add DTS file for twl6030 PMIC Benoit Cousson
2011-12-20 16:27   ` Benoit Cousson
2011-12-20 16:27 ` [PATCH v3 07/11] arm/dts: twl4030: Add DTS file for twl4030 PM + Audio IC Benoit Cousson
2011-12-20 16:27   ` Benoit Cousson
2011-12-20 16:47   ` Rob Herring
2011-12-20 16:47     ` Rob Herring
2011-12-20 16:51     ` Rob Herring
2011-12-20 16:51       ` Rob Herring
2011-12-20 16:27 ` [PATCH v3 08/11] arm/dts: omap4-panda: Add twl6030 and i2c EEPROM Benoit Cousson
2011-12-20 16:27   ` Benoit Cousson
2011-12-20 16:27 ` [PATCH v3 09/11] arm/dts: omap4-sdp: Add twl6030, i2c3 and i2c4 devices Benoit Cousson
2011-12-20 16:27   ` Benoit Cousson
2011-12-20 16:27 ` [PATCH v3 10/11] arm/dts: omap3-beagle: Add twl4030 and i2c EEPROM Benoit Cousson
2011-12-20 16:27   ` Benoit Cousson
2011-12-20 16:27 ` [PATCH v3 11/11] ARM: OMAP2+: board-generic: Remove i2c static init Benoit Cousson
2011-12-20 16:27   ` Benoit Cousson
2011-12-22 15:07 ` [PATCH v3 00/11] OMAP4: Add DT support for i2c and twl6030 Rob Herring
2011-12-22 15:07   ` Rob Herring
2011-12-23  9:18   ` Cousson, Benoit
2011-12-23  9:18     ` Cousson, Benoit

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.