Re: [PATCH] MAINTAINERS: Update entry for omap related .dts files to cover new SoCs

2014-10-21 Thread Benoit Cousson

Hi Nishanth,

On 21/10/2014 22:24, Nishanth Menon wrote:

DRA7(including AM5x) and AM47x series are handled under OMAP umbrella.
These SoC support and dts have been added since 3.14 kernel and Pull
requests for these have come in from OMAP till date.

So just ensure that get_maintainers can pick up this list as well.

Cc: Benoît Cousson bcous...@baylibre.com
Cc: Tony Lindgren t...@atomide.com
Cc: linux-omap@vger.kernel.org
Cc: devicet...@vger.kernel.org
Signed-off-by: Nishanth Menon n...@ti.com


Acked-by: Benoît Cousson bcous...@baylibre.com


Thanks,
Benoit


---
  MAINTAINERS |3 +++
  1 file changed, 3 insertions(+)

diff --git a/MAINTAINERS b/MAINTAINERS
index a20df9b..e205bd2 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -6585,6 +6585,9 @@ L:devicet...@vger.kernel.org
  S:Maintained
  F:arch/arm/boot/dts/*omap*
  F:arch/arm/boot/dts/*am3*
+F: arch/arm/boot/dts/*am4*
+F: arch/arm/boot/dts/*am5*
+F: arch/arm/boot/dts/*dra7*

  OMAP CLOCK FRAMEWORK SUPPORT
  M:Paul Walmsley p...@pwsan.com




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH RFC] ARM: dts: am335x: update USB DT references

2014-04-23 Thread Benoit Cousson

Hi Tony,

On 23/04/2014 16:48, Tony Lindgren wrote:

* Benoit Cousson bcous...@baylibre.com [140422 07:14]:

Hi Leigh,

On 16/04/2014 13:26, Leigh Brown wrote:

In ARM: dts: am33xx: correcting dt node unit address for usb, the
usb_ctrl_mod and cppi41dma nodes were updated with the correct register
addresses.  However, the dts files that reference these nodes were not
updated, and those devices are no longer being enabled.

This patch corrects the references for the affected dts files.


Thanks for the fix. BTW, why is it a RFC? Do you plan to send an updated
version?

FYI, even with this fix, the BBB still does not have a working MUSB on
3.15-rc2. Have you observed that as well?


Signed-off-by: Leigh Brown le...@solinno.co.uk


If this is a final version, I'll apply it for -rc3.


Looks like I already have this in omap-for-v3.15/fixes-v2, sorry
looks like I never replied to this one.


:-)

OK, I'll let you handle this one.

Thanks,
Benoit



Regards,

Tony


---
  arch/arm/boot/dts/am335x-bone-common.dtsi | 4 ++--
  arch/arm/boot/dts/am335x-evm.dts  | 4 ++--
  arch/arm/boot/dts/am335x-evmsk.dts| 4 ++--
  arch/arm/boot/dts/am335x-igep0033.dtsi| 4 ++--
  4 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-bone-common.dtsi 
b/arch/arm/boot/dts/am335x-bone-common.dtsi
index e3f27ec..2e7d932 100644
--- a/arch/arm/boot/dts/am335x-bone-common.dtsi
+++ b/arch/arm/boot/dts/am335x-bone-common.dtsi
@@ -183,7 +183,7 @@
  usb {
status = okay;

-   control@44e1 {
+   control@44e10620 {
status = okay;
};

@@ -204,7 +204,7 @@
dr_mode = host;
};

-   dma-controller@07402000  {
+   dma-controller@47402000  {
status = okay;
};
  };
diff --git a/arch/arm/boot/dts/am335x-evm.dts b/arch/arm/boot/dts/am335x-evm.dts
index 28ae040..77df10d 100644
--- a/arch/arm/boot/dts/am335x-evm.dts
+++ b/arch/arm/boot/dts/am335x-evm.dts
@@ -331,7 +331,7 @@
  usb {
status = okay;

-   control@44e1 {
+   control@44e10620 {
status = okay;
};

@@ -352,7 +352,7 @@
dr_mode = host;
};

-   dma-controller@07402000  {
+   dma-controller@47402000  {
status = okay;
};
  };
diff --git a/arch/arm/boot/dts/am335x-evmsk.dts 
b/arch/arm/boot/dts/am335x-evmsk.dts
index ec08f6f..ab23885 100644
--- a/arch/arm/boot/dts/am335x-evmsk.dts
+++ b/arch/arm/boot/dts/am335x-evmsk.dts
@@ -364,7 +364,7 @@
  usb {
status = okay;

-   control@44e1 {
+   control@44e10620 {
status = okay;
};

@@ -385,7 +385,7 @@
dr_mode = host;
};

-   dma-controller@07402000  {
+   dma-controller@47402000  {
status = okay;
};
  };
diff --git a/arch/arm/boot/dts/am335x-igep0033.dtsi 
b/arch/arm/boot/dts/am335x-igep0033.dtsi
index 7063311..5942e7d 100644
--- a/arch/arm/boot/dts/am335x-igep0033.dtsi
+++ b/arch/arm/boot/dts/am335x-igep0033.dtsi
@@ -202,7 +202,7 @@
  usb {
status = okay;

-   control@44e1 {
+   control@44e10620 {
status = okay;
};

@@ -223,7 +223,7 @@
dr_mode = host;
};

-   dma-controller@07402000  {
+   dma-controller@47402000  {
status = okay;
};
  };




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com



--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH RFC] ARM: dts: am335x: update USB DT references

2014-04-23 Thread Benoit Cousson

Hi Ezequiel,

On 23/04/2014 17:17, Ezequiel Garcia wrote:

On Apr 23, Tony Lindgren wrote:

* Benoit Cousson bcous...@baylibre.com [140422 07:14]:

Hi Leigh,

On 16/04/2014 13:26, Leigh Brown wrote:

In ARM: dts: am33xx: correcting dt node unit address for usb, the
usb_ctrl_mod and cppi41dma nodes were updated with the correct register
addresses.  However, the dts files that reference these nodes were not
updated, and those devices are no longer being enabled.

This patch corrects the references for the affected dts files.


Maybe someone can take care of using phandles instead?

This way, the board's dts files would be immune to such .dtsi changes.


Indeed, that will avoid such issues.

Are you volunteer for that cleanup ? :-)

Thanks,
Benoit


--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH RFC] ARM: dts: am335x: update USB DT references

2014-04-22 Thread Benoit Cousson

Hi Leigh,

On 16/04/2014 13:26, Leigh Brown wrote:

In ARM: dts: am33xx: correcting dt node unit address for usb, the
usb_ctrl_mod and cppi41dma nodes were updated with the correct register
addresses.  However, the dts files that reference these nodes were not
updated, and those devices are no longer being enabled.

This patch corrects the references for the affected dts files.


Thanks for the fix. BTW, why is it a RFC? Do you plan to send an updated 
version?


FYI, even with this fix, the BBB still does not have a working MUSB on 
3.15-rc2. Have you observed that as well?



Signed-off-by: Leigh Brown le...@solinno.co.uk


If this is a final version, I'll apply it for -rc3.

Thanks,
Benoit



---
  arch/arm/boot/dts/am335x-bone-common.dtsi | 4 ++--
  arch/arm/boot/dts/am335x-evm.dts  | 4 ++--
  arch/arm/boot/dts/am335x-evmsk.dts| 4 ++--
  arch/arm/boot/dts/am335x-igep0033.dtsi| 4 ++--
  4 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-bone-common.dtsi 
b/arch/arm/boot/dts/am335x-bone-common.dtsi
index e3f27ec..2e7d932 100644
--- a/arch/arm/boot/dts/am335x-bone-common.dtsi
+++ b/arch/arm/boot/dts/am335x-bone-common.dtsi
@@ -183,7 +183,7 @@
  usb {
status = okay;

-   control@44e1 {
+   control@44e10620 {
status = okay;
};

@@ -204,7 +204,7 @@
dr_mode = host;
};

-   dma-controller@07402000  {
+   dma-controller@47402000  {
status = okay;
};
  };
diff --git a/arch/arm/boot/dts/am335x-evm.dts b/arch/arm/boot/dts/am335x-evm.dts
index 28ae040..77df10d 100644
--- a/arch/arm/boot/dts/am335x-evm.dts
+++ b/arch/arm/boot/dts/am335x-evm.dts
@@ -331,7 +331,7 @@
  usb {
status = okay;

-   control@44e1 {
+   control@44e10620 {
status = okay;
};

@@ -352,7 +352,7 @@
dr_mode = host;
};

-   dma-controller@07402000  {
+   dma-controller@47402000  {
status = okay;
};
  };
diff --git a/arch/arm/boot/dts/am335x-evmsk.dts 
b/arch/arm/boot/dts/am335x-evmsk.dts
index ec08f6f..ab23885 100644
--- a/arch/arm/boot/dts/am335x-evmsk.dts
+++ b/arch/arm/boot/dts/am335x-evmsk.dts
@@ -364,7 +364,7 @@
  usb {
status = okay;

-   control@44e1 {
+   control@44e10620 {
status = okay;
};

@@ -385,7 +385,7 @@
dr_mode = host;
};

-   dma-controller@07402000  {
+   dma-controller@47402000  {
status = okay;
};
  };
diff --git a/arch/arm/boot/dts/am335x-igep0033.dtsi 
b/arch/arm/boot/dts/am335x-igep0033.dtsi
index 7063311..5942e7d 100644
--- a/arch/arm/boot/dts/am335x-igep0033.dtsi
+++ b/arch/arm/boot/dts/am335x-igep0033.dtsi
@@ -202,7 +202,7 @@
  usb {
status = okay;

-   control@44e1 {
+   control@44e10620 {
status = okay;
};

@@ -223,7 +223,7 @@
dr_mode = host;
};

-   dma-controller@07402000  {
+   dma-controller@47402000  {
status = okay;
};
  };




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] ARM: OMAP4: hwmod data: correct the idlemodes for spinlock

2014-03-13 Thread Benoit Cousson

Hi Paul,

On 13/03/2014 22:02, Paul Walmsley wrote:

On Thu, 13 Mar 2014, Tony Lindgren wrote:


* Paul Walmsley p...@pwsan.com [131225 20:51]:

(cc Benoît)

On Mon, 23 Dec 2013, Suman Anna wrote:


The spinlock module's SYSCONFIG register does not support
smart wakeup, so remove this flag from the idle modes in
the spinlock hwmod definition.

Signed-off-by: Suman Anna s-a...@ti.com


Benoît Cousson is the primary maintainer of this file that you're
changing:

$ scripts/get_maintainer.pl -f arch/arm/mach-omap2/omap_hwmod_44xx_data.c
Benoît Cousson bcous...@baylibre.com (maintainer:OMAP HWMOD DATA F...)
Tony Lindgren t...@atomide.com (maintainer:OMAP SUPPORT)
Russell King li...@arm.linux.org.uk (maintainer:ARM PORT)
linux-omap@vger.kernel.org (open list:OMAP HWMOD DATA F...)
linux-arm-ker...@lists.infradead.org (moderated list:ARM SUB-ARCHITECT...)
linux-ker...@vger.kernel.org (open list)
$

Please make sure that he's part of the address list when patches are sent
that apply against this file.


FYI untagging this in my inbox assuming it's being resent or queued by Paul.


Hmm, seems like it's either you or Benoît who is on the hook for this one.

Benoît?

Am happy to queue it if either of you want.


Feel free to queue it, I don't have anything else pending so far, so I 
was not planning to do a pull request.


Acked-by: Benoit Cousson bcous...@baylibre.com

Thanks,
Benoit

--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [GIT PULL] ARM: OMAP: Device Tree for 3.15

2014-03-03 Thread Benoit Cousson

On 02/03/2014 23:17, Tony Lindgren wrote:

* Benoit Cousson bcous...@baylibre.com [140302 12:45]:

Hi Tony,

Please pull the following commits for OMAP Device Tree for v3.15.


Thanks pulling into omap-for-v3.15/dt.


Thank you Tony.

Regards,
Benoit

--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] ARM: dts: add BeagleBone Audio Cape (Rev A) dtsi

2014-03-03 Thread Benoit Cousson

On 28/02/2014 23:17, Tony Lindgren wrote:

* Jack Mitchell m...@embed.me.uk [140122 03:09]:

From: Jack Mitchell j...@embed.me.uk

Devicetree include file for setting up the am335x mcasp bus, i2c-2
bus, and audio codec required for a functioning BeagleBone Audio Cape.

Signed-off-by: Jack Mitchell j...@embed.me.uk
Signed-off-by: Matt Porter mpor...@linaro.org
---
  arch/arm/boot/dts/am335x-bone-audio-cape-reva.dtsi | 124 +
  arch/arm/boot/dts/am335x-bone-common.dtsi  |  14 +++
  2 files changed, 138 insertions(+)
  create mode 100644 arch/arm/boot/dts/am335x-bone-audio-cape-reva.dtsi

diff --git a/arch/arm/boot/dts/am335x-bone-audio-cape-reva.dtsi 
b/arch/arm/boot/dts/am335x-bone-audio-cape-reva.dtsi
new file mode 100644
index 000..b8ec3dc
--- /dev/null
+++ b/arch/arm/boot/dts/am335x-bone-audio-cape-reva.dtsi
@@ -0,0 +1,124 @@
+/*
+ * Copyright (C) 2014 Jack Mitchell j...@embed.me.uk
+ *
+ * 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.
+ *
+ * In order to enable the BeagleBone Audio Cape this dtsi must be
+ * incuded in the top level dts. On BeagleBone Black hardware the
+ * status of the HDMI dts node must also be set to disabled.


Seems like this is unsafe to merge then? This probably also needs
comments from Peter Ujfalusi, added him to Cc.


Maybe, we'd better define a new DTS board (like 
am335x-boneblack-audio.dts) if we cannot use audio cape without losing 
the HDMI.
Since we don't have mechanism like overlay, we don't have the choice but 
defining several boards for each cape variant.


BTW, what is the conflict source with HDMI?
At some point I remember that the mcasp for audio cape was broken 
because of changes in the mcasp for the HDMI, but it is not the case 
anymore, thanks to the cleanup from Jyri.





+ * --- a/arch/arm/boot/dts/am335x-bone.dts
+ * +++ b/arch/arm/boot/dts/am335x-bone.dts
+ * @@ -9,6 +9,7 @@
+ *
+ *  #include am33xx.dtsi
+ *  #include am335x-bone-common.dtsi
+ * +#include am335x-bone-audio-cape-reva.dtsi
+ *
+ *  ldo3_reg {
+ * regulator-min-microvolt = 180;
+ *
+ * On BeagleBone Black hardware the status of the HDMI dts node must
+ * also be set to disabled
+ *
+ * --- a/arch/arm/boot/dts/am335x-boneblack.dts
+ * +++ b/arch/arm/boot/dts/am335x-boneblack.dts
+ * @@ -73,6 +74,6 @@
+ * pinctrl-names = default, off;
+ * pinctrl-0 = nxp_hdmi_bonelt_pins;
+ * pinctrl-1 = nxp_hdmi_bonelt_off_pins;
+ * -   status = okay;
+ * +   status = disabled;
+ * };
+ *  };
+ */
+
+/ {
+   sound {
+   compatible = ti,da830-evm-audio;
+   ti,model = AM335x BeagleBone Audio Cape Rev. A;
+   ti,audio-codec = tlv320aic3106;
+   ti,mcasp-controller = mcasp0;
+   ti,codec-clock-rate = 1200;
+   ti,audio-routing =
+   Headphone Jack,   HPLOUT,
+   Headphone Jack,   HPROUT,
+   LINE1L,   Line In,
+   LINE1R,   Line In;
+   };
+
+   audio-cape-gpio-leds {
+   compatible = gpio-leds;
+   pinctrl-names = default;
+   pinctrl-0 = bone_audio_cape_led_pins;
+
+   audio-led0 {
+   label = audio:green:usr0;
+   gpios = gpio1 18 GPIO_ACTIVE_HIGH;
+   linux,default-trigger = heartbeat;
+   default-state = off;
+   };
+
+   audio-led1 {
+   label = audio:green:usr1;
+   gpios = gpio1 19 GPIO_ACTIVE_HIGH;
+   linux,default-trigger = mmc0;
+   default-state = off;
+   };
+   };
+};
+
+am33xx_pinmux {
+   bone_audio_cape_led_pins: pinmux_bone_audio_cape_led_pins {
+   pinctrl-single,pins = 
+   0x48 (PIN_OUTPUT_PULLDOWN | MUX_MODE7) /* 
gpmc_a2.gpio1_18 */
+   0x4c (PIN_OUTPUT_PULLDOWN | MUX_MODE7) /* 
gpmc_a3.gpio1_19 */
+   ;
+   };
+
+   bone_audio_cape_pins: bone_audio_cape_pins {
+   pinctrl-single,pins = 
+   0x190 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mcasp0_aclkx.mcasp0_aclkx */
+   0x194 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mcasp0_fsx.mcasp0_fsx */
+   0x19c (PIN_INPUT_PULLUP | MUX_MODE2)/* 
mcasp0_ahclkr.mcasp0_axr2 */
+   0x1ac (PIN_INPUT_PULLUP | MUX_MODE2)/* 
mcasp0_ahclkx.mcasp0_axr3 */
+   ;
+   };
+};
+
+i2c2 {
+   pinctrl-names = default;
+   pinctrl-0 = i2c2_pins;
+
+   status = okay;
+   clock-frequency = 10;
+
+   tlv320aic3106: tlv320aic3106@1b {


A more generic name will be prefered here.

Regards,

Re: [PATCHv2 9/9] arm: dts: am43x-gp-evm: Add matrix gpio keys.

2014-03-02 Thread Benoit Cousson

Hi Sourav,

On 21/02/2014 15:28, Sourav Poddar wrote:

Hi Benoit,
On Tuesday 14 January 2014 07:51 PM, Benoit Cousson wrote:

Hi Felipe,

On 14/01/2014 14:14, Felipe Balbi wrote:

On Mon, Jan 13, 2014 at 10:13:13PM +0530, sourav wrote:

Benoit,

On Thursday 19 December 2013 06:03 PM, Sourav Poddar wrote:

Add gpio keys node for am43x gp evm.

Signed-off-by: Sourav Poddarsourav.pod...@ti.com
---
  arch/arm/boot/dts/am437x-gp-evm.dts |   21 +
  1 file changed, 21 insertions(+)

diff --git a/arch/arm/boot/dts/am437x-gp-evm.dts
b/arch/arm/boot/dts/am437x-gp-evm.dts
index 0dc248d..4eb72b8 100644
--- a/arch/arm/boot/dts/am437x-gp-evm.dts
+++ b/arch/arm/boot/dts/am437x-gp-evm.dts
@@ -13,6 +13,7 @@
  #include am4372.dtsi
  #includedt-bindings/pinctrl/am43xx.h
  #includedt-bindings/pwm/pwm.h
+#includedt-bindings/gpio/gpio.h

  / {
  model = TI AM437x GP EVM;
@@ -24,6 +25,26 @@
  brightness-levels =0 51 53 56 62 75 101 152 255;
  default-brightness-level =8;
  };
+
+matrix_keypad: matrix_keypad@0 {
+compatible = gpio-matrix-keypad;
+debounce-delay-ms =5;
+col-scan-delay-us =2;
+
+row-gpios =gpio3 21 GPIO_ACTIVE_HIGH /* Bank3, pin21 */
+ gpio4 3 GPIO_ACTIVE_HIGH /* Bank4, pin3 */
+ gpio4 2 GPIO_ACTIVE_HIGH; /* Bank4, pin2 */
+
+col-gpios =gpio3 19 GPIO_ACTIVE_HIGH /* Bank3, pin19 */
+ gpio3 20 GPIO_ACTIVE_HIGH; /* Bank3, pin20 */
+
+linux,keymap =0x0201  /* P1 */
+0x00010202  /* P2 */
+0x0167  /* UP */
+0x0101006a  /* RIGHT */
+0x0269  /* LEFT */
+0x0201006c;  /* DOWN */
+};
  };

am43xx_pinmux {


ping on this series, this series is lying for a while.
This series is based on your for_3.14 branch.


Benoit, do you need us to do anything else to get this merged ? Sourav
already rebased the patches as you requested back in December 19th.


Nope, I've just needed more BW. I'll apply it ASAP.

Thanks,
Benoit


Ping on this.


I've just applied them. Sorry for the delay,

Regards,
Benoit

--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v5 1/2] arm: dts: omap4+: Add DMM bindings

2014-03-02 Thread Benoit Cousson

Hi Archit,

On 17/12/2013 11:02, Archit Taneja wrote:

Add Dynamic Memory Manager (DMM) bindings for OMAP4 and OMAP5 and DRA7x devices.
DMM only requires address and irq information.

Add documentation for the DMM bindings.

Originally worked on by Andy Gross andy...@gmail.com

Cc: Andy Gross andy...@gmail.com
Signed-off-by: Archit Taneja arc...@ti.com


I've just applied your patch.

Thanks,
Benoit


---
  Documentation/devicetree/bindings/arm/omap/dmm.txt | 22 ++
  arch/arm/boot/dts/dra7.dtsi|  7 +++
  arch/arm/boot/dts/omap4.dtsi   |  7 +++
  arch/arm/boot/dts/omap5.dtsi   |  7 +++
  4 files changed, 43 insertions(+)
  create mode 100644 Documentation/devicetree/bindings/arm/omap/dmm.txt

diff --git a/Documentation/devicetree/bindings/arm/omap/dmm.txt 
b/Documentation/devicetree/bindings/arm/omap/dmm.txt
new file mode 100644
index 000..8bd6d0a
--- /dev/null
+++ b/Documentation/devicetree/bindings/arm/omap/dmm.txt
@@ -0,0 +1,22 @@
+OMAP Dynamic Memory Manager (DMM) bindings
+
+The dynamic memory manager (DMM) is a module located immediately in front of 
the
+SDRAM controllers (called EMIFs on OMAP). DMM manages various aspects of memory
+accesses such as priority generation amongst initiators, configuration of SDRAM
+interleaving, optimizing transfer of 2D block objects, and provide MMU-like 
page
+translation for initiators which need contiguous dma bus addresses.
+
+Required properties:
+- compatible:  Should contain ti,omap4-dmm for OMAP4 family
+   Should contain ti,omap5-dmm for OMAP5 and DRA7x family
+- reg: Contains DMM register address range (base address and length)
+- interrupts:  Should contain an interrupt-specifier for DMM_IRQ.
+- ti,hwmods:   Name of the hwmod associated to DMM, which is typically dmm
+
+Example:
+
+dmm@4e00 {
+   compatible = ti,omap4-dmm;
+   reg = 0x4e00 0x800;
+   ti,hwmods = dmm;
+};
diff --git a/arch/arm/boot/dts/dra7.dtsi b/arch/arm/boot/dts/dra7.dtsi
index d0df4c4..c9bb006 100644
--- a/arch/arm/boot/dts/dra7.dtsi
+++ b/arch/arm/boot/dts/dra7.dtsi
@@ -425,6 +425,13 @@
ti,hwmods = wd_timer2;
};

+   dmm@4e00 {
+   compatible = ti,omap5-dmm;
+   reg = 0x4e00 0x800;
+   interrupts = 0 113 0x4;
+   ti,hwmods = dmm;
+   };
+
i2c1: i2c@4807 {
compatible = ti,omap4-i2c;
reg = 0x4807 0x100;
diff --git a/arch/arm/boot/dts/omap4.dtsi b/arch/arm/boot/dts/omap4.dtsi
index a1e0585..3c67b2f 100644
--- a/arch/arm/boot/dts/omap4.dtsi
+++ b/arch/arm/boot/dts/omap4.dtsi
@@ -502,6 +502,13 @@
ti,hwmods = kbd;
};

+   dmm@4e00 {
+   compatible = ti,omap4-dmm;
+   reg = 0x4e00 0x800;
+   interrupts = 0 113 0x4;
+   ti,hwmods = dmm;
+   };
+
emif1: emif@4c00 {
compatible = ti,emif-4d;
reg = 0x4c00 0x100;
diff --git a/arch/arm/boot/dts/omap5.dtsi b/arch/arm/boot/dts/omap5.dtsi
index fc3fad5..878f635 100644
--- a/arch/arm/boot/dts/omap5.dtsi
+++ b/arch/arm/boot/dts/omap5.dtsi
@@ -621,6 +621,13 @@
ti,hwmods = wd_timer2;
};

+   dmm@4e00 {
+   compatible = ti,omap5-dmm;
+   reg = 0x4e00 0x800;
+   interrupts = 0 113 0x4;
+   ti,hwmods = dmm;
+   };
+
emif1: emif@4c00 {
compatible  = ti,emif-4d5;
ti,hwmods   = emif1;




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[GIT PULL] ARM: OMAP: Device Tree for 3.15

2014-03-02 Thread Benoit Cousson
Hi Tony,

Please pull the following commits for OMAP Device Tree for v3.15.

Thanks,
Benoît


The following changes since commit 6d0abeca3242a88cab8232e4acd7e2bf088f3bc2:

  Linux 3.14-rc3 (2014-02-16 13:30:25 -0800)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/bcousson/linux-omap-dt.git 
tags/for_3.15/dts_signed

for you to fetch changes up to 1a5fe3ca5ea192d4309dd61f3626b79ff38693c2:

  ARM: dts: omap4+: Add DMM bindings (2014-03-02 21:26:27 +0100)


Add craneboard devices
Add more N900 devices
Add am43x-epos-evm and am437x-gp-evm devices
Add OMAP4 DMM devices


Archit Taneja (1):
  ARM: dts: omap4+: Add DMM bindings

Darren Etheridge (1):
  pinctrl: am43xx: dt-bindings: add MUX_MODE8

Lokesh Vutla (1):
  ARM: dts: am437x-gp-evm: Add gp dts.

Nishanth Menon (2):
  ARM: dts: Add basic devices for AM3517-craneboard
  ARM: dts: omap3430-sdp: add dip switch information for MMC operation

Sebastian Reichel (6):
  ARM: dts: TWL4030: Add keypad node
  ARM: dts: OMAP3-N900: Add TWL4030 Keypad Matrix
  ARM: dts: OMAP3-N900: Add support for tsl2563
  ARM: dts: OMAP3-N900: Add tpa6130a2 support
  ARM: dts: OMAP3-N900: Add isp1704 support
  ARM: dts: OMAP3-N900: Add bq24150a support

Sourav Poddar (7):
  ARM: dts: am4372: Add pwm-cells property for ecap device.
  ARM: dts: am43x-epos-evm: Add pwm backlight support.
  ARM: dts: am43x-epos-evm: Add I2C2 data.
  ARM: dts: am43x-epos-evm: Add SPI data.
  ARM: dts: am437x-gp-evm: Add pwm backlight support.
  ARM: dts: am437x-gp-evm: Enable gpio.
  ARM: dts: am43x-gp-evm: Add matrix gpio keys.

 Documentation/devicetree/bindings/arm/omap/dmm.txt  |  22 ++
 Documentation/devicetree/bindings/arm/omap/omap.txt |   3 ++
 arch/arm/boot/dts/Makefile  |   2 +
 arch/arm/boot/dts/am3517-craneboard.dts | 174 
+++
 arch/arm/boot/dts/am4372.dtsi   |   9 +
 arch/arm/boot/dts/am437x-gp-evm.dts | 100 
+
 arch/arm/boot/dts/am43x-epos-evm.dts|  67 
+++
 arch/arm/boot/dts/dra7.dtsi |   7 
 arch/arm/boot/dts/omap3-n900.dts|  90 
+
 arch/arm/boot/dts/omap3430-sdp.dts  |   4 ++
 arch/arm/boot/dts/omap4.dtsi|   7 
 arch/arm/boot/dts/omap5.dtsi|   7 
 arch/arm/boot/dts/twl4030.dtsi  |   7 
 include/dt-bindings/pinctrl/am43xx.h|   1 +
 14 files changed, 500 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/arm/omap/dmm.txt
 create mode 100644 arch/arm/boot/dts/am3517-craneboard.dts
 create mode 100644 arch/arm/boot/dts/am437x-gp-evm.dts

-- 
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 0/6] N900 DTS additions for 3.14

2014-02-21 Thread Benoit Cousson

Hi Sebastian,

On 29/01/2014 16:03, Sebastian Reichel wrote:

Hi,

On Sat, Jan 11, 2014 at 10:16:57PM +0100, Sebastian Reichel wrote:

Here are a couple of additions for the Nokia N900 Device Tree
Source file. All related drivers changes are queued for 3.14
(except for the tpa6130a2, which got merged into 3.13).

I may have some more additions if the driver changes for the
accelerometer, the touchscreen or the wireless lan chip will be
queued up.


Ping. If I'm not mistaken the merge window will probably be closed
at the weekend (2014-01-19 + 2 weeks = 2014-02-02).

P.S.: Accelerometer, Touchscreen and WLAN driver changes haven't
made it into 3.14, so the patchset I mailed is complete.



Sorry for the delay, I've just applied them for 3.15.

BTW, do you have any other pending DTS patches?

Thanks,
Benoit

--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] ARM: dts: OMAP5: add pmu node

2014-02-12 Thread Benoit Cousson

Hi Nathan,

On 11/02/2014 21:14, Nathan Lynch wrote:

On 01/29/2014 10:56 AM, Nathan Lynch wrote:

Expose the PMU on OMAP5.

Signed-off-by: Nathan Lynch nathan_ly...@mentor.com


OMAP folks, any issues with this patch?


Yes :-)


Notes:
 Briefly tested with perf on OMAP5 UEVM with next-20140124.

  arch/arm/boot/dts/omap5.dtsi | 6 ++
  1 file changed, 6 insertions(+)

diff --git a/arch/arm/boot/dts/omap5.dtsi b/arch/arm/boot/dts/omap5.dtsi
index a72813a9663e..fbf4661436e2 100644
--- a/arch/arm/boot/dts/omap5.dtsi
+++ b/arch/arm/boot/dts/omap5.dtsi
@@ -76,6 +76,12 @@
 GIC_PPI 10 (GIC_CPU_MASK_RAW(3) | 
IRQ_TYPE_LEVEL_LOW);
};

+   pmu {
+   compatible = arm,cortex-a15-pmu;
+   interrupts = 0 131 4,
+0 132 4;


Could you use the macros instead of hard coded value? You have the 
example just before your modification in the patch itself.


Thanks,
Benoit

--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 0/6] N900 DTS additions for 3.14

2014-01-21 Thread Benoit Cousson

Hi Sebastian,

On 20/01/2014 16:59, Sebastian Reichel wrote:

On Sat, Jan 11, 2014 at 10:16:57PM +0100, Sebastian Reichel wrote:

Here are a couple of additions for the Nokia N900 Device Tree
Source file. All related drivers changes are queued for 3.14
(except for the tpa6130a2, which got merged into 3.13).

I may have some more additions if the driver changes for the
accelerometer, the touchscreen or the wireless lan chip will be
queued up.


ping?

Also it seems, that for_3.14/dts branch on bcousson/linux-omap-dt.git
merged some branches, which Tony no longer intends to be merged for
3.14.


Yeah, I will have to sync with Tony to understand what will be in 3.14-rc1.

Do you have strong dep with the series Tony has done?

Regards,
Benoit

--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCHv2 9/9] arm: dts: am43x-gp-evm: Add matrix gpio keys.

2014-01-14 Thread Benoit Cousson

Hi Felipe,

On 14/01/2014 14:14, Felipe Balbi wrote:

On Mon, Jan 13, 2014 at 10:13:13PM +0530, sourav wrote:

Benoit,

On Thursday 19 December 2013 06:03 PM, Sourav Poddar wrote:

Add gpio keys node for am43x gp evm.

Signed-off-by: Sourav Poddarsourav.pod...@ti.com
---
  arch/arm/boot/dts/am437x-gp-evm.dts |   21 +
  1 file changed, 21 insertions(+)

diff --git a/arch/arm/boot/dts/am437x-gp-evm.dts 
b/arch/arm/boot/dts/am437x-gp-evm.dts
index 0dc248d..4eb72b8 100644
--- a/arch/arm/boot/dts/am437x-gp-evm.dts
+++ b/arch/arm/boot/dts/am437x-gp-evm.dts
@@ -13,6 +13,7 @@
  #include am4372.dtsi
  #includedt-bindings/pinctrl/am43xx.h
  #includedt-bindings/pwm/pwm.h
+#includedt-bindings/gpio/gpio.h

  / {
model = TI AM437x GP EVM;
@@ -24,6 +25,26 @@
brightness-levels =0 51 53 56 62 75 101 152 255;
default-brightness-level =8;
};
+
+   matrix_keypad: matrix_keypad@0 {
+   compatible = gpio-matrix-keypad;
+   debounce-delay-ms =5;
+   col-scan-delay-us =2;
+
+   row-gpios =gpio3 21 GPIO_ACTIVE_HIGH /* Bank3, pin21 */
+   gpio4 3 GPIO_ACTIVE_HIGH /* Bank4, pin3 */
+   gpio4 2 GPIO_ACTIVE_HIGH; /* Bank4, pin2 */
+
+   col-gpios =gpio3 19 GPIO_ACTIVE_HIGH /* Bank3, pin19 */
+   gpio3 20 GPIO_ACTIVE_HIGH; /* Bank3, pin20 */
+
+   linux,keymap =0x0201  /* P1 */
+   0x00010202  /* P2 */
+   0x0167  /* UP */
+   0x0101006a  /* RIGHT */
+   0x0269  /* LEFT */
+   0x0201006c;  /* DOWN */
+   };
  };

  am43xx_pinmux {


ping on this series, this series is lying for a while.
This series is based on your for_3.14 branch.


Benoit, do you need us to do anything else to get this merged ? Sourav
already rebased the patches as you requested back in December 19th.


Nope, I've just needed more BW. I'll apply it ASAP.

Thanks,
Benoit

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


Re: [PATCH 00/18] ARM: dts: Better support for Gumstix Overo

2014-01-09 Thread Benoit Cousson

Hi Florian,

On 09/01/2014 17:47, Florian Vaussard wrote:

Hello,

This series adds a number of improvements to Gumstix Overo.


Thanks for that nice series.


Patch 1+2: fix an issue with the vendor prefix (reported long ago by Javier 
Martinez Canillas)
Patch 3+4: add some missing pinctrl entries
Patch 5: completely turn off the PMIC on power off
Patch 6: enable the on-board Wifi
Patch 7: add the high-speed USB PHY
Patch 8: add specific timings for LAN9221 into a generic file
- This might interest other people using the same chip, result in doubled 
bandwith

Patch 9: simplify omap3-tobi by using patch 8
Patch 10: add support for AT24C01 EEPROM used on expansion boards
Patch 11: factorize parts common to all expansion boards
Patch 12: rename omap3-tobi to omap3-overo-tobi
- I do not know to which extent this might qualify as an API breakage,
but the new name is far better IMHO

Patch 13 to 17: add new extension boards (Palo43, Gallop43, Alto35, Chestnut43, 
Summit)
Patch 18: add the HDMI output
- this patch depends on Tomi Valkeinen's DT binding for OMAPDSS, which is
not yet merged, so this patch will have to wait


The patches 13 to 17 are based on the hardware schematics and compile-tested, 
as I
do not have the necessary hardware (anyone willing to send me some boards ? :-)
We are mainly missing the support for the various LCDs, the accelerometer + 
probably
other small things.

This series is based on Tony's omap-for-v3.14/dt branch + work from Tomi [1] 
for the patch 18.

Benoit: I guess that I am too late for the 3.14... ?


Yeah, I think so, even my 3.14 branch is too late for 3.14 :-)

Thanks,
Benoit



Regards,

Florian


Florian Vaussard (18):
   of: add vendor prefix for Gumstix
   ARM: dts: omap3-tobi: Use the correct vendor prefix
   ARM: dts: omap3-tobi: Add missing pinctrl
   ARM: dts: omap3-overo: Add missing pinctrl
   ARM: dts: omap3-overo: Use complete poweroff
   ARM: dts: omap3-overo: Enable MMC2
   ARM: dts: omap3-overo: Add HSUSB PHY
   ARM: dts: omap: Add common file for SMSC9221
   ARM: dts: omap3-tobi: Use include file omap-gpmc-smsc9221
   ARM: dts: omap3-tobi: Add AT24C01 EEPROM
   ARM: dts: omap3-tobi: Create a file for common Gumstix peripherals
   ARM: dts: omap3-tobi: Rename to omap3-overo-tobi
   ARM: dts: Add support for the Overo Palo43
   ARM: dts: Add support for the Overo Gallop43
   ARM: dts: Add support for the Overo Alto35
   ARM: dts: Add support for the Overo Chestnut43
   ARM: dts: Add support for the Overo Summit
   ARM: dts: overo: Add support for DVI output

  .../devicetree/bindings/vendor-prefixes.txt|   1 +
  arch/arm/boot/dts/Makefile |   7 +-
  arch/arm/boot/dts/omap-gpmc-smsc9221.dtsi  |  58 ++
  arch/arm/boot/dts/omap3-overo-alto35.dts   |  52 +
  arch/arm/boot/dts/omap3-overo-chestnut43.dts   |  76 +
  arch/arm/boot/dts/omap3-overo-common-dvi.dtsi  | 108 ++
  arch/arm/boot/dts/omap3-overo-common.dtsi  |  39 +++
  arch/arm/boot/dts/omap3-overo-gallop43.dts |  51 +
  arch/arm/boot/dts/omap3-overo-palo43.dts   |  52 +
  arch/arm/boot/dts/omap3-overo-summit.dts   |  30 +
  .../dts/{omap3-tobi.dts = omap3-overo-tobi.dts}   |  41 +--
  arch/arm/boot/dts/omap3-overo.dtsi | 122 +++--
  12 files changed, 594 insertions(+), 43 deletions(-)
  create mode 100644 arch/arm/boot/dts/omap-gpmc-smsc9221.dtsi
  create mode 100644 arch/arm/boot/dts/omap3-overo-alto35.dts
  create mode 100644 arch/arm/boot/dts/omap3-overo-chestnut43.dts
  create mode 100644 arch/arm/boot/dts/omap3-overo-common-dvi.dtsi
  create mode 100644 arch/arm/boot/dts/omap3-overo-common.dtsi
  create mode 100644 arch/arm/boot/dts/omap3-overo-gallop43.dts
  create mode 100644 arch/arm/boot/dts/omap3-overo-palo43.dts
  create mode 100644 arch/arm/boot/dts/omap3-overo-summit.dts
  rename arch/arm/boot/dts/{omap3-tobi.dts = omap3-overo-tobi.dts} (54%)




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] ARM: dts: omap3430-sdp: add dip switch information for MMC operation

2014-01-06 Thread Benoit Cousson

Hi Nishanth,

On 06/01/2014 23:37, Nishanth Menon wrote:

MMC 8 bit mode operation depends on dip switch setting which is not
obvious - The current board file has this description. However, with
removal of the board file in the future, this information will be lost
and has to be rediscovered.


Thanks for that. I've just applied it.

Regards,
Benoit



Signed-off-by: Nishanth Menon n...@ti.com
---
  arch/arm/boot/dts/omap3430-sdp.dts |4 
  1 file changed, 4 insertions(+)

diff --git a/arch/arm/boot/dts/omap3430-sdp.dts 
b/arch/arm/boot/dts/omap3430-sdp.dts
index 281914e..cd3d047 100644
--- a/arch/arm/boot/dts/omap3430-sdp.dts
+++ b/arch/arm/boot/dts/omap3430-sdp.dts
@@ -34,6 +34,10 @@
  mmc1 {
vmmc-supply = vmmc1;
vmmc_aux-supply = vsim;
+   /*
+* S6-3 must be in ON position for 8 bit mode to function
+* Else, use 4 bit mode
+*/
bus-width = 8;
  };


--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] ARM: dts: Add basic devices for AM3517-craneboard

2013-12-18 Thread Benoit Cousson

Hi Nishanth,

On 17/12/2013 20:45, Nishanth Menon wrote:

On 12/09/2013 03:55 PM, Nishanth Menon wrote:

Craneboard is a hardware development platform based on the Sitara
AM3517 ARM Cortex - A8 microprocessor device - see [1] for more
details. Add basic devices for craneboard as replacement for the board
file scheduled for removal as part of device tree conversion

[1] http://craneboard.org

Signed-off-by: Nishanth Menon n...@ti.com
---


gentle ping.. had'nt seen a response on this patch. Could we queue
this up for v3.14-rc1?


Yep, it looks good to me.
But if you don't mind I'll start pushing my branch after Xmas :-).

Thanks,
Benoit



Based on:
git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap.git
branch: omap-for-v3.14/omap3-board-removal 736e812 ARM: OMAP2+: Remove unused 
platform init code and headers

Bootlog: http://pastebin.mozilla.org/3744412

  arch/arm/boot/dts/Makefile  |1 +
  arch/arm/boot/dts/am3517-craneboard.dts |  174 +++
  2 files changed, 175 insertions(+)
  create mode 100644 arch/arm/boot/dts/am3517-craneboard.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index fc37bca..ad155fc 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -205,6 +205,7 @@ dtb-$(CONFIG_ARCH_OMAP2PLUS) += omap2420-h4.dtb \
am335x-boneblack.dtb \
am335x-nano.dtb \
am335x-base0033.dtb \
+   am3517-craneboard.dtb \
am3517-evm.dtb \
am3517_mt_ventoux.dtb \
am43x-epos-evm.dtb \
diff --git a/arch/arm/boot/dts/am3517-craneboard.dts 
b/arch/arm/boot/dts/am3517-craneboard.dts
new file mode 100644
index 000..2d40b3f
--- /dev/null
+++ b/arch/arm/boot/dts/am3517-craneboard.dts
@@ -0,0 +1,174 @@
+/*
+ * See craneboard.org for more details
+ *
+ * Copyright (C) 2013 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.
+ */
+/dts-v1/;
+
+#include am3517.dtsi
+
+/ {
+   model = TI AM3517 CraneBoard (TMDSEVM3517);
+   compatible = ti,am3517-craneboard, ti,am3517, ti,omap3;
+
+   memory {
+   device_type = memory;
+   reg = 0x8000 0x1000;/* 256 MB */
+   };
+
+   vbat: fixedregulator@0 {
+   compatible = regulator-fixed;
+   regulator-name = vbat;
+   regulator-min-microvolt = 500;
+   regulator-max-microvolt = 500;
+   regulator-boot-on;
+   };
+};
+
+davinci_emac {
+   status = okay;
+};
+
+davinci_mdio {
+   status = okay;
+};
+
+i2c1 {
+   clock-frequency = 260;
+
+   tps: tps@2d {
+   reg = 0x2d;
+   };
+};
+
+i2c2 {
+   clock-frequency = 40;
+   /* goes to expansion connector */
+   status = disabled;
+};
+
+i2c3 {
+   clock-frequency = 40;
+   /* goes to expansion connector */
+   status = disabled;
+};
+
+mmc1 {
+   vmmc-supply = vdd2_reg;
+   bus-width = 8;
+};
+
+mmc2 {
+   /* goes to expansion connector */
+   status = disabled;
+};
+
+mmc3 {
+   /* goes to expansion connector */
+   status = disabled;
+};
+
+#include tps65910.dtsi
+
+omap3_pmx_core {
+   tps_pins: pinmux_tps_pins {
+   pinctrl-single,pins = 
+   0x1b0 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
sys_nirq.sys_nirq */
+   ;
+   };
+};
+
+tps {
+   pinctrl-names = default;
+   pinctrl-0 = tps_pins;
+
+   interrupts = 7; /* SYS_NIRQ cascaded to intc */
+   interrupt-parent = intc;
+
+   ti,en-ck32k-xtal;
+
+   vcc1-supply = vbat;
+   vcc2-supply = vbat;
+   vcc3-supply = vbat;
+   vcc4-supply = vbat;
+   vcc5-supply = vbat;
+   vcc6-supply = vbat;
+   vcc7-supply = vbat;
+   vccio-supply = vbat;
+
+   regulators {
+   vrtc_reg: regulator@0 {
+   regulator-always-on;
+   };
+
+   vio_reg: regulator@1 {
+   regulator-always-on;
+   };
+
+   /*
+* Unused:
+* VDIG1=2.7V,300mA max
+* VDIG2=1.8V,300mA max
+*/
+
+   vpll_reg: regulator@7 {
+   /* VDDS_DPLL_1V8 */
+   regulator-min-microvolt = 180;
+   regulator-max-microvolt = 180;
+   regulator-always-on;
+   };
+
+   vaux1_reg: regulator@9 {
+   /* VDDS_SRAM_1V8 */
+   regulator-min-microvolt = 180;
+   regulator-max-microvolt = 180;
+   regulator-always-on;
+   };
+
+   vaux2_reg: regulator@10 {
+   /* VDDA1P8V_USBPHY */
+ 

Re: [PATCH] ARM: dts: Add basic devices for AM3517-craneboard

2013-12-18 Thread Benoit Cousson

On 18/12/2013 18:02, Nishanth Menon wrote:

On 12/18/2013 10:57 AM, Benoit Cousson wrote:

On 17/12/2013 20:45, Nishanth Menon wrote:

On 12/09/2013 03:55 PM, Nishanth Menon wrote:

Craneboard is a hardware development platform based on the Sitara
AM3517 ARM Cortex - A8 microprocessor device - see [1] for more
details. Add basic devices for craneboard as replacement for the board
file scheduled for removal as part of device tree conversion

[1] http://craneboard.org

Signed-off-by: Nishanth Menon n...@ti.com
---


gentle ping.. had'nt seen a response on this patch. Could we queue
this up for v3.14-rc1?


Yep, it looks good to me.

Thanks benoit.


But if you don't mind I'll start pushing my branch after Xmas :-).


As long as Tony is ok with it, I have no issues either - will be great
to have dt only boot in .14-rc1 though.


Good point, it is already -rc4.

OK, I'll just queued it and pushed it to for_3.14/dts.

Regards,
Benoit

--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 0/3] Add more device nodes for am43x gp evm.

2013-12-18 Thread Benoit Cousson

Hi Sourav,

On 18/12/2013 18:43, Sourav Poddar wrote:

Benoit,
On Wednesday 27 November 2013 01:01 PM, Sourav Poddar wrote:

The patch series adds support for enabling gpio, pwm backlight and
matrix gpio keys on am43x-gp-evm.

Done on top of 3.13-rc1 + tero clock series(1) + Afzal's basic gp
support(2).

[1]: https://patchwork.kernel.org/patch/3009541/
[2]: https://patchwork.kernel.org/patch/3171761/

Tested on am43x-gp-evm.

There is a some bug while using regulators through backlight
driver on 3.13-rc1. So, tested pwm part with this patch[3].

[3]: http://www.spinics.net/lists/arm-kernel/msg288215.html

Sourav Poddar (3):
   arm: dts: am437x-gp-evm: Enable gpio.
   ARM: dts: am43x-gp-evm: Add matrix gpio keys.
   ARM: dts: am437x-gp-evm: Add pwm backlight support.

  arch/arm/boot/dts/am437x-gp-evm.dts |   53
+++
  1 files changed, 53 insertions(+), 0 deletions(-)


Ping on this?


The series looks good, but you should rebase it on top of for_3.14/dts 
that is based on the big cleanup branch Tony has done.

I cannot apply it right now.

Thanks,
Benoit


--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 0/3] Add more device nodes for am43x gp evm.

2013-12-18 Thread Benoit Cousson

On 18/12/2013 19:15, Sourav Poddar wrote:

On Wednesday 18 December 2013 11:19 PM, Benoit Cousson wrote:

Hi Sourav,

On 18/12/2013 18:43, Sourav Poddar wrote:

Benoit,
On Wednesday 27 November 2013 01:01 PM, Sourav Poddar wrote:

The patch series adds support for enabling gpio, pwm backlight and
matrix gpio keys on am43x-gp-evm.

Done on top of 3.13-rc1 + tero clock series(1) + Afzal's basic gp
support(2).

[1]: https://patchwork.kernel.org/patch/3009541/
[2]: https://patchwork.kernel.org/patch/3171761/

Tested on am43x-gp-evm.

There is a some bug while using regulators through backlight
driver on 3.13-rc1. So, tested pwm part with this patch[3].

[3]: http://www.spinics.net/lists/arm-kernel/msg288215.html

Sourav Poddar (3):
   arm: dts: am437x-gp-evm: Enable gpio.
   ARM: dts: am43x-gp-evm: Add matrix gpio keys.
   ARM: dts: am437x-gp-evm: Add pwm backlight support.

  arch/arm/boot/dts/am437x-gp-evm.dts |   53
+++
  1 files changed, 53 insertions(+), 0 deletions(-)


Ping on this?


The series looks good, but you should rebase it on top of for_3.14/dts
that is based on the big cleanup branch Tony has done.
I cannot apply it right now.


Ok. I will rebase it and send you the series, As you can see there is
one dependency on afzal  basic support patch, as mentioned in
the cover letter. If you are ok with that patch, it has to go first. So,
if you wish I can work with afzal and send you this
series and afzal patch together.


Yes, go ahead and repost the whole series with the depency.

BTW, could you do that as well with your other series?

Thanks,
Benoit
--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 1/3] ARM: OMAP4+: hwmod data: Don't prevent RESET of USB Host module

2013-12-09 Thread Benoit Cousson

Salut Paul,

On 08/12/2013 17:26, Paul Walmsley wrote:

Hi Benoît,

On Tue, 3 Dec 2013, Roger Quadros wrote:


Without this, the USB devices are sometimes not detected on OMAP4 Panda
with u-boot v2013.10.

Unlike what the comment states, errata i660 does not state that we
can't RESET the USB host module. Instead it states that RESET is the
only way to recover from a deadlock situation.

RESET ensures that the module is in a known good state irrespective
of what bootloader does with the module, so it must be done at boot.

Reported-by: Tomi Valkeinen tomi.valkei...@ti.com
Signed-off-by: Roger Quadros rog...@ti.com


Acked-by: Paul Walmsley p...@pwsan.com

Will you pick this up for the -rc series, or do you want me or Tony to?
Roger writes that this one's pretty important.


I guess, it is better for you to take it. I don't have anything queued 
for -rc.


Acked-by: Benoit Cousson bcous...@baylibre.com

Thanks,
Benoit




- Paul



---
  arch/arm/mach-omap2/omap_hwmod_44xx_data.c | 12 ++--
  arch/arm/mach-omap2/omap_hwmod_54xx_data.c | 13 +++--
  2 files changed, 5 insertions(+), 20 deletions(-)

diff --git a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c 
b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
index 1e5b12c..3318cae9 100644
--- a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
+++ b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
@@ -2937,7 +2937,7 @@ static struct omap_hwmod_class_sysconfig 
omap44xx_usb_host_hs_sysc = {
.sysc_offs  = 0x0010,
.syss_offs  = 0x0014,
.sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE |
-  SYSC_HAS_SOFTRESET),
+  SYSC_HAS_SOFTRESET | SYSC_HAS_RESET_STATUS),
.idlemodes  = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
   SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
   MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
@@ -3001,15 +3001,7 @@ static struct omap_hwmod omap44xx_usb_host_hs_hwmod = {
 * hence HWMOD_SWSUP_MSTANDBY
 */

-   /*
-* During system boot; If the hwmod framework resets the module
-* the module will have smart idle settings; which can lead to deadlock
-* (above Errata Id:i660); so, dont reset the module during boot;
-* Use HWMOD_INIT_NO_RESET.
-*/
-
-   .flags  = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
- HWMOD_INIT_NO_RESET,
+   .flags  = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
  };

  /*
diff --git a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c 
b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
index 9e08d69..e297d62 100644
--- a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
+++ b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
@@ -1544,7 +1544,8 @@ static struct omap_hwmod_class_sysconfig 
omap54xx_usb_host_hs_sysc = {
.rev_offs   = 0x,
.sysc_offs  = 0x0010,
.sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_RESET_STATUS |
-  SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
+  SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
+  SYSC_HAS_RESET_STATUS),
.idlemodes  = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
   SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
   MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
@@ -1598,15 +1599,7 @@ static struct omap_hwmod omap54xx_usb_host_hs_hwmod = {
 * hence HWMOD_SWSUP_MSTANDBY
 */

-   /*
-* During system boot; If the hwmod framework resets the module
-* the module will have smart idle settings; which can lead to deadlock
-* (above Errata Id:i660); so, dont reset the module during boot;
-* Use HWMOD_INIT_NO_RESET.
-*/
-
-   .flags  = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
- HWMOD_INIT_NO_RESET,
+   .flags  = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
.main_clk   = l3init_60m_fclk,
.prcm = {
.omap4 = {
--
1.8.3.2




- Paul




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] ARM: DTS: omap4-sdp: Add regulator for LCD backlight (pwm-backlight)

2013-11-28 Thread Benoit Cousson

Hi Peter,

On 28/11/2013 10:28, Peter Ujfalusi wrote:

Since in DT booted kernel dummy regulators are no longer supported we need
to provide valid phandle for the regulator needed by the backlight.
On the board VBAT is used to power the LCD backlight(s).

Signed-off-by: Peter Ujfalusi peter.ujfal...@ti.com
---
Hi,

This patch is needed for 3.13 to get the LCD backlight to work again.


OK, so this is a fix for the next -rc?

Regards,
Benoit



Regards,
Peter

  arch/arm/boot/dts/omap4-sdp.dts | 1 +
  1 file changed, 1 insertion(+)

diff --git a/arch/arm/boot/dts/omap4-sdp.dts b/arch/arm/boot/dts/omap4-sdp.dts
index 5fc3f43..6f86db2 100644
--- a/arch/arm/boot/dts/omap4-sdp.dts
+++ b/arch/arm/boot/dts/omap4-sdp.dts
@@ -104,6 +104,7 @@
100 110 120 127
;
default-brightness-level = 13;
+   power-supply = vbat;
};

sound {




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH RFC] ARM/dts: am335x-boneblack: Add HDMI audio support

2013-11-19 Thread Benoit Cousson

Hi Jyri,

A side question related to audio cape support on BBB. In the official 
3.8.13 CircuitCo version the HDMI audio support was breaking the 
audio-cape support due to some bad hacks in the mcasp driver.


Is this still the case with you series?

Thanks,
Benoit


On 19/11/2013 13:21, Jyri Sarha wrote:

Adds mcasp0_pins, clk_mcasp0_fixed, clk_mcasp0, mcasp0, hdmi_audio,
and sound nodes.

Signed-off-by: Jyri Sarha jsa...@ti.com
---
  arch/arm/boot/dts/am335x-boneblack.dts |   52 
  1 file changed, 52 insertions(+)

diff --git a/arch/arm/boot/dts/am335x-boneblack.dts 
b/arch/arm/boot/dts/am335x-boneblack.dts
index 6b71ad9..b5a2404 100644
--- a/arch/arm/boot/dts/am335x-boneblack.dts
+++ b/arch/arm/boot/dts/am335x-boneblack.dts
@@ -60,12 +60,35 @@
0x1b0 0x03  /* xdma_event_intr0, OMAP_MUX_MODE3 | 
AM33XX_PIN_OUTPUT */
;
};
+
+   mcasp0_pins: mcasp0_pins {
+   pinctrl-single,pins = 
+   0x1ac (PIN_INPUT_PULLUP | MUX_MODE0) /* 
mcasp0_ahclkx.mcasp0_ahclkx */
+   0x19c (PIN_OUTPUT_PULLDOWN | MUX_MODE2) /* 
mcasp0_ahclkr.mcasp0_axr2 */
+   0x194 (PIN_OUTPUT_PULLUP | MUX_MODE0) /* 
mcasp0_fsx.mcasp0_fsx */
+   0x190 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
mcasp0_aclkx.mcasp0_aclkx */
+   0x06c (PIN_OUTPUT_PULLUP | MUX_MODE7) /* 
gpmc_a11.gpio1_27 */
+   ;
+   };
  };

  lcdc {
status = okay;
  };

+mcasp0{
+   pinctrl-names = default;
+   pinctrl-0 = mcasp0_pins;
+   status = okay;
+   op-mode = 0;/* MCASP_IIS_MODE */
+   tdm-slots = 2;
+   serial-dir =/* 0: INACTIVE, 1: TX, 2: RX */
+   0 0 1 0
+   ;
+   tx-num-evt = 1;
+   rx-num-evt = 1;
+};
+
  / {
hdmi {
compatible = ti,tilcdc,slave;
@@ -75,4 +98,33 @@
pinctrl-1 = nxp_hdmi_bonelt_off_pins;
status = okay;
};
+
+   clk_mcasp0_fixed: clk_mcasp0_fixed {
+   #clock-cells = 0;
+   compatible = fixed-clock;
+   clock-frequency = 24576000;
+   };
+
+   clk_mcasp0: clk_mcasp0 {
+   #clock-cells = 0;
+   compatible = gpio-clock;
+   clocks = clk_mcasp0_fixed;
+   enable-gpios = gpio1 27 GPIO_ACTIVE_HIGH; /* BeagleBone 
Black Clk enable on GPIO1_27 */
+   };
+
+   hdmi_audio: hdmi_audio@0 {
+  compatible = linux,hdmi-audio;
+  status = okay;
+   };
+
+   sound {
+   compatible = ti,am33xx-beaglebone-black;
+   ti,model = TI BeagleBone Black;
+   ti,audio-codec = hdmi_audio;
+   ti,mcasp-controller = mcasp0;
+   ti,audio-routing =
+   HDMI Out,   TX;
+   clocks = clk_mcasp0;
+   clock-names = ti,codec-clock;
+   };
  };




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 00/14] DTS: ARM: OMAP3-N900: Add misc. HW

2013-10-23 Thread Benoit Cousson

Hi Sebastian,

On 23/10/2013 00:49, Sebastian Reichel wrote:

This patchset adds misc. hardware elements to the Nokia N900 DTS
file. Apart from the last two patches the kernel drivers in 3.12
are already capable of handling the DT entries.

The series is based on bcousson/linux-omap-dt.git:for_3.13/dts.


Thanks, I've just applied the whole series.

Regards,
Benoit

--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 1/2] leds: lp55xx: handle enable pin in driver

2013-10-23 Thread Benoit Cousson

On 23/10/2013 10:19, Tony Lindgren wrote:

* Bryan Wu coolo...@gmail.com [131022 10:47]:

On Tue, Oct 22, 2013 at 10:37 AM, Tony Lindgren t...@atomide.com wrote:

* Bryan Wu coolo...@gmail.com [131022 10:23]:

On Tue, Oct 22, 2013 at 10:06 AM, Tony Lindgren t...@atomide.com wrote:

* Sebastian Reichel s...@debian.org [131022 06:02]:

This patch moves the handling of the chip's enable pin from the board
code into the driver. It also updates all board-code files using the
driver to incorporate this change.

This is needed for device tree support of the enable pin.


This seems safe to merge along with the other LED patches, the
changes to arch/arm/mach-omap2 should not conflict with anything.

So for the arch/arm/mach-omap2 changes:

Acked-by: Tony Lindgren t...@atomide.com


I'm OK for LED parts, will this patch go through omap tree? If so,
please add my ack.

Acked-by: Bryan Wu coolo...@gmail.com


It's probably best that you take it via with the LED patches.



OK, I will do it. what about PATCH 2 of this patch set? Will you take
care of it?


Benoit should take that one, otherwise there's a good chance of
pointless merge conflicts with the .dts files.


I've just merged it.

Regards,
Benoit

--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 0/2] ARM: dts: omap5-uevm: Audio related fixes

2013-10-23 Thread Benoit Cousson

Hi Peter,

On 23/10/2013 11:32, Peter Ujfalusi wrote:

Hi,

When the omap5-evm.dts file has been renamed to omap5-uevm.dts and the sEVM
support got deprecated in favor of uEVM (or Panda5) the content was not
validated.
The reset GPIO is different on uEVM compared to sEVM and uEVM does not have
support for dmic.

Regards,
Peter


I've just applied your series, let's try to push that for 3.13.

Thanks,
Benoit



---
Peter Ujfalusi (2):
   ARM: dts: omap5-uevm: Correct twl6040 reset GPIO pinmux
   ARM: dts: omap5-uevm: Remove pinmux for dmic pins

  arch/arm/boot/dts/omap5-uevm.dts | 12 +---
  1 file changed, 1 insertion(+), 11 deletions(-)




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[GIT PULL] ARM: OMAP: Some more more Device Tree for 3.13

2013-10-23 Thread Benoit Cousson
Hi Tony,

Please pull the branch for even more OMAP Device Tree for v3.13 or later.

Thanks,
Benoit


The following changes since commit 6a96867844895008558810853c7838af39dd317c:

  ARM: dts: AM33xx+: Add i2c aliases (2013-10-22 11:05:42 +0200)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/bcousson/linux-omap-dt.git 
tags/for_3.13_super_late/dts_signed

for you to fetch changes up to b306e7b819edd0515e18f5ca7e0d1cb4b0e4e58a:

  ARM: dts: omap5-uevm: Remove pinmux for dmic pins (2013-10-23 11:40:47 +0200)


Add a lot of N900 nodes
Add OPP table to OMAP5/DRA7
Add support for Newflow NanoBone board


Eric Witcher (1):
  ARM: dts: omap5-uevm: fix mcspi node pin descriptions

J Keerthy (3):
  ARM: dts: dra7-evm: add smps123 supply for CPU
  ARM: dts: OMAP5: Add CPU OPP table
  ARM: dts: DRA7: Add CPU OPP table

Mark Jackson (1):
  ARM: dts: Add support for Newflow NanoBone board

Markus Pargmann (1):
  ARM: dts: am33xx, change usb ctrl module label

Nishanth Menon (1):
  ARM: dts: omap5-uevm: add smps123 supply for CPU

Peter Ujfalusi (2):
  ARM: dts: omap5-uevm: Correct twl6040 reset GPIO pinmux
  ARM: dts: omap5-uevm: Remove pinmux for dmic pins

Sebastian Reichel (14):
  ARM: dts: omap3-n900: Add pinctrl for i2c devices
  ARM: dts: omap3-n900: Fix i2c bus speed
  ARM: dts: omap3-n900: Add UART support
  ARM: dts: omap3-n900: Add support for SD cards
  ARM: dts: omap3-n900: GPIO key definitions
  ARM: dts: omap3-n900: Add vibrator device
  ARM: dts: omap3-n900: Add LP5523 support
  ARM: dts: TWL4030: Add missing regulators
  ARM: dts: omap3-n900: Specify regulator info
  ARM: dts: omap3-n900: Add NAND support
  ARM: dts: omap3-n900:: Mux RX51_LCD_RESET_GPIO in DTS
  ARM: dts: omap3-n900: Add TLV320AIC3X support
  ARM: dts: omap3-n900: Add LP5523 support
  ARM: dts: TWL4030: Add power button support

 MAINTAINERS   |   6 +
 arch/arm/boot/dts/Makefile|   1 +
 arch/arm/boot/dts/am335x-nano.dts | 431 ++
 arch/arm/boot/dts/am33xx.dtsi |   6 +-
 arch/arm/boot/dts/dra7-evm.dts|   4 +
 arch/arm/boot/dts/dra7.dtsi   |   8 +-
 arch/arm/boot/dts/omap3-n900.dts  | 396 +-
 arch/arm/boot/dts/omap5-uevm.dts  |  34 ++-
 arch/arm/boot/dts/omap5.dtsi  |   9 +-
 arch/arm/boot/dts/twl4030.dtsi|  49 -
 10 files changed, 912 insertions(+), 32 deletions(-)
 create mode 100644 arch/arm/boot/dts/am335x-nano.dts
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] ARM: dts: am4372: Add McASP nodes

2013-10-22 Thread Benoit Cousson

On 22/10/2013 09:46, Peter Ujfalusi wrote:

Hi,

On 10/21/2013 10:01 PM, Sergei Shtylyov wrote:


diff --git a/arch/arm/boot/dts/am4372.dtsi b/arch/arm/boot/dts/am4372.dtsi
index c328d5c..defaad1 100644
--- a/arch/arm/boot/dts/am4372.dtsi
+++ b/arch/arm/boot/dts/am4372.dtsi
@@ -633,5 +633,32 @@
   dma-names = tx, rx;
   };

+mcasp0: mcasp@48038000 {


According to ePAPR spec [1], the name of a node should be somewhat
generic, reflecting the function of the device and not its
precise programming model. In this case probably sound?


We use the 'sound' node name for the sound card itself. The case with McASP is
a bit complicated. It can operate in I2S mode (and similar protocols like RJM,
LJM, TDM) or it can interface with S/PDIF, IEC60958-1, AES-3 codecs.
The mode we put McASP depends on the external components, so the same McASP
can be used in I2S mode in one board while on the other it can be S/PDIF.
It would have been convenient if I could use 'i2s' as node name but it is not
true for McASP (Tegra, Exynos for example have I2S, AC97, S/PDIF as separate 
IP).

IMHO the 'mcasp' is still the best node name for this IP. McASP stands for:
'Multichannel Audio Serial Port' and this is pretty much what McASP is.


Yes, I do agree, there are tons of nodes that cannot have generic name. 
Moreover, we are already using that name in few OMAP dts, so for 
consistency, let's keep that name.


Benoit

--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] ARM: dts: igep0033: Add mmc1 node for SDCARD support.

2013-10-22 Thread Benoit Cousson

Hi Enric,

On 19/10/2013 22:55, Enric Balletbo i Serra wrote:

Add mmc1 dt node to IGEP COM AQUILA board.


I've just applied it.

Please note that since we are already at -rc6 and since all the 
maintainers are actually visiting Edinburgh for KS and ELCE, I doubt all 
the latest patches will reach 3.13 :-(


Thanks,
Benoit



Signed-off-by: Enric Balletbo i Serra eballe...@gmail.com
---
  arch/arm/boot/dts/am335x-igep0033.dtsi | 13 +
  1 file changed, 13 insertions(+)

diff --git a/arch/arm/boot/dts/am335x-igep0033.dtsi 
b/arch/arm/boot/dts/am335x-igep0033.dtsi
index 06eba07..6196244 100644
--- a/arch/arm/boot/dts/am335x-igep0033.dtsi
+++ b/arch/arm/boot/dts/am335x-igep0033.dtsi
@@ -44,6 +44,13 @@
regulator-max-microvolt = 500;
regulator-boot-on;
};
+
+   vmmc: fixedregulator@0 {
+   compatible = regulator-fixed;
+   regulator-name = vmmc;
+   regulator-min-microvolt = 330;
+   regulator-max-microvolt = 330;
+   };
  };

  am33xx_pinmux {
@@ -180,6 +187,12 @@
};
  };

+mmc1 {
+   status = okay;
+   vmmc-supply = vmmc;
+   bus-width = 4;
+};
+
  uart0 {
status = okay;
pinctrl-names = default;




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[GIT PULL] ARM: OMAP: Some more Device Tree for 3.13

2013-10-22 Thread Benoit Cousson
Hi Tony,

Please pull the branch for few more OMAP Device Tree for v3.13 or later.

Thanks,
Benoit


The following changes since commit 6cf02dbb4b71f1c0c9acec89ae2df3b2318135f4:

  ARM: dts: dra7-evm: Add mmc2 node for eMMC support (2013-10-11 21:15:02 +0200)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/bcousson/linux-omap-dt.git 
tags/for_3.13_late/dts_signed

for you to fetch changes up to 6a96867844895008558810853c7838af39dd317c:

  ARM: dts: AM33xx+: Add i2c aliases (2013-10-22 11:05:42 +0200)


Add i2c aliases
Add McASP and audio support
Add reset/idle on init bindings for OMAP
Add more nodes for AM4272


Darren Etheridge (1):
  ARM: dts: am335x-evm: Add audio support for am335x-evm.dts

Enric Balletbo i Serra (1):
  ARM: dts: igep0033: Add mmc1 node for SDCARD support.

George Cherian (1):
  ARM: dts: OMAP5: Add dr_mode for dwc3

Jyri Sarha (1):
  ARM: dts: AM33XX: mcasp: Add location for data port registers to 
reg-property

Kishon Vijay Abraham I (1):
  ARM: dts: omap5-uevm: remove always_on, boot_on from smps10_out1

Lokesh Vutla (1):
  ARM: dts: AM4372: Add L2, EDMA, mailbox, MMC and SHAM nodes

Mugunthan V N (1):
  ARM: dts: AM4372: Update Support for EPOS EVM

Nishanth Menon (3):
  ARM: dts: omap4-panda-es: Do not reset gpio1
  ARM: dts: OMAP3+: Add i2c aliases
  ARM: dts: AM33xx+: Add i2c aliases

Pantelis Antoniou (1):
  ARM: dts: AM33XX: Add mcasp0 and mcasp1 device tree entries

Peter Ujfalusi (2):
  ARM: dts: am335x-evmsk: Audio support
  ARM: dts: AM4372: Add McASP nodes

Rajendra Nayak (2):
  ARM: dts: omap: Add reset/idle on init bindings for OMAP
  ARM: dts: am335x-evmsk: Do not reset gpio0

Roger Quadros (2):
  ARM: dts: omap3: Adapt USB OTG to generic PHY framework
  ARM: dts: omap3-beagle: Adapt USB OTG to generic PHY framework

Sricharan R (1):
  ARM: dts: OMAP5: Remove clock-frequency field for cpu timers

 .../devicetree/bindings/arm/omap/omap.txt  |   3 +-
 arch/arm/boot/dts/am335x-evm.dts   |  50 +
 arch/arm/boot/dts/am335x-evmsk.dts |  52 +
 arch/arm/boot/dts/am335x-igep0033.dtsi |  13 ++
 arch/arm/boot/dts/am33xx.dtsi  |  33 +++
 arch/arm/boot/dts/am4372.dtsi  | 240 -
 arch/arm/boot/dts/am43x-epos-evm.dts   | 168 +++
 arch/arm/boot/dts/dra7.dtsi|   5 +
 arch/arm/boot/dts/omap3-beagle.dts |   2 +
 arch/arm/boot/dts/omap3-gta04.dts  |   2 +
 arch/arm/boot/dts/omap3-n900.dts   |   2 +
 arch/arm/boot/dts/omap3.dtsi   |   3 +
 arch/arm/boot/dts/omap4-panda-es.dts   |   4 +
 arch/arm/boot/dts/omap4.dtsi   |   7 +
 arch/arm/boot/dts/omap5-uevm.dts   |   2 -
 arch/arm/boot/dts/omap5.dtsi   |   9 +-
 include/dt-bindings/pinctrl/am43xx.h   |  31 +++
 17 files changed, 621 insertions(+), 5 deletions(-)
 create mode 100644 include/dt-bindings/pinctrl/am43xx.h
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [RFCv3 7/7] ARM: dts: N900: Add SSI information

2013-10-22 Thread Benoit Cousson

Hi Sebastian,

Thanks to Tony, I've just realized that I missed all your patches, that 
for some reason ended-up in my junk folder :-(


That being said, I cannot apply any of your DTS patches! What base 
branch are you using?


Could you repost all your pending DTS patches in one series rebased on 
top of my for_3.13/dts?


Thanks,
Benoit

On 06/10/2013 22:27, Sebastian Reichel wrote:

Add SSI device tree data for OMAP3 and Nokia N900.

Signed-off-by: Sebastian Reichel s...@debian.org
---
  arch/arm/boot/dts/omap3-n900.dts | 12 ++
  arch/arm/boot/dts/omap3.dtsi | 47 
  2 files changed, 59 insertions(+)

diff --git a/arch/arm/boot/dts/omap3-n900.dts b/arch/arm/boot/dts/omap3-n900.dts
index 0582356..0fbb77e 100644
--- a/arch/arm/boot/dts/omap3-n900.dts
+++ b/arch/arm/boot/dts/omap3-n900.dts
@@ -186,6 +186,18 @@
power = 50;
  };

+ssi_port1 {
+   ti,ssi-cawake-gpio = gpio5 23 GPIO_ACTIVE_HIGH; /* 151 */
+
+   ssi-char {
+   compatible = ssi-char;
+   };
+};
+
+ssi_port2 {
+   status = disabled;
+};
+
  uart1 {
pinctrl-names = default;
pinctrl-0 = uart1_pins;
diff --git a/arch/arm/boot/dts/omap3.dtsi b/arch/arm/boot/dts/omap3.dtsi
index 7d95cda..9f60b82 100644
--- a/arch/arm/boot/dts/omap3.dtsi
+++ b/arch/arm/boot/dts/omap3.dtsi
@@ -532,5 +532,52 @@
num-eps = 16;
ram-bits = 12;
};
+
+   ssi: ssi-controller@48058000 {
+   compatible = ti,omap3-ssi;
+   ti,hwmods = ssi;
+
+   reg = 0x48058000 0x1000,
+ 0x48059000 0x1000;
+   reg-names = sys,
+   gdd;
+
+   interrupts = 71;
+   interrupt-names = gdd_mpu;
+
+   #address-cells = 1;
+   #size-cells = 1;
+   ranges;
+
+   ssi_port1: ssi-port@0 {
+   compatible = ti,omap3-ssi-port;
+
+   reg = 0x4805a000 0x800,
+ 0x4805a800 0x800;
+   reg-names = tx,
+   rx;
+
+   interrupt-parent = intc;
+   interrupts = 67,
+68;
+   interrupt-names = mpu_irq0,
+ mpu_irq1;
+   };
+
+   ssi_port2: ssi-port@1 {
+   compatible = ti,omap3-ssi-port;
+
+   reg = 0x4805b000 0x800,
+ 0x4805b800 0x800;
+   reg-names = tx,
+   rx;
+
+   interrupt-parent = intc;
+   interrupts = 69,
+70;
+   interrupt-names = mpu_irq0,
+ mpu_irq1;
+   };
+   };
};
  };




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v3] Add support for Newflow NanoBone board

2013-10-22 Thread Benoit Cousson

Hi Mark,

On 04/10/2013 10:15, Mark Jackson wrote:

NanoBone Specification:
---
CPU:
   TI AM335x

Memory:
   256MB DDR3
   128MB NOR flash
   128KB FRAM

Ethernet:
   2 x 10/100 connected to SMSC LAN8710 PHY

USB:
   1 x USB2.0 Type A

I2C:
   2Kbit EEPROM (Microchip 24AA02)
   RTC (Maxim DS1338)
   GPIO Expander (Microchip MCP23017)

Expansion connector:
   6 x UART
   1 x MMC/SD
   1 x USB2.0

Signed-off-by: Mark Jackson m...@newflow.co.uk
Reviewed-by: Javier Martinez Canillas javier.marti...@collabora.co.uk


Thanks I've just applied it.

Regards,
Benoit


---
Changes in v3:
- Added MMC support
- Fixed regulator limits

Changes in v2:
- Reworked to use existing device nodes as suggested by Javier

  MAINTAINERS   |6 +
  arch/arm/boot/dts/Makefile|1 +
  arch/arm/boot/dts/am335x-nano.dts |  431 +
  3 files changed, 438 insertions(+)
  create mode 100644 arch/arm/boot/dts/am335x-nano.dts

diff --git a/MAINTAINERS b/MAINTAINERS
index e61c2e8..8a4c9d9 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -6062,6 +6062,12 @@ L:   linux-omap@vger.kernel.org
  S:Maintained
  F:drivers/gpio/gpio-omap.c

+OMAP/NEWFLOW NANOBONE MACHINE SUPPORT
+M: Mark Jackson m...@newflow.co.uk
+L: linux-omap@vger.kernel.org
+S: Maintained
+F: arch/arm/boot/dts/am335x-nano.dts
+
  OMFS FILESYSTEM
  M:Bob Copeland m...@bobcopeland.com
  L:linux-karma-de...@lists.sourceforge.net
diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index e95af3f..543e837 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -184,6 +184,7 @@ dtb-$(CONFIG_ARCH_OMAP2PLUS) += omap2420-h4.dtb \
am335x-evmsk.dtb \
am335x-bone.dtb \
am335x-boneblack.dtb \
+   am335x-nano.dtb \
am3517-evm.dtb \
am3517_mt_ventoux.dtb \
am43x-epos-evm.dtb
diff --git a/arch/arm/boot/dts/am335x-nano.dts 
b/arch/arm/boot/dts/am335x-nano.dts
new file mode 100644
index 000..9907b49
--- /dev/null
+++ b/arch/arm/boot/dts/am335x-nano.dts
@@ -0,0 +1,431 @@
+/*
+ * Copyright (C) 2013 Newflow Ltd - http://www.newflow.co.uk/
+ *
+ * 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.
+ */
+/dts-v1/;
+
+#include am33xx.dtsi
+
+/ {
+   model = Newflow AM335x NanoBone;
+   compatible = ti,am33xx;
+
+   cpus {
+   cpu@0 {
+   cpu0-supply = dcdc2_reg;
+   };
+   };
+
+   memory {
+   device_type = memory;
+   reg = 0x8000 0x1000; /* 256 MB */
+   };
+
+   leds {
+   compatible = gpio-leds;
+
+   led@0 {
+   label = nanobone:green:usr1;
+   gpios = gpio1 5 0;
+   default-state = off;
+   };
+   };
+};
+
+am33xx_pinmux {
+   pinctrl-names = default;
+   pinctrl-0 = misc_pins;
+
+   misc_pins: misc_pins {
+   pinctrl-single,pins = 
+   0x15c (PIN_OUTPUT | MUX_MODE7)  /* spi0_cs0.gpio0_5 */
+   ;
+   };
+
+   gpmc_pins: gpmc_pins {
+   pinctrl-single,pins = 
+   0x0 (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad0.gpmc_ad0 */
+   0x4 (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad1.gpmc_ad1 */
+   0x8 (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad2.gpmc_ad2 */
+   0xc (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad3.gpmc_ad3 */
+   0x10 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad4.gpmc_ad4 */
+   0x14 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad5.gpmc_ad5 */
+   0x18 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad6.gpmc_ad6 */
+   0x1c (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad7.gpmc_ad7 */
+   0x20 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad8.gpmc_ad8 */
+   0x24 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad9.gpmc_ad9 */
+   0x28 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad10.gpmc_ad10 */
+   0x2c (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad11.gpmc_ad11 */
+   0x30 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad12.gpmc_ad12 */
+   0x34 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad13.gpmc_ad13 */
+   0x38 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad14.gpmc_ad14 */
+   0x3c (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad15.gpmc_ad15 */
+
+   0x70 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_wait0.gpmc_wait0 */
+   0x7c (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_csn0.gpmc_csn0 */
+   0x80 

Re: [PATCH] ARM: dts: am33xx, change usb ctrl module label

2013-10-22 Thread Benoit Cousson

Hi Markus,

On 14/10/2013 14:49, Markus Pargmann wrote:

Control module is not usb specific. This patch changes the label to
usb_ctrl_mod.

Signed-off-by: Markus Pargmann m...@pengutronix.de


I've just applied it.

Thanks,
Benoit


---
  arch/arm/boot/dts/am33xx.dtsi | 6 +++---
  1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/arch/arm/boot/dts/am33xx.dtsi b/arch/arm/boot/dts/am33xx.dtsi
index f9c5da9..14510ee 100644
--- a/arch/arm/boot/dts/am33xx.dtsi
+++ b/arch/arm/boot/dts/am33xx.dtsi
@@ -346,7 +346,7 @@
ti,hwmods = usb_otg_hs;
status = disabled;

-   ctrl_mod: control@44e1 {
+   usb_ctrl_mod: control@44e1 {
compatible = ti,am335x-usb-ctrl-module;
reg = 0x44e10620 0x10
0x44e10648 0x4;
@@ -359,7 +359,7 @@
reg = 0x47401300 0x100;
reg-names = phy;
status = disabled;
-   ti,ctrl_mod = ctrl_mod;
+   ti,ctrl_mod = usb_ctrl_mod;
};

usb0: usb@47401000 {
@@ -407,7 +407,7 @@
reg = 0x47401b00 0x100;
reg-names = phy;
status = disabled;
-   ti,ctrl_mod = ctrl_mod;
+   ti,ctrl_mod = usb_ctrl_mod;
};

usb1: usb@47401800 {




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] ARM: dts: omap5-uevm: fix mcspi node pin descriptions

2013-10-22 Thread Benoit Cousson

Hi Eric,

On 18/10/2013 08:42, Eric Witcher wrote:

Correct mcspi pin descriptions to match corresponding node name and
add chip select number to be consistent with OMAP5 TRM.

Signed-off-by: Eric Witcher ewitc...@mindspring.com


Applied on my tree.

Thanks,
Benoit


---
  arch/arm/boot/dts/omap5-uevm.dts | 18 +-
  1 file changed, 9 insertions(+), 9 deletions(-)

diff --git a/arch/arm/boot/dts/omap5-uevm.dts b/arch/arm/boot/dts/omap5-uevm.dts
index d784b3a..90c7843 100644
--- a/arch/arm/boot/dts/omap5-uevm.dts
+++ b/arch/arm/boot/dts/omap5-uevm.dts
@@ -131,25 +131,25 @@
0xbc (PIN_INPUT | MUX_MODE0)/*  mcspi2_clk 
*/
0xbe (PIN_INPUT | MUX_MODE0)/*  mcspi2_simo 
*/
0xc0 (PIN_INPUT_PULLUP | MUX_MODE0) /*  mcspi2_somi 
*/
-   0xc2 (PIN_OUTPUT | MUX_MODE0)   /*  mcspi2_cs */
+   0xc2 (PIN_OUTPUT | MUX_MODE0)   /*  mcspi2_cs0 
*/
;
};

mcspi3_pins: pinmux_mcspi3_pins {
pinctrl-single,pins = 
-   0x78 (PIN_INPUT | MUX_MODE1)/*  mcspi2_somi 
*/
-   0x7a (PIN_INPUT | MUX_MODE1)/*  mcspi2_cs */
-   0x7c (PIN_INPUT | MUX_MODE1)/*  mcspi2_simo 
*/
-   0x7e (PIN_INPUT | MUX_MODE1)/*  mcspi2_clk 
*/
+   0x78 (PIN_INPUT | MUX_MODE1)/*  mcspi3_somi 
*/
+   0x7a (PIN_INPUT | MUX_MODE1)/*  mcspi3_cs0 
*/
+   0x7c (PIN_INPUT | MUX_MODE1)/*  mcspi3_simo 
*/
+   0x7e (PIN_INPUT | MUX_MODE1)/*  mcspi3_clk 
*/
;
};

mcspi4_pins: pinmux_mcspi4_pins {
pinctrl-single,pins = 
-   0x164 (PIN_INPUT | MUX_MODE1)   /*  mcspi2_clk 
*/
-   0x168 (PIN_INPUT | MUX_MODE1)   /*  mcspi2_simo 
*/
-   0x16a (PIN_INPUT | MUX_MODE1)   /*  mcspi2_somi 
*/
-   0x16c (PIN_INPUT | MUX_MODE1)   /*  mcspi2_cs */
+   0x164 (PIN_INPUT | MUX_MODE1)   /*  mcspi4_clk 
*/
+   0x168 (PIN_INPUT | MUX_MODE1)   /*  mcspi4_simo 
*/
+   0x16a (PIN_INPUT | MUX_MODE1)   /*  mcspi4_somi 
*/
+   0x16c (PIN_INPUT | MUX_MODE1)   /*  mcspi4_cs0 
*/
;
};





--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [RFCv3 7/7] ARM: dts: N900: Add SSI information

2013-10-22 Thread Benoit Cousson

Hi Sebastian,

On 22/10/2013 16:44, Sebastian Reichel wrote:

Hi Benoit,

On Tue, Oct 22, 2013 at 02:48:45PM +0200, Benoit Cousson wrote:

Thanks to Tony, I've just realized that I missed all your patches,
that for some reason ended-up in my junk folder :-(


oh :( Can you check why they ended up in junk? I would like to
prevent more mails going there.


That being said, I cannot apply any of your DTS patches! What base
branch are you using?


Currently torvalds/master with pavel's n900 patch and some more
patches from me.


Mmm, looks like I missed these patches :-)




Could you repost all your pending DTS patches in one series rebased
on top of my for_3.13/dts?


Sure. DT maintainers haven't given feedback since the last patchset
[0]. Do you want to wait for feedback from them?


OK, maybe not the SSI series that is still RFC, but I guess all the 
others ones are fine to be merged.


Could you repost the whole N900 DTS patches (beside SSI) in one series 
rebased on top of mine?


Thanks,
Benoit



[0] https://lkml.org/lkml/2013/9/23/529

-- Sebastian




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH V7 0/8] ARM: OMAP3+: support cpufreq-cpu0 for device tree boot

2013-10-22 Thread Benoit Cousson

Hi Nishanth,

On 16/10/2013 17:39, Nishanth Menon wrote:

Hi,

This series enables the use of cpufreq-cpu0 generic driver for all
OMAP and related derivatives. Only patch#8 in the series, which
introduces CPU clock nodes, depends on Tero's V8 patch series for clock
nodes[1]

I will stop copy pasting the series complete history and point at [2].

Main changes since V6[3]:
- squashed patches for a minimal set
- i have organized the series such that 1 to 7 can immediately be merged
   if desired:
- patches 1,2,3 can go to Tony's omap-for-v3.13/quirk [4]
- patches 4-7 can go to Benoit's for_3.13/dts [5]


I've just applied them in my DTS tree.

Thanks,
Benoit


- patch 8 needs to depend on [1] and should eventually go to [5]

NOTES: obviously without clock nodes cpufreq will not function.

Test Script: http://pastebin.com/VvJPjsne

Test-log:
BeagleBoard-XM (OMAP36xx): http://pastebin.com/XZDNaHPf
PandaBoard-ES (OMAP4460): http://pastebin.com/qQCmA2ng
BeagleBone-Black(AM335x): http://pastebin.com/98FX4uYW
OMAP5uEVM (OMAP5432): http://pastebin.com/NXj3L636
DRA7-EVM (DRA7xx): http://pastebin.com/0kKT3TXy

J Keerthy (3):
   ARM: dts: dra7-evm: add smps123 supply for CPU
   ARM: dts: OMAP5: Add CPU OPP table
   ARM: dts: DRA7: Add CPU OPP table

Nishanth Menon (5):
   ARM: OMAP3+: do not register non-dt OPP tables for device tree boot
   ARM: OMAP2+: add missing lateinit hook for calling pm late init
   ARM: OMAP3+: use cpu0-cpufreq driver in device tree supported boot
   ARM: dts: omap5-uevm: add smps123 supply for CPU
   ARM: dts: OMAP3: add clock nodes for CPU

[1] http://marc.info/?t=13813328426r=1w=2
[2] http://marc.info/?l=linux-arm-kernelm=136804009618594w=2
[3] http://marc.info/?l=devicetreem=138135419203492w=2
[4] 
https://git.kernel.org/cgit/linux/kernel/git/tmlind/linux-omap.git/log/?h=omap-for-v3.13/quirk

  arch/arm/boot/dts/am33xx.dtsi   |4 
  arch/arm/boot/dts/dra7-evm.dts  |4 
  arch/arm/boot/dts/dra7.dtsi |   13 -
  arch/arm/boot/dts/omap3.dtsi|5 +
  arch/arm/boot/dts/omap4.dtsi|5 +
  arch/arm/boot/dts/omap5-uevm.dts|4 
  arch/arm/boot/dts/omap5.dtsi|   15 ++-
  arch/arm/mach-omap2/board-generic.c |4 
  arch/arm/mach-omap2/common.h|4 
  arch/arm/mach-omap2/io.c|   20 
  arch/arm/mach-omap2/opp.c   |4 
  arch/arm/mach-omap2/pm.c|   12 +---
  12 files changed, 89 insertions(+), 5 deletions(-)

Regards,
Nishanth Menon




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v5 DTS 0/4] Fix AM335x-evm analog audio support

2013-10-20 Thread Benoit Cousson

Hi Jyri,

On 20/10/2013 19:04, Jyri Sarha wrote:

Hi Benoit,
I rebased the DTS patches on top of
git://git.kernel.org/pub/scm/linux/kernel/git/bcousson/linux-omap-dt.git
for_3.13/dts -branch
and tested the result. Hope that was the right branch.


Yes, thanks for the update.

I've just applied the patches.

Regards,
Benoit



The DTS patches can also be pulled from:
git://git.ti.com/~jyrisarha/ti-linux-kernel/jyrisarhas-audio-video-linux-feature-tree.git
for_bcousson/for_3.13/dts -branch

The non DTS patches rebased on top of v3.12-rc5 can be pulled from here:
git://git.ti.com/~jyrisarha/ti-linux-kernel/jyrisarhas-audio-video-linux-feature-tree.git
v3.12-rc5-am33xx-audio-patch-v5-no-dts -branch

The the full patch series can be found here:
http://mailman.alsa-project.org/pipermail/alsa-devel/2013-October/067443.html

Best regards,
Jyri

Darren Etheridge (1):
   ARM/dts: am335x-evm: Add audio support for am335x-evm.dts

Jyri Sarha (1):
   ARM/dts: am33xx: mcasp: Add location for data port registers to
 reg-property

Pantelis Antoniou (1):
   ARM/dts: am33xx: Add mcasp0 and mcasp1 device tree entries

Peter Ujfalusi (1):
   ARM/dts: am335x-evmsk: Audio support

  arch/arm/boot/dts/am335x-evm.dts   |   50 
  arch/arm/boot/dts/am335x-evmsk.dts |   48 ++
  arch/arm/boot/dts/am33xx.dtsi  |   28 
  3 files changed, 126 insertions(+)




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 0/2] ARM: dts: AM4372: Add more nodes

2013-10-18 Thread Benoit Cousson

Hi Lokesh,

On 18/10/2013 05:49, Lokesh Vutla wrote:

Hi Benoit,
On Friday 11 October 2013 12:44 AM, Lokesh Vutla wrote:

This patch series add nodes for l2-cache-controller, EDMA, mailbox, mmc, sham,
and updates the properties for cpsw, i2c0, matrix-keypad.

These patches are applied on top of Benoit's for_3.13/dts branch
git://git.kernel.org/pub/scm/linux/kernel/git/bcousson/linux-omap-dt.git 
for_3.13/dts

Can you take this patch series for 3.13?


I've just applied it after a sloght change in the subject and in the SoB 
list.


ARM: dts: AM4372: Add L2, EDMA, mailbox, MMC and SHAM nodes

Populate nodes for l2-cache-controller, EDMA, mailbox,
mmc, sham.

Update as well DT properties for epwmss, aes, des.

Signed-off-by: Suman Anna s-a...@ti.com
Signed-off-by: Balaji T K balaj...@ti.com
Signed-off-by: Mugunthan V N mugunthan...@ti.com
Signed-off-by: Lokesh Vutla lokeshvu...@ti.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com


I added all the author you listed in a more formal way.

Regards,
Benoit



Thanks and regards,
Lokesh


Testing:
Tested EDMA, mmc, sham, aes, des, i2c0, cpsw, matric-keypad on AM4372 EPOS EVM
with the addition of following two series:
- Tero's V8 of OMAP DT clock conversion
   http://www.mail-archive.com/linux-omap@vger.kernel.org/msg96769.html
- Afzal's V5 of AM43x PRCM basic support
   http://www.mail-archive.com/linux-omap@vger.kernel.org/msg96275.html

Lokesh Vutla (1):
   ARM: dts: AM4372: Add more nodes

Mugunthan V N (1):
   ARM: dts: AM4372: Update Support for EPOS EVM

  arch/arm/boot/dts/am4372.dtsi|  210 +-
  arch/arm/boot/dts/am43x-epos-evm.dts |  168 +++
  include/dt-bindings/pinctrl/am43xx.h |   31 +
  3 files changed, 408 insertions(+), 1 deletion(-)
  create mode 100644 include/dt-bindings/pinctrl/am43xx.h






--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v3] ARM: dts: add minimal DT support for Nokia N950 N9 phones

2013-10-18 Thread Benoit Cousson

On 16/10/2013 02:35, Tony Lindgren wrote:

* Aaro Koskinen aaro.koski...@iki.fi [131015 13:36]:

Add minimal DT support for Nokia N950  N9 phones. The same functionality
that is provided by the current board file should work: serial console,
USB, OneNAND and MMC.

Signed-off-by: Aaro Koskinen aaro.koski...@iki.fi
Acked-by: Tony Lindgren t...@atomide.com


Oh this is not yet merged, I'll pick this one into the
omap-for-v3.13/board-removal as the board removal patch is
already there.


Just to be sure. Does that mean that you'll take care of that one, and 
thus I do not have to queue it?


Thanks,
Benoit


Regards,

Tony


---

v3: Added Tony's ACK  properties for generic USB PHY framework.

Previous version: http://marc.info/?t=138005105700010r=1w=2

  arch/arm/boot/dts/Makefile   |   2 +
  arch/arm/boot/dts/omap3-n9.dts   |  18 
  arch/arm/boot/dts/omap3-n950-n9.dtsi | 174 +++
  arch/arm/boot/dts/omap3-n950.dts |  18 
  4 files changed, 212 insertions(+)
  create mode 100644 arch/arm/boot/dts/omap3-n9.dts
  create mode 100644 arch/arm/boot/dts/omap3-n950-n9.dtsi
  create mode 100644 arch/arm/boot/dts/omap3-n950.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index 9df7d2c..62d0f4d 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -177,6 +177,8 @@ dtb-$(CONFIG_ARCH_OMAP2PLUS) += omap2420-h4.dtb \
omap3-gta04.dtb \
omap3-igep0020.dtb \
omap3-igep0030.dtb \
+   omap3-n9.dtb \
+   omap3-n950.dtb \
omap4-panda.dtb \
omap4-panda-a4.dtb \
omap4-panda-es.dtb \
diff --git a/arch/arm/boot/dts/omap3-n9.dts b/arch/arm/boot/dts/omap3-n9.dts
new file mode 100644
index 000..39828ce
--- /dev/null
+++ b/arch/arm/boot/dts/omap3-n9.dts
@@ -0,0 +1,18 @@
+/*
+ * omap3-n9.dts - Device Tree file for Nokia N9
+ *
+ * Written by: Aaro Koskinen aaro.koski...@iki.fi
+ *
+ * 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.
+ */
+
+/dts-v1/;
+
+#include omap3-n950-n9.dtsi
+
+/ {
+   model = Nokia N9;
+   compatible = nokia,omap3-n9, ti,omap3;
+};
diff --git a/arch/arm/boot/dts/omap3-n950-n9.dtsi 
b/arch/arm/boot/dts/omap3-n950-n9.dtsi
new file mode 100644
index 000..94eb77d
--- /dev/null
+++ b/arch/arm/boot/dts/omap3-n950-n9.dtsi
@@ -0,0 +1,174 @@
+/*
+ * omap3-n950-n9.dtsi - Device Tree file for Nokia N950  N9 (common stuff)
+ *
+ * Written by: Aaro Koskinen aaro.koski...@iki.fi
+ *
+ * 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.
+ */
+
+#include omap36xx.dtsi
+
+/ {
+   cpus {
+   cpu@0 {
+   cpu0-supply = vcc;
+   };
+   };
+
+   memory {
+   device_type = memory;
+   reg = 0x8000 0x4000; /* 1 GB */
+   };
+
+   vemmc: fixedregulator@0 {
+   compatible = regulator-fixed;
+   regulator-name = VEMMC;
+   regulator-min-microvolt = 290;
+   regulator-max-microvolt = 290;
+   gpio = gpio5 29 0; /* gpio line 157 */
+   startup-delay-us = 150;
+   enable-active-high;
+   };
+};
+
+omap3_pmx_core {
+   mmc2_pins: pinmux_mmc2_pins {
+   pinctrl-single,pins = 
+   0x128 (PIN_INPUT_PULLUP | MUX_MODE0) /* sdmmc2_clk */
+   0x12a (PIN_INPUT_PULLUP | MUX_MODE0) /* sdmmc2_cmd */
+   0x12c (PIN_INPUT_PULLUP | MUX_MODE0) /* sdmmc2_dat0 */
+   0x12e (PIN_INPUT_PULLUP | MUX_MODE0) /* sdmmc2_dat1 */
+   0x130 (PIN_INPUT_PULLUP | MUX_MODE0) /* sdmmc2_dat2 */
+   0x132 (PIN_INPUT_PULLUP | MUX_MODE0) /* sdmmc2_dat3 */
+   ;
+   };
+};
+
+i2c1 {
+   clock-frequency = 290;
+
+   twl: twl@48 {
+   reg = 0x48;
+   interrupts = 7; /* SYS_NIRQ cascaded to intc */
+   interrupt-parent = intc;
+   };
+};
+
+/include/ twl4030.dtsi
+
+twl {
+   compatible = ti,twl5031;
+};
+
+twl_gpio {
+   ti,pullups  = 0x01; /* BIT(0) */
+   ti,pulldowns= 0x008106; /* BIT(1) | BIT(2) | BIT(8) | BIT(15) */
+};
+
+i2c2 {
+   clock-frequency = 40;
+};
+
+i2c3 {
+   clock-frequency = 40;
+};
+
+mmc1 {
+   status = disabled;
+};
+
+mmc2 {
+   pinctrl-names = default;
+   pinctrl-0 = mmc2_pins;
+   vmmc-supply = vemmc;
+   bus-width = 4;
+   ti,non-removable;
+};
+
+mmc3 {
+   status = disabled;
+};
+
+usb_otg_hs {
+   interface-type = 0;
+   usb-phy = usb2_phy;
+   phys = usb2_phy;
+   phy-names = usb2-phy;
+   mode = 3;
+   power = 50;

Re: [PATCH] ARM: dts: omap3-beagle: Adapt USB OTG to generic PHY framework

2013-10-18 Thread Benoit Cousson

Hi Roger,

On 18/10/2013 14:00, Roger Quadros wrote:

Hi Benoit,

Could you please include this one for 3.13?
Without this OTG port will be broken for beagle. Thanks.



I've just applied it.

Thanks,
Benoit


cheers,
-roger

On 10/07/2013 01:46 PM, Roger Quadros wrote:

The generic PHY framewrok expects different properties than the
old USB PHY framework. Supply those properties.

Fixes USB OTG port on beagle after the Generic PHY framework was
merged in greg/usb-next. [1]

[1] - https://lkml.org/lkml/2013/9/27/581

Signed-off-by: Roger Quadros rog...@ti.com
---
  arch/arm/boot/dts/omap3-beagle.dts |2 ++
  1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-beagle.dts 
b/arch/arm/boot/dts/omap3-beagle.dts
index 7669c16..fa532aa 100644
--- a/arch/arm/boot/dts/omap3-beagle.dts
+++ b/arch/arm/boot/dts/omap3-beagle.dts
@@ -173,6 +173,8 @@
  usb_otg_hs {
interface-type = 0;
usb-phy = usb2_phy;
+   phys = usb2_phy;
+   phy-names = usb2-phy;
mode = 3;
power = 50;
  };






--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v5 00/12] Fix AM335x-evm analog audio support

2013-10-18 Thread Benoit Cousson

+ Tony

Hi Jyri,

The DTS part looks fine to me, but does not apply at all on my branch,

Could you rebase it and repost it without the driver part to avoid any 
issue during the driver merge?


Thanks,
Benoit

On 18/10/2013 17:37, Jyri Sarha wrote:


The v4 version of patches can be found here:
http://mailman.alsa-project.org/pipermail/alsa-devel/2013-October/067098.html
The v3 version of patches can be found here:
http://mailman.alsa-project.org/pipermail/alsa-devel/2013-September/066728.html
The v2 version of patches can be found here:
http://mailman.alsa-project.org/pipermail/alsa-devel/2013-September/066379.html
The RFC version of patches can been found here:
http://mailman.alsa-project.org/pipermail/alsa-devel/2013-September/066178.html

Changes since v4
- Rebased on top of Lunux 3.12-rc5
- Fix mcasp0 dat address in reg propery.
  - Comment: 
http://mailman.alsa-project.org/pipermail/alsa-devel/2013-October/067116.html
  - Changes:
- [PATCH v4 08/10] ARM/dts: am33xx: mcasp: Add location for data port 
registers to reg-property
- Fix number of serializers for am335x based boards
  - Comment: 
http://mailman.alsa-project.org/pipermail/alsa-devel/2013-October/067113.html
  - Changes:
- [PATCH v4 09/10] ARM/dts: am335x-evm: Add audio support for 
am335x-evm.dts
- [PATCH v4 10/10] ARM/dts: am335x-evmsk: Audio support
- Change davinci-mcasp compatible property model to a more accurate one
  - Add: [PATCH v5 05/12] arm: omap2plus_defconfig: enable AM33xx SOC EVM 
audio
  - Changes:
- [PATCH v4 07/10] ARM/dts: am33xx: Add mcasp0 and mcasp1 device tree 
entries
- Enable AM33xx SOC EVM audio in omap2plus_defconfig
  - Add: [PATCH v5 12/12] arm: omap2plus_defconfig: enable AM33xx SOC EVM 
audio
- The patch numbers 5-10 have been shifted to 6-11

Changes since v3
   - Rebased on top of v3.12-rc4
   - Drop already applied patches:
 - [PATCH v2 01/11] ASoC: davinci-evm: Move sysclk logic away from 
evm_hw_params
 - [PATCH v2 06/11] ASoC: davinci: Add support for AM33xx SoC Audio
 - [PATCH v2 07/11] ASoC: tlv320aic3x: Add regulators to DT bindings 
document
 - [PATCH v2 08/11] ASoC: tlv320aic3x: Add codec pins to DT bindings 
document
   - Add: ASoC: davinci: Fix AM33xx SoC Audio support
 - Contains the fixes from Peter:
   
http://mailman.alsa-project.org/pipermail/alsa-devel/2013-September/066448.html
 - Contents of this patch were squashed to [PATCH v3 06/11] ASoC:
   davinci: Add support for AM33xx SoC Audio, but since the patch v2 was
   already applied the changes are here as a separate patch.
   - Add: ASoC: davinci-mcasp: Remove redundant num-serializer DT parameter
   - Change: ASoC: davinci-mcasp: Add DMA register locations to DT
 to: ASoC: davinci-mcasp: Add location for data port registers to DT
 - Use more accurate name for data port register location
 - Improve commit message
   - Change: ASoC: davinci-mcasp: Interrupts property to optional and add 
interrupt-names
 to: ASoC: davinci-mcasp: Improve DT bindings document
 - Remove #address-cells and #size-cells
 - Bracket named interrupts tuples
 - Add missing for to serial-dir description
 - Improve tdm-slots description
 - Improve op-mode description
 - Add pinctrl-names and pinctrl-0 descriptions
   - Change: ARM/dts: am335x-evm: Add audio support for am335x-evm.dts
 - Use board specific name 'AM335x-EVM' for the soundcard.
 - Use the board specific tlv320aic3106 codec. Use this name instead of 
generic
   tlv320aic3x.
 - Remove num-serializer property from mcasp node
 - Remove blank lines
   - Change: ARM/dts: am33xx: Add mcasp0 and mcasp1 device tree entries
 - Bracket all named property tuples
   - Add: ARM/dts: am335x-evmsk: Audio support
   - The other patches in the set not mentioned here are identical to their
 earlier version

Changes since v2
   [PATCH v2 01/11] ASoC: davinci-evm: Move sysclk logic away from evm_hw_params
- no change
   [PATCH v2 02/11] ASoC: davinci-evm: Add device tree binding
- no change
   [PATCH v2 03/11] ASoC: davinci-mcasp: Add DMA register locations to DT
- no change
   [PATCH v2 04/11] ASoC: davinci-mcasp: Extract DMA channels directly from DT
- no change
   [PATCH v2 05/11] ASoC: davinci-mcasp: Remove interrupt property from DT 
bindin
- restore binding but make it optional and add interrupt-names property
   [PATCH v2 06/11] ASoC: davinci: Add support for AM33xx SoC Audio
- SND_DAVINCI_SOC help Machine driver for ... - Platform driver for ...
- SND_AM33XX_SOC_EVM depends on SND_DAVINCI_SOC  SOC_AM33XX
- SND_AM33XX_SOC_EVM does not selcet SND_DAVINCI_SOC
   [PATCH v2 07/11] ASoC: tlv320aic3x: Add regulators to DT bindings document
- no change
   [PATCH v2 08/11] ASoC: tlv320aic3x: Add codec pins to DT bindings document
- no change
   [PATCH v2 09/11] ARM/dts: am33xx: Add mcasp0 and mcasp1 

Re: [PATCH v2 2/2] ARM: dts: omap5: Add dr_mode for dwc3

2013-10-17 Thread Benoit Cousson

Hi Kishon,

On 16/10/2013 15:17, Kishon Vijay Abraham I wrote:

Benoit,

On Tuesday 15 October 2013 11:19 AM, Kishon Vijay Abraham I wrote:

From: George Cherian george.cher...@ti.com

Added dr_mode property in dwc3 and set its default mode to device.
Currently dwc3 driver doesn't have support for OTG mode. So explicitly
setting to peripheral even dwc3 is a OTG controller since OMAP5 has
already got an EHCI host.

Signed-off-by: George Cherian george.cher...@ti.com
Signed-off-by: Kishon Vijay Abraham I kis...@ti.com


Can you take this patch for 3.13?


I've just applied it.

Thanks,
Benoit


--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 1/2] ARM: dts: omap5-uevm: remove always_on, boot_on from smps10_out1

2013-10-17 Thread Benoit Cousson

Hi Kishon,

On 16/10/2013 15:27, Nishanth Menon wrote:

On 10/16/2013 08:17 AM, Kishon Vijay Abraham I wrote:

Benoit,

On Thursday 10 October 2013 04:19 PM, Kishon Vijay Abraham I wrote:

smps10 should be enabled only in the case of host mode. So stop
doing always_on, boot_on from smps10_out1. The driver will enable it in host
mode.


Can you take this patch too?


Acked-by: Nishanth Menon n...@ti.com


I've just applied it.

Thanks,
Benoit


--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [RESEND PATCH V2 1/2] ARM: dts: AM33xx: Add RNG node

2013-10-15 Thread Benoit Cousson

Hi Lokesh,

On 12/10/2013 15:26, Lokesh Vutla wrote:

Hi Benoit,
On Thursday 29 August 2013 06:22 PM, Lokesh Vutla wrote:

Add the AM33xx RNG module's device tree data.
Also add Documentation file describing the data
for the RNG module.

Seems you missed this patch. Please consider this for this merge window.


Indeed I missed it. Sorry :-(


Patch 2/2 is already taken by Paul.
Without this patch AM335x boot will crash as I mentioned in my cover letter.

Thanks and regards,
Lokesh


Signed-off-by: Lokesh Vutla lokeshvu...@ti.com
---
Changes since V1:
- Drop status=disabled entry in dt node, Since
   RNG is present on all AM33xx platforms.

  .../devicetree/bindings/hwrng/omap_rng.txt |   22 
  arch/arm/boot/dts/am33xx.dtsi  |7 +++
  2 files changed, 29 insertions(+)
  create mode 100644 Documentation/devicetree/bindings/hwrng/omap_rng.txt


I do not see the acked-by for the binding part. You do need that for any 
new bindings nowadays.




diff --git a/Documentation/devicetree/bindings/hwrng/omap_rng.txt 
b/Documentation/devicetree/bindings/hwrng/omap_rng.txt
new file mode 100644
index 000..6a62acd
--- /dev/null
+++ b/Documentation/devicetree/bindings/hwrng/omap_rng.txt
@@ -0,0 +1,22 @@
+OMAP SoC HWRNG Module
+
+Required properties:
+
+- compatible : Should contain entries for this and backward compatible
+  RNG versions:
+  - ti,omap2-rng for OMAP2.
+  - ti,omap4-rng for OMAP4, OMAP5 and AM33XX.
+  Note that these two versions are incompatible.
+- ti,hwmods: Name of the hwmod associated with the RNG module
+- reg : Offset and length of the register set for the module
+- interrupts : the interrupt number for the RNG module.
+   Only used for ti,omap4-rng.
+
+Example:
+/* AM335x */
+rng: rng@4831 {
+   compatible = ti,omap4-rng;
+   ti,hwmods = rng;
+   reg = 0x4831 0x2000;
+   interrupts = 111;
+};
diff --git a/arch/arm/boot/dts/am33xx.dtsi b/arch/arm/boot/dts/am33xx.dtsi
index 38b446b..26ebe30 100644
--- a/arch/arm/boot/dts/am33xx.dtsi
+++ b/arch/arm/boot/dts/am33xx.dtsi
@@ -530,5 +530,12 @@
#size-cells = 1;
status = disabled;
};
+
+   rng: rng@4831 {
+   compatible = ti,omap4-rng;
+   ti,hwmods = rng;
+   reg = 0x4831 0x2000;
+   interrupts = 111;
+   };
};
  };





It looks good to me, but it does not apply on my branch.
Please rebase it and repost with the proper acked-by.

Thanks,
Benoit


--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 1/1] ARM: dts: omap3: Adapt USB OTG to generic PHY framework

2013-10-15 Thread Benoit Cousson

Hi Roger,

On 14/10/2013 11:20, Roger Quadros wrote:

Hi Benoit,

On 10/10/2013 06:34 PM, Felipe Balbi wrote:

On Mon, Oct 07, 2013 at 04:28:13PM +0300, Roger Quadros wrote:

The generic PHY framewrok expects different properties than the
old USB PHY framework. Supply those properties.

Fixes USB OTG port on GAT04 and N900 after the Generic PHY framework was
merged in greg/usb-next. [1]

[1] - https://lkml.org/lkml/2013/9/27/581

Signed-off-by: Roger Quadros rog...@ti.com


Acked-by: Felipe Balbi ba...@ti.com



Could you please pick this one for 3.13? Thanks.

I don't see it in your 3.13 take 2 pull request.


It was not in it. I've just applied it.

Thanks
Benoit

--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v2 2/5] ARM: dts: omap: Add new bindings for OMAP

2013-10-15 Thread Benoit Cousson

Hi Rajendra,

On 09/10/2013 18:45, Benoit Cousson wrote:

+ A couple of DT maintainers

On 09/10/2013 18:41, Rajendra Nayak wrote:

On Wednesday 09 October 2013 08:43 PM, Benoit Cousson wrote:

Hi Rajendra,

On 09/10/2013 12:11, Rajendra Nayak wrote:

On OMAP we have co-processor IPs, memory controllers,
GPIOs which control regulators and power switches to
PMIC, and SoC internal Bus IPs, some or most of which
should either not be reset or idled or both at init.
(In some cases there are erratas which prevent an IP
from being reset)
Have a way to pass this information from DT.


Did you get some acked-by from the DT maintainers?
Every new bindings must be carefully reviewed now.


Nope, I haven't. The patches are on the list for a couple
of months now.


Let's see if Mark and Rob are OK with that.


OK, I've just applied it after a small change in the subject:

 ARM: dts: omap: Add reset/idle on init bindings for OMAP

Is that OK for you?

Thanks,
Benoit



Thanks,
Benoit





Regards,
Benoit



Update the am33xx/omap4 and omap5 dtsi files with the
new bindings for modules which either should not be
idled. reset or both. A later patch would cleanup the
same information that exists today as part of the hwmod
data files.

Signed-off-by: Rajendra Nayak rna...@ti.com
---
   .../devicetree/bindings/arm/omap/omap.txt  |3 ++-
   arch/arm/boot/dts/am33xx.dtsi  |2 ++
   arch/arm/boot/dts/omap4.dtsi   |3 +++
   arch/arm/boot/dts/omap5.dtsi   |2 ++
   4 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/arm/omap/omap.txt
b/Documentation/devicetree/bindings/arm/omap/omap.txt
index 91b7049..808c154 100644
--- a/Documentation/devicetree/bindings/arm/omap/omap.txt
+++ b/Documentation/devicetree/bindings/arm/omap/omap.txt
@@ -21,7 +21,8 @@ Required properties:
   Optional properties:
   - ti,no_idle_on_suspend: When present, it prevents the PM to idle
the module
 during suspend.
-
+- ti,no-reset-on-init: When present, the module should not be reset
at init
+- ti,no-idle-on-init: When present, the module should not be idled
at init

   Example:

diff --git a/arch/arm/boot/dts/am33xx.dtsi
b/arch/arm/boot/dts/am33xx.dtsi
index f9c5da9..ec33ea0 100644
--- a/arch/arm/boot/dts/am33xx.dtsi
+++ b/arch/arm/boot/dts/am33xx.dtsi
@@ -607,6 +607,7 @@
   reg = 0x44d0 0x4000/* M3 UMEM */
  0x44d8 0x2000;/* M3 DMEM */
   ti,hwmods = wkup_m3;
+ti,no-reset-on-init;
   };

   elm: elm@4808 {
@@ -637,6 +638,7 @@
   gpmc: gpmc@5000 {
   compatible = ti,am3352-gpmc;
   ti,hwmods = gpmc;
+ti,no-idle-on-init;
   reg = 0x5000 0x2000;
   interrupts = 100;
   gpmc,num-cs = 7;
diff --git a/arch/arm/boot/dts/omap4.dtsi
b/arch/arm/boot/dts/omap4.dtsi
index 22d9f2b..e8fe797 100644
--- a/arch/arm/boot/dts/omap4.dtsi
+++ b/arch/arm/boot/dts/omap4.dtsi
@@ -214,6 +214,7 @@
   gpmc,num-cs = 8;
   gpmc,num-waitpins = 4;
   ti,hwmods = gpmc;
+ti,no-idle-on-init;
   };

   uart1: serial@4806a000 {
@@ -492,6 +493,7 @@
   reg = 0x4c00 0x100;
   interrupts = GIC_SPI 110 IRQ_TYPE_LEVEL_HIGH;
   ti,hwmods = emif1;
+ti,no-idle-on-init;
   phy-type = 1;
   hw-caps-read-idle-ctrl;
   hw-caps-ll-interface;
@@ -503,6 +505,7 @@
   reg = 0x4d00 0x100;
   interrupts = GIC_SPI 111 IRQ_TYPE_LEVEL_HIGH;
   ti,hwmods = emif2;
+ti,no-idle-on-init;
   phy-type = 1;
   hw-caps-read-idle-ctrl;
   hw-caps-ll-interface;
diff --git a/arch/arm/boot/dts/omap5.dtsi
b/arch/arm/boot/dts/omap5.dtsi
index 7cdea1b..a9d49df 100644
--- a/arch/arm/boot/dts/omap5.dtsi
+++ b/arch/arm/boot/dts/omap5.dtsi
@@ -607,6 +607,7 @@
   emif1: emif@0x4c00 {
   compatible= ti,emif-4d5;
   ti,hwmods= emif1;
+ti,no-idle-on-init;
   phy-type= 2; /* DDR PHY type: Intelli PHY */
   reg = 0x4c00 0x400;
   interrupts = GIC_SPI 110 IRQ_TYPE_LEVEL_HIGH;
@@ -618,6 +619,7 @@
   emif2: emif@0x4d00 {
   compatible= ti,emif-4d5;
   ti,hwmods= emif2;
+ti,no-idle-on-init;
   phy-type= 2; /* DDR PHY type: Intelli PHY */
   reg = 0x4d00 0x400;
   interrupts = GIC_SPI 111 IRQ_TYPE_LEVEL_HIGH;










--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] ARM: dts: omap4-panda-es: Do not reset gpio1

2013-10-15 Thread Benoit Cousson

Hi Nishanth,

On 10/10/2013 18:44, Nishanth Menon wrote:

Do not reset GPIO1 at boot-up because GPIO 7 in GPIO1 block is used on
OMAP4460 PandaBoard-ES to select voltage register in TPS62361 which
supplies VDD_MPU.

Without this, OMAP4460 PandaBoard-ES boards fail to boot-up because
MPU voltage switches over to VSET0 voltage value (boot voltage) which
is not sufficient to operate the device at OPP100.

Signed-off-by: Nishanth Menon n...@ti.com
---
As explained here: http://marc.info/?l=u-bootm=133066647800872w=2

GPIO1 reset causes PandaBoard-ES to stop functioning.
This depends on Patch series from Rajendra:
http://marc.info/?l=linux-docm=138131355520116w=2
Applies on Benoit's for_13/dts branch:
https://git.kernel.org/cgit/linux/kernel/git/bcousson/linux-omap-dt.git/log/?h=for_3.13/dts


I've just applied it after Rajendra's series.

Thanks,
Benoit




Tested on PandaBoard-ES without the u-boot uenv hack

  arch/arm/boot/dts/omap4-panda-es.dts |4 
  1 file changed, 4 insertions(+)

diff --git a/arch/arm/boot/dts/omap4-panda-es.dts 
b/arch/arm/boot/dts/omap4-panda-es.dts
index 56c4354..816d1c9 100644
--- a/arch/arm/boot/dts/omap4-panda-es.dts
+++ b/arch/arm/boot/dts/omap4-panda-es.dts
@@ -62,3 +62,7 @@
gpios = gpio1 8 GPIO_ACTIVE_HIGH;
};
  };
+
+gpio1 {
+ti,no-reset-on-init;
+};




--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[GIT PULL] ARM: OMAP: Device Tree for 3.13

2013-10-11 Thread Benoit Cousson
Hi Tony,

Please pull the following commits for OMAP Device Tree for v3.13.

Thanks,
Benoit


The following changes since commit d0e639c9e06d44e713170031fe05fb60ebe680af:

  Linux 3.12-rc4 (2013-10-06 14:00:20 -0700)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/bcousson/linux-omap-dt.git 
tags/for_3.13/dts_signed

for you to fetch changes up to a778dd01b9ed97af513b53bfaa74039ab5f4b8f2:

  ARM: dts: omap5-uevm: mark TWL6037 as system-power-controller (2013-10-09 
00:37:56 +0200)


Add the minimal DTS support for DRA7xx based SoC core.
Add the initial support for N900 and gta04 phones.
Enable USB3 on OMAP5 evm board.
Add support for cryto accelerators
Add new IGEP AQUILA board
Add AM33XX EDMA support
Update HSUSB node to use the reset-gpios fmwk


Aaro Koskinen (1):
  ARM: dts: omap3-devkit8000: fix a typo in GMPC node

Afzal Mohammed (2):
  ARM: dts: AM4372: cpu(s) node per latest binding
  ARM: dts: AM4372: add few nodes

Alexander Holler (1):
  ARM: dts: am335x-bone: add CD for mmc1

Alexandre Belloni (1):
  ARM: dts: AM33XX: Add PMU support

Balaji T K (2):
  ARM: dts: am335x-bone-common: correct mux mode for cmd line
  ARM: dts: am335x-evm[sdk]: switch mmc1 to 4-bit mode

Benoit Cousson (1):
  ARM: OMAP5: hwmod: add missing ocp2scp hwmod data

Benoit Parrot (1):
  ARM: dts: AM33XX: Add LCDC info into am335x-evm

Dan Murphy (1):
  ARM: dts: AM33XX: add ethernet alias's for am33xx

Darren Etheridge (1):
  ARM: dts: AM33XX beagle black: add pinmux and hdmi node to enable display

Enric Balletbo i Serra (2):
  ARM: dts: AM33XX: Add support for IGEP COM AQUILA
  ARM: dts: AM33XX: Add support for IGEP AQUILA EXPANSION board.

Felipe Balbi (2):
  ARM: dts: OMAP5: add palmas-usb node
  ARM: configs: omap2plus_defconfig: enable dwc3 and dependencies

Javier Martinez Canillas (8):
  ARM: dts: omap3-igep: add pinmux node for GPIO LED configuration
  ARM: dts: omap3-igep0020: add mux conf for GPIO LEDs
  ARM: dts: omap3-igep0030: add mux conf for GPIO LED
  ARM: dts: AM33XX: use pinmux node defined in included file
  ARM: dts: AM33XX: don't redefine OCP bus and device nodes
  ARM: dts: omap3-igep: Add USB OTG support
  ARM: dts: omap3-igep0020: Add HS USB Host support
  ARM: dts: omap3-igep0020: use standard constant for IRQ flags

Joel Fernandes (5):
  ARM: dts: OMAP4: Add AES node
  ARM: dts: OMAP4: Add DES3DES node
  ARM: dts: AM33XX: Fix AES interrupt number
  ARM: dts: AM437X: Add AES node
  ARM: dts: AM437X: Add DES node

Keerthy (1):
  ARM: dts: DRA7: Add TPS659038 PMIC nodes

Kishon Vijay Abraham I (1):
  ARM: dts: omap5-uevm: Split SMPS10 in two nodes

Koen Kooi (3):
  ARM: dts: am335x-boneblack: add eMMC DT entry
  ARM: dts: am335x-bone-common: switch mmc1 to 4-bit mode
  ARM: dts: am335x-bone-common: add cpu0 and mmc1 triggers

Lars Poeschel (1):
  ARM: dts: AM33xx: Correct gpio #interrupt-cells property

Lee Jones (7):
  ARM: dts: Remove '0x's from OMAP2420 H4 DTS file
  ARM: dts: Remove '0x's from OMAP3 IGEP0020 DTS file
  ARM: dts: Remove '0x's from OMAP3 IGEP0030 DTS file
  ARM: dts: Remove '0x's from OMAP3 DTS file
  ARM: dts: Remove '0x's from OMAP3430 SDP DTS file
  ARM: dts: Remove '0x's from OMAP4 DTS file
  ARM: dts: Remove '0x's from OMAP5 DTS file

Marek Belisko (1):
  ARM: dts: Add devicetree for gta04 board.

Mark A. Greer (2):
  ARM: dts: AM33XX: Add SHAM data and documentation
  ARM: dts: AM33XX: Add AES data and documentation

Matt Porter (3):
  ARM: dts: AM33XX: Add EDMA support
  ARM: dts: AM33XX: Add SPI DMA support
  ARM: dts: AM33XX: Add MMC support and documentation

Nishanth Menon (2):
  ARM: dts: am335x-boneblack: move fixed regulator to board level
  ARM: dts: omap5-uevm: mark TWL6037 as system-power-controller

Pavel Machek (1):
  ARM: dts: N900: Add device tree

R Sricharan (1):
  ARM: dts: DRA7: Add the dts files for dra7 SoC and dra7-evm board

Roger Quadros (6):
  ARM: dts: omap3-beagle: Make USB host pin naming consistent
  ARM: dts: omap3-beagle: Use reset-gpios for hsusb2_reset
  ARM: dts: omap4-panda: Use reset-gpios for hsusb1_reset
  ARM: dts: omap5-uevm: Use reset-gpios for hsusb2/3_reset
  ARM: dts: omap3-beagle-xm: Add USB Host support
  ARM: dts: omap3-beagle: Add USB OTG PHY details

Ruslan Bilovol (1):
  ARM: dts: twl6030: Move common configuration for OMAP4 boards in a 
separate dtsi file

 .../devicetree/bindings/crypto/omap-aes.txt|  31 +
 .../devicetree/bindings/crypto/omap-sham.txt   |  28 +
 .../devicetree/bindings/mmc/ti-omap-hsmmc.txt  |  26 +-
 arch/arm/boot/dts/Makefile |   6 +-
 arch/arm/boot/dts/am335x-base0033

Re: [GIT PULL] ARM: OMAP: Device Tree for 3.13

2013-10-11 Thread Benoit Cousson

Hi Tony,

On 11/10/2013 20:03, Tony Lindgren wrote:

Hi Benoit,

* Benoit Cousson bcous...@baylibre.com [131011 09:50]:

Add the minimal DTS support for DRA7xx based SoC core.
Add the initial support for N900 and gta04 phones.
Enable USB3 on OMAP5 evm board.
Add support for cryto accelerators
Add new IGEP AQUILA board
Add AM33XX EDMA support
Update HSUSB node to use the reset-gpios fmwk


Looks good to me, but we're getting self-inflicted merge
conflicts in two places now with Paul's hwmod changes,
and my defconfig changes.


Damn!


Can you please respin without the following two patches:

49bcd824c1c0db32fe4de0c1ba3ee36defdb11ca ARM: configs: omap2plus_defconfig: 
enable dwc3 and dependencies
736c4bb159c793b00331261438deb982cbac3c03 ARM: OMAP5: hwmod: add missing ocp2scp 
hwmod data

I can pick the two patches above and apply after pulling in
Paul's branch first.


OK, no problem.



However, if other branches are based on this, then we just
need to deal with the merge conflicts, and there's no point
in redoing your branch.


Considering the patches, I don't see any dependency with the other ones, 
as soon as they are pulled before the DTS changes.


I'll do that ASAP and repost.

Benoit

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


Re: [PATCH v2 1/2] ARM: dts: dra7-evm: Add mmc1 node for micro-sd support

2013-10-11 Thread Benoit Cousson

Hi Balaji,

On 11/10/2013 18:44, Balaji T K wrote:

On Thursday 10 October 2013 12:21 AM, Sekhar Nori wrote:

On Monday 07 October 2013 09:55 PM, Balaji T K wrote:

Add mmc1 dt node to dra7-evm board.
Input for ldo1 regulator is controlled by gpio 5 of pcf8575 chip (0x21)
on i2c1 bus. When dt support for gpio-pcf857x is available, input supply
will be modelled as cascaded regulator.

Signed-off-by: Balaji T K balaj...@ti.com


Acked-by: Sekhar Nori nsek...@ti.com


Hi Benoit,

Can you let me know if you have any comments on this patch series?


The series looks good, and I've just applied it for 3.13.

Thanks,
Benoit

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


[GIT PULL] ARM: OMAP: Device Tree for 3.13, take #2

2013-10-11 Thread Benoit Cousson
Hi Tony,

Please pull the updated branch for OMAP Device Tree for v3.13.

I removed the 2 conflicting patches, and added 2 mores for dra7 to compensate 
:-)

Thanks,
Benoit



The following changes since commit d0e639c9e06d44e713170031fe05fb60ebe680af:

  Linux 3.12-rc4 (2013-10-06 14:00:20 -0700)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/bcousson/linux-omap-dt.git 
tags/for_3.13/dts_signed

for you to fetch changes up to 6cf02dbb4b71f1c0c9acec89ae2df3b2318135f4:

  ARM: dts: dra7-evm: Add mmc2 node for eMMC support (2013-10-11 21:15:02 +0200)


Add the minimal DTS support for DRA7xx based SoC core.
Add the initial support for N900 and gta04 phones.
Enable USB3 on OMAP5 evm board.
Add support for cryto accelerators
Add new IGEP AQUILA board
Add AM33XX EDMA support
Update HSUSB node to use the reset-gpios fmwk


Aaro Koskinen (1):
  ARM: dts: omap3-devkit8000: fix a typo in GMPC node

Afzal Mohammed (2):
  ARM: dts: AM4372: cpu(s) node per latest binding
  ARM: dts: AM4372: add few nodes

Alexander Holler (1):
  ARM: dts: am335x-bone: add CD for mmc1

Alexandre Belloni (1):
  ARM: dts: AM33XX: Add PMU support

Balaji T K (4):
  ARM: dts: am335x-bone-common: correct mux mode for cmd line
  ARM: dts: am335x-evm[sdk]: switch mmc1 to 4-bit mode
  ARM: dts: dra7-evm: Add mmc1 node for micro-sd support
  ARM: dts: dra7-evm: Add mmc2 node for eMMC support

Benoit Parrot (1):
  ARM: dts: AM33XX: Add LCDC info into am335x-evm

Dan Murphy (1):
  ARM: dts: AM33XX: add ethernet alias's for am33xx

Darren Etheridge (1):
  ARM: dts: AM33XX beagle black: add pinmux and hdmi node to enable display

Enric Balletbo i Serra (2):
  ARM: dts: AM33XX: Add support for IGEP COM AQUILA
  ARM: dts: AM33XX: Add support for IGEP AQUILA EXPANSION board.

Felipe Balbi (1):
  ARM: dts: OMAP5: add palmas-usb node

Javier Martinez Canillas (8):
  ARM: dts: omap3-igep: add pinmux node for GPIO LED configuration
  ARM: dts: omap3-igep0020: add mux conf for GPIO LEDs
  ARM: dts: omap3-igep0030: add mux conf for GPIO LED
  ARM: dts: AM33XX: use pinmux node defined in included file
  ARM: dts: AM33XX: don't redefine OCP bus and device nodes
  ARM: dts: omap3-igep: Add USB OTG support
  ARM: dts: omap3-igep0020: Add HS USB Host support
  ARM: dts: omap3-igep0020: use standard constant for IRQ flags

Joel Fernandes (5):
  ARM: dts: OMAP4: Add AES node
  ARM: dts: OMAP4: Add DES3DES node
  ARM: dts: AM33XX: Fix AES interrupt number
  ARM: dts: AM437X: Add AES node
  ARM: dts: AM437X: Add DES node

Keerthy (1):
  ARM: dts: DRA7: Add TPS659038 PMIC nodes

Kishon Vijay Abraham I (1):
  ARM: dts: omap5-uevm: Split SMPS10 in two nodes

Koen Kooi (3):
  ARM: dts: am335x-boneblack: add eMMC DT entry
  ARM: dts: am335x-bone-common: switch mmc1 to 4-bit mode
  ARM: dts: am335x-bone-common: add cpu0 and mmc1 triggers

Lars Poeschel (1):
  ARM: dts: AM33xx: Correct gpio #interrupt-cells property

Lee Jones (7):
  ARM: dts: Remove '0x's from OMAP2420 H4 DTS file
  ARM: dts: Remove '0x's from OMAP3 IGEP0020 DTS file
  ARM: dts: Remove '0x's from OMAP3 IGEP0030 DTS file
  ARM: dts: Remove '0x's from OMAP3 DTS file
  ARM: dts: Remove '0x's from OMAP3430 SDP DTS file
  ARM: dts: Remove '0x's from OMAP4 DTS file
  ARM: dts: Remove '0x's from OMAP5 DTS file

Marek Belisko (1):
  ARM: dts: Add devicetree for gta04 board.

Mark A. Greer (2):
  ARM: dts: AM33XX: Add SHAM data and documentation
  ARM: dts: AM33XX: Add AES data and documentation

Matt Porter (3):
  ARM: dts: AM33XX: Add EDMA support
  ARM: dts: AM33XX: Add SPI DMA support
  ARM: dts: AM33XX: Add MMC support and documentation

Nishanth Menon (2):
  ARM: dts: am335x-boneblack: move fixed regulator to board level
  ARM: dts: omap5-uevm: mark TWL6037 as system-power-controller

Pavel Machek (1):
  ARM: dts: N900: Add device tree

R Sricharan (1):
  ARM: dts: DRA7: Add the dts files for dra7 SoC and dra7-evm board

Roger Quadros (6):
  ARM: dts: omap3-beagle: Make USB host pin naming consistent
  ARM: dts: omap3-beagle: Use reset-gpios for hsusb2_reset
  ARM: dts: omap4-panda: Use reset-gpios for hsusb1_reset
  ARM: dts: omap5-uevm: Use reset-gpios for hsusb2/3_reset
  ARM: dts: omap3-beagle-xm: Add USB Host support
  ARM: dts: omap3-beagle: Add USB OTG PHY details

Ruslan Bilovol (1):
  ARM: dts: twl6030: Move common configuration for OMAP4 boards in a 
separate dtsi file

 .../devicetree/bindings/crypto/omap-aes.txt|  31 +
 .../devicetree/bindings/crypto/omap-sham.txt   |  28 +
 .../devicetree/bindings/mmc/ti-omap-hsmmc.txt  |  26 +-
 arch/arm/boot/dts/Makefile |   

Re: [PATCH] ARM: DRA: DTS: Remove clock-frequency field for cpu timers

2013-10-11 Thread Benoit Cousson

Hi Sricharan,

On 10/10/2013 15:11, Santosh Shilimkar wrote:

On Thursday 10 October 2013 03:50 AM, Sricharan R wrote:

The arm arch timers frequency are now programmed in the CNTFREQ
per-cpu register by the timer code using the secure API [1].
So remove the redundant entry from the dts.

[1] http://marc.info/?l=linux-omapm=138139106312786w=2

Cc: Benoit Cousson bcous...@baylibre.com
Signed-off-by: Sricharan R r.sricha...@ti.com
---

Acked-by: Santosh Shilimkar santosh.shilim...@ti.com



I've just applied it for 3.13.

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


Re: [PATCH 3/3] ARM: OMAP2+: Let DT say what devices should not to idled or reset

2013-10-09 Thread Benoit Cousson

Hi Rajendra,

On 09/10/2013 09:37, Rajendra Nayak wrote:

On Wednesday 09 October 2013 12:54 PM, Paul Walmsley wrote:

Hi Benoît, Rajendra,

On Tue, 20 Aug 2013, Rajendra Nayak wrote:


Now that we have DT bindings to specify which devices on the SoC should not
be reset or idled, get rid of the same information existing as part of the
hwmod data files and pass this info from DT instead.

For GPMC, the HWMOD_INIT_NO_RESET flag seems to be added in hwmod not due to
any errata around the GPMC IP, but rather because any timings
set by the bootloader are not being correctly programmed by the kernel.
This seems like something that needs to be fixed as part of GPMC driver
in the kernel, and hence the flag is left as is in hwmod, which can be
removed once the driver does what its expected to.

Signed-off-by: Rajendra Nayak rna...@ti.com
---
  arch/arm/boot/dts/am33xx.dtsi  |2 ++
  arch/arm/boot/dts/omap4.dtsi   |3 +++
  arch/arm/boot/dts/omap5.dtsi   |2 ++
  arch/arm/mach-omap2/omap_hwmod_33xx_data.c |4 ++--
  arch/arm/mach-omap2/omap_hwmod_44xx_data.c |4 +---
  arch/arm/mach-omap2/omap_hwmod_54xx_data.c |2 --
  6 files changed, 10 insertions(+), 7 deletions(-)


Looking at this one, maybe the best thing for this patch is for Rajendra
to split it into two patches.  Benoît can merge the DTS patch first, then
I can merge the hwmod side as a cleanup once the first one goes in.  That
will avoid conflicts from other DTS and hwmod changes going into the tree.

Rajendra, when you do the split, please add in the DT documentation part
from patch 2.  Am going to strip that out from the second patch and just
merge the hwmod changes.

Sound good?


Sure Paul, I'll repost the complete series with proper splits such that its
easier for you and Benoit to pick them up independently.


If you could do it soon, I'm about to send an early pull request to Tony 
to avoid the trouble we had last time.


Thanks,
Benoit

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


Re: [PATCH v2 2/5] ARM: dts: omap: Add new bindings for OMAP

2013-10-09 Thread Benoit Cousson

Hi Rajendra,

On 09/10/2013 12:11, Rajendra Nayak wrote:

On OMAP we have co-processor IPs, memory controllers,
GPIOs which control regulators and power switches to
PMIC, and SoC internal Bus IPs, some or most of which
should either not be reset or idled or both at init.
(In some cases there are erratas which prevent an IP
from being reset)
Have a way to pass this information from DT.


Did you get some acked-by from the DT maintainers?
Every new bindings must be carefully reviewed now.

Regards,
Benoit



Update the am33xx/omap4 and omap5 dtsi files with the
new bindings for modules which either should not be
idled. reset or both. A later patch would cleanup the
same information that exists today as part of the hwmod
data files.

Signed-off-by: Rajendra Nayak rna...@ti.com
---
  .../devicetree/bindings/arm/omap/omap.txt  |3 ++-
  arch/arm/boot/dts/am33xx.dtsi  |2 ++
  arch/arm/boot/dts/omap4.dtsi   |3 +++
  arch/arm/boot/dts/omap5.dtsi   |2 ++
  4 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/arm/omap/omap.txt 
b/Documentation/devicetree/bindings/arm/omap/omap.txt
index 91b7049..808c154 100644
--- a/Documentation/devicetree/bindings/arm/omap/omap.txt
+++ b/Documentation/devicetree/bindings/arm/omap/omap.txt
@@ -21,7 +21,8 @@ Required properties:
  Optional properties:
  - ti,no_idle_on_suspend: When present, it prevents the PM to idle the module
during suspend.
-
+- ti,no-reset-on-init: When present, the module should not be reset at init
+- ti,no-idle-on-init: When present, the module should not be idled at init

  Example:

diff --git a/arch/arm/boot/dts/am33xx.dtsi b/arch/arm/boot/dts/am33xx.dtsi
index f9c5da9..ec33ea0 100644
--- a/arch/arm/boot/dts/am33xx.dtsi
+++ b/arch/arm/boot/dts/am33xx.dtsi
@@ -607,6 +607,7 @@
reg = 0x44d0 0x4000 /* M3 UMEM */
   0x44d8 0x2000;   /* M3 DMEM */
ti,hwmods = wkup_m3;
+   ti,no-reset-on-init;
};

elm: elm@4808 {
@@ -637,6 +638,7 @@
gpmc: gpmc@5000 {
compatible = ti,am3352-gpmc;
ti,hwmods = gpmc;
+   ti,no-idle-on-init;
reg = 0x5000 0x2000;
interrupts = 100;
gpmc,num-cs = 7;
diff --git a/arch/arm/boot/dts/omap4.dtsi b/arch/arm/boot/dts/omap4.dtsi
index 22d9f2b..e8fe797 100644
--- a/arch/arm/boot/dts/omap4.dtsi
+++ b/arch/arm/boot/dts/omap4.dtsi
@@ -214,6 +214,7 @@
gpmc,num-cs = 8;
gpmc,num-waitpins = 4;
ti,hwmods = gpmc;
+   ti,no-idle-on-init;
};

uart1: serial@4806a000 {
@@ -492,6 +493,7 @@
reg = 0x4c00 0x100;
interrupts = GIC_SPI 110 IRQ_TYPE_LEVEL_HIGH;
ti,hwmods = emif1;
+   ti,no-idle-on-init;
phy-type = 1;
hw-caps-read-idle-ctrl;
hw-caps-ll-interface;
@@ -503,6 +505,7 @@
reg = 0x4d00 0x100;
interrupts = GIC_SPI 111 IRQ_TYPE_LEVEL_HIGH;
ti,hwmods = emif2;
+   ti,no-idle-on-init;
phy-type = 1;
hw-caps-read-idle-ctrl;
hw-caps-ll-interface;
diff --git a/arch/arm/boot/dts/omap5.dtsi b/arch/arm/boot/dts/omap5.dtsi
index 7cdea1b..a9d49df 100644
--- a/arch/arm/boot/dts/omap5.dtsi
+++ b/arch/arm/boot/dts/omap5.dtsi
@@ -607,6 +607,7 @@
emif1: emif@0x4c00 {
compatible  = ti,emif-4d5;
ti,hwmods   = emif1;
+   ti,no-idle-on-init;
phy-type= 2; /* DDR PHY type: Intelli PHY */
reg = 0x4c00 0x400;
interrupts = GIC_SPI 110 IRQ_TYPE_LEVEL_HIGH;
@@ -618,6 +619,7 @@
emif2: emif@0x4d00 {
compatible  = ti,emif-4d5;
ti,hwmods   = emif2;
+   ti,no-idle-on-init;
phy-type= 2; /* DDR PHY type: Intelli PHY */
reg = 0x4d00 0x400;
interrupts = GIC_SPI 111 IRQ_TYPE_LEVEL_HIGH;



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


Re: [PATCH v2 2/5] ARM: dts: omap: Add new bindings for OMAP

2013-10-09 Thread Benoit Cousson

+ A couple of DT maintainers

On 09/10/2013 18:41, Rajendra Nayak wrote:

On Wednesday 09 October 2013 08:43 PM, Benoit Cousson wrote:

Hi Rajendra,

On 09/10/2013 12:11, Rajendra Nayak wrote:

On OMAP we have co-processor IPs, memory controllers,
GPIOs which control regulators and power switches to
PMIC, and SoC internal Bus IPs, some or most of which
should either not be reset or idled or both at init.
(In some cases there are erratas which prevent an IP
from being reset)
Have a way to pass this information from DT.


Did you get some acked-by from the DT maintainers?
Every new bindings must be carefully reviewed now.


Nope, I haven't. The patches are on the list for a couple
of months now.


Let's see if Mark and Rob are OK with that.

Thanks,
Benoit





Regards,
Benoit



Update the am33xx/omap4 and omap5 dtsi files with the
new bindings for modules which either should not be
idled. reset or both. A later patch would cleanup the
same information that exists today as part of the hwmod
data files.

Signed-off-by: Rajendra Nayak rna...@ti.com
---
   .../devicetree/bindings/arm/omap/omap.txt  |3 ++-
   arch/arm/boot/dts/am33xx.dtsi  |2 ++
   arch/arm/boot/dts/omap4.dtsi   |3 +++
   arch/arm/boot/dts/omap5.dtsi   |2 ++
   4 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/arm/omap/omap.txt 
b/Documentation/devicetree/bindings/arm/omap/omap.txt
index 91b7049..808c154 100644
--- a/Documentation/devicetree/bindings/arm/omap/omap.txt
+++ b/Documentation/devicetree/bindings/arm/omap/omap.txt
@@ -21,7 +21,8 @@ Required properties:
   Optional properties:
   - ti,no_idle_on_suspend: When present, it prevents the PM to idle the module
 during suspend.
-
+- ti,no-reset-on-init: When present, the module should not be reset at init
+- ti,no-idle-on-init: When present, the module should not be idled at init

   Example:

diff --git a/arch/arm/boot/dts/am33xx.dtsi b/arch/arm/boot/dts/am33xx.dtsi
index f9c5da9..ec33ea0 100644
--- a/arch/arm/boot/dts/am33xx.dtsi
+++ b/arch/arm/boot/dts/am33xx.dtsi
@@ -607,6 +607,7 @@
   reg = 0x44d0 0x4000/* M3 UMEM */
  0x44d8 0x2000;/* M3 DMEM */
   ti,hwmods = wkup_m3;
+ti,no-reset-on-init;
   };

   elm: elm@4808 {
@@ -637,6 +638,7 @@
   gpmc: gpmc@5000 {
   compatible = ti,am3352-gpmc;
   ti,hwmods = gpmc;
+ti,no-idle-on-init;
   reg = 0x5000 0x2000;
   interrupts = 100;
   gpmc,num-cs = 7;
diff --git a/arch/arm/boot/dts/omap4.dtsi b/arch/arm/boot/dts/omap4.dtsi
index 22d9f2b..e8fe797 100644
--- a/arch/arm/boot/dts/omap4.dtsi
+++ b/arch/arm/boot/dts/omap4.dtsi
@@ -214,6 +214,7 @@
   gpmc,num-cs = 8;
   gpmc,num-waitpins = 4;
   ti,hwmods = gpmc;
+ti,no-idle-on-init;
   };

   uart1: serial@4806a000 {
@@ -492,6 +493,7 @@
   reg = 0x4c00 0x100;
   interrupts = GIC_SPI 110 IRQ_TYPE_LEVEL_HIGH;
   ti,hwmods = emif1;
+ti,no-idle-on-init;
   phy-type = 1;
   hw-caps-read-idle-ctrl;
   hw-caps-ll-interface;
@@ -503,6 +505,7 @@
   reg = 0x4d00 0x100;
   interrupts = GIC_SPI 111 IRQ_TYPE_LEVEL_HIGH;
   ti,hwmods = emif2;
+ti,no-idle-on-init;
   phy-type = 1;
   hw-caps-read-idle-ctrl;
   hw-caps-ll-interface;
diff --git a/arch/arm/boot/dts/omap5.dtsi b/arch/arm/boot/dts/omap5.dtsi
index 7cdea1b..a9d49df 100644
--- a/arch/arm/boot/dts/omap5.dtsi
+++ b/arch/arm/boot/dts/omap5.dtsi
@@ -607,6 +607,7 @@
   emif1: emif@0x4c00 {
   compatible= ti,emif-4d5;
   ti,hwmods= emif1;
+ti,no-idle-on-init;
   phy-type= 2; /* DDR PHY type: Intelli PHY */
   reg = 0x4c00 0x400;
   interrupts = GIC_SPI 110 IRQ_TYPE_LEVEL_HIGH;
@@ -618,6 +619,7 @@
   emif2: emif@0x4d00 {
   compatible= ti,emif-4d5;
   ti,hwmods= emif2;
+ti,no-idle-on-init;
   phy-type= 2; /* DDR PHY type: Intelli PHY */
   reg = 0x4d00 0x400;
   interrupts = GIC_SPI 111 IRQ_TYPE_LEVEL_HIGH;







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


Re: [PATCH v3 0/3] ARM: dts: omap3-igep: improvements for v3.13

2013-10-08 Thread Benoit Cousson

Hi Javier

On 07/10/2013 17:12, Javier Martinez Canillas wrote:

Hi Benoit,

This series are some enhancements and cleanups for IGEP boards
that it would be great if can make it for v3.13.

This is a third version of the patch-set that addresses some issues
raised by Roger Quadros and is composed of the following patches:

[PATCH v3 1/3] ARM: dts: omap3-igep: Add USB OTG support
[PATCH v3 2/3] ARM: dts: omap3-igep0020: Add HS USB Host support
[PATCH v3 3/3] ARM: dts: omap3-igep0020: use standard constant for IRQ

The patches were tested using the new generic PHY framework that are
currently on usb-next branch and will be part of v3.13


I've just pulled them into my branch.

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


Re: [PATCH v3 0/3] AM33XX crypto DTS patches

2013-10-08 Thread Benoit Cousson

Hi Joel,

n 05/10/2013 21:04, Joel Fernandes wrote:

These patches are some minor fixups and changes to commit messages to the
AM33XX crypto (aes, sham) patches with reference to the comments at:
http://comments.gmane.org/gmane.linux.drivers.devicetree/45961

Joel Fernandes (1):
   ARM: dts: AM33XX: Fix AES interrupt number

Mark A. Greer (2):
   ARM: dts: AM33XX: Add SHAM data and documentation
   ARM: dts: AM33XX: Add AES data and documentation

  .../devicetree/bindings/crypto/omap-aes.txt| 31 ++
  .../devicetree/bindings/crypto/omap-sham.txt   | 28 +++
  arch/arm/boot/dts/am335x-bone.dts  |  8 ++
  arch/arm/boot/dts/am335x-evm.dts   |  8 ++
  arch/arm/boot/dts/am335x-evmsk.dts |  8 ++
  arch/arm/boot/dts/am33xx.dtsi  | 19 +
  6 files changed, 102 insertions(+)
  create mode 100644 Documentation/devicetree/bindings/crypto/omap-aes.txt
  create mode 100644 Documentation/devicetree/bindings/crypto/omap-sham.txt



I've just applied this series and the remaining ones from the previous 
version.


Thanks,
Benoit

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


Re: [PATCH] ARM: dts: omap5-uevm: mark TWL6037 as system-power-controller

2013-10-08 Thread Benoit Cousson

Hi Nishanth,

On 08/10/2013 17:43, Nishanth Menon wrote:

On 09/19/2013 02:11 PM, Nishanth Menon wrote:

This allows the palmas pm_power_off to kick in on power off command
and switch off the board.

Signed-off-by: Nishanth Menon n...@ti.com
---
Based on: (benoit's for_3.13/dts branch)
https://git.kernel.org/cgit/linux/kernel/git/bcousson/linux-omap-dt.git/log/?h=for_3.13/dts
This uses the support introduced by:
http://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=b81eec09a484c588ead035003ce7555ca8a9963a

  arch/arm/boot/dts/omap5-uevm.dts |1 +
  1 file changed, 1 insertion(+)

diff --git a/arch/arm/boot/dts/omap5-uevm.dts b/arch/arm/boot/dts/omap5-uevm.dts
index da25a14..8227386 100644
--- a/arch/arm/boot/dts/omap5-uevm.dts
+++ b/arch/arm/boot/dts/omap5-uevm.dts
@@ -271,6 +271,7 @@
reg = 0x48;
interrupt-controller;
#interrupt-cells = 2;
+   ti,system-power-controller;

extcon_usb3: palmas_usb {
compatible = ti,palmas-usb-vid;


Gentle ping.
patchworks link: https://patchwork.kernel.org/patch/2913111/


I've just applied it and pushed it to my branch.

Thanks,
Benoit

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


Re: [PATCH 1/3] ARM: dts: omap3-igep0020: Add USB OTG support

2013-10-07 Thread Benoit Cousson

Hi Javier,

On 07/10/2013 13:54, Javier Martinez Canillas wrote:

On 10/07/2013 12:43 PM, Roger Quadros wrote:

Javier,

On 10/05/2013 03:04 AM, Javier Martinez Canillas wrote:

Commit ad871c10b (ARM: dts: OMAP: Add usb_otg and glue data to OMAP3+ boards)
added USB OTG support for most OMAP boards but some OMAP3 boards
such as the IGEPv2 were not updated. This patch adds an USB OTG
device node to this board.

Signed-off-by: Javier Martinez Canillas javier.marti...@collabora.co.uk
---
  arch/arm/boot/dts/omap3-igep0020.dts | 7 +++
  1 file changed, 7 insertions(+)

diff --git a/arch/arm/boot/dts/omap3-igep0020.dts 
b/arch/arm/boot/dts/omap3-igep0020.dts
index eedf0d8..903e944 100644
--- a/arch/arm/boot/dts/omap3-igep0020.dts
+++ b/arch/arm/boot/dts/omap3-igep0020.dts
@@ -166,3 +166,10 @@
smsc,save-mac-address;
};
  };
+
+usb_otg_hs {
+   interface-type = 0;
+   usb-phy = usb2_phy;


With the PHY generic framework in Greg's usb-next branch [1], you will also 
need to add

+   phys = usb2_phy;
+   phy-names = usb2-phy;


+   mode = 3;
+   power = 50;
+};



So it would be good to test with the usb-next branch.

cheers,
-roger

[1] - git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git



Hi Roger,

Thanks for the pointer, I'll add those properties and test using the PHY generic
framework.


Should I expect a v3 then?

Benoit



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


Re: [PATCH 1/3] ARM: dts: omap3-igep0020: Add USB OTG support

2013-10-07 Thread Benoit Cousson

On 07/10/2013 14:02, Javier Martinez Canillas wrote:

On 10/07/2013 01:58 PM, Benoit Cousson wrote:

Hi Javier,

On 07/10/2013 13:54, Javier Martinez Canillas wrote:

On 10/07/2013 12:43 PM, Roger Quadros wrote:

Javier,

On 10/05/2013 03:04 AM, Javier Martinez Canillas wrote:

Commit ad871c10b (ARM: dts: OMAP: Add usb_otg and glue data to OMAP3+ boards)
added USB OTG support for most OMAP boards but some OMAP3 boards
such as the IGEPv2 were not updated. This patch adds an USB OTG
device node to this board.

Signed-off-by: Javier Martinez Canillas javier.marti...@collabora.co.uk
---
   arch/arm/boot/dts/omap3-igep0020.dts | 7 +++
   1 file changed, 7 insertions(+)

diff --git a/arch/arm/boot/dts/omap3-igep0020.dts 
b/arch/arm/boot/dts/omap3-igep0020.dts
index eedf0d8..903e944 100644
--- a/arch/arm/boot/dts/omap3-igep0020.dts
+++ b/arch/arm/boot/dts/omap3-igep0020.dts
@@ -166,3 +166,10 @@
smsc,save-mac-address;
};
   };
+
+usb_otg_hs {
+   interface-type = 0;
+   usb-phy = usb2_phy;


With the PHY generic framework in Greg's usb-next branch [1], you will also 
need to add

+   phys = usb2_phy;
+   phy-names = usb2-phy;


+   mode = 3;
+   power = 50;
+};



So it would be good to test with the usb-next branch.

cheers,
-roger

[1] - git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git



Hi Roger,

Thanks for the pointer, I'll add those properties and test using the PHY generic
framework.


Should I expect a v3 then?



Hi Benoit,

Yes, I'll test it and send a v3 in the next few hours, sorry for not being clear
about that.



That's OK, I was applying your series when I saw your email ;-)

I'm waiting for the next one.

Thanks,
Benoit

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


Re: [PATCHv3 0/2] ARM: dts: Add initial support for IGEP AQUILA

2013-10-04 Thread Benoit Cousson

Hi Enric,

On 03/10/2013 20:17, Tony Lindgren wrote:

* Javier Martinez Canillas martinez.jav...@gmail.com [130925 06:18]:

On Tue, Sep 10, 2013 at 4:55 PM, Enric Balletbo i Serra
eballe...@gmail.com wrote:

From: Enric Balletbo i Serra eballe...@iseebcn.com

Hi all,

These two patches introduces initial support for the IGEP AM335x-based
platforms. The first patch add support for IGEP COM AQUILA products, and the
second patch add support for the development board.

These patches apply on top of bcousson/for_3.12/dts repository.

Changes since v2:
   * Make it compatible with isee,am335x-base0033, isee,am335x-igep0033,
 ti,am33xx since these boards are manufactured by ISEE not TI. (Javier)
Changes since v1:
   * Use node to reference the nodes already defined in dtsi files. (Javier)

Best regards,

Enric Balletbo i Serra (2):
   ARM: dts: AM33XX: Add support for IGEP COM AQUILA
   ARM: dts: AM33XX: Add support for IGEP AQUILA EXPANSION board.

  arch/arm/boot/dts/Makefile |   1 +
  arch/arm/boot/dts/am335x-base0033.dts  |  16 ++
  arch/arm/boot/dts/am335x-igep0033.dtsi | 265 +
  3 files changed, 282 insertions(+)
  create mode 100644 arch/arm/boot/dts/am335x-base0033.dts
  create mode 100644 arch/arm/boot/dts/am335x-igep0033.dtsi

--
1.8.1.2



Hi Benoit and Tony,

Any comments on this series? I had already reviewed previous versions
of the DT and it looks good to me now.

It would be great if this can make it for 3.13.


Looks good to me, I would assume Benoit will be looking at this
shortly.


I did :-)

It looks good to me too, I've just fixed a conflict with my current 
branch in the Makefile and fix a typo in the header:


+++ b/arch/arm/boot/dts/am335x-base0033.dts
@@ -0,0 +1,16 @@
+/*
+ * am335x-base0033.dtsi - Device Tree file for IGEP AQUILA EXPANSION

Should be am335x-base0033.dts. I fixed it for you. Please check if the 
fix is ok in the branch.


Pushed on my for_3.13/dts branch.

Thanks,
Benoit

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


Re: [PATCH 1/2] ARM: dts: am335x-bone-common: correct mux mode for cmd line

2013-10-04 Thread Benoit Cousson

Hi Balaji,

On 27/09/2013 13:35, Balaji T K wrote:

pinmux_emmc_pins: mux mode for cmd line should be MODE2
to detect eMMC on beagle bone black and beagle bone white + eMMC cape.

Signed-off-by: Balaji T K balaj...@ti.com
Tested-by: Felipe Balbi ba...@ti.com
---
based on 
git://git.kernel.org/pub/scm/linux/kernel/git/bcousson/linux-omap-dt.git 
for_3.13/dts

  arch/arm/boot/dts/am335x-bone-common.dtsi |2 +-
  1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-bone-common.dtsi 
b/arch/arm/boot/dts/am335x-bone-common.dtsi
index ff5c3ca..51f6a99 100644
--- a/arch/arm/boot/dts/am335x-bone-common.dtsi
+++ b/arch/arm/boot/dts/am335x-bone-common.dtsi
@@ -153,7 +153,7 @@
emmc_pins: pinmux_emmc_pins {
pinctrl-single,pins = 
0x80 (PIN_INPUT_PULLUP | MUX_MODE2) /* 
gpmc_csn1.mmc1_clk */
-   0x84 (PIN_INPUT_PULLUP | MUX_MODE1) /* 
gpmc_csn2.mmc1_cmd */
+   0x84 (PIN_INPUT_PULLUP | MUX_MODE2) /* 
gpmc_csn2.mmc1_cmd */
0x00 (PIN_INPUT_PULLUP | MUX_MODE1) /* 
gpmc_ad0.mmc1_dat0 */
0x04 (PIN_INPUT_PULLUP | MUX_MODE1) /* 
gpmc_ad1.mmc1_dat1 */
0x08 (PIN_INPUT_PULLUP | MUX_MODE1) /* 
gpmc_ad2.mmc1_dat2 */



Thanks, I'll apply it for 3.13.

Regards,
Benoit

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


Re: [PATCH 2/2] ARM: dts: am335x-evm, am335x-evmsdk: switch mmc1 to 4-bit mode

2013-10-04 Thread Benoit Cousson

Hi Balaji,

On 27/09/2013 13:35, Balaji T K wrote:

set bus-width to make SD card operate in 4 bit mode.

Signed-off-by: Balaji T K balaj...@ti.com
---
based on 
git://git.kernel.org/pub/scm/linux/kernel/git/bcousson/linux-omap-dt.git 
for_3.13/dts

  arch/arm/boot/dts/am335x-evm.dts   |1 +
  arch/arm/boot/dts/am335x-evmsk.dts |1 +
  2 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-evm.dts b/arch/arm/boot/dts/am335x-evm.dts
index 23b0a3e..028ca09 100644
--- a/arch/arm/boot/dts/am335x-evm.dts
+++ b/arch/arm/boot/dts/am335x-evm.dts
@@ -521,4 +521,5 @@
  mmc1 {
status = okay;
vmmc-supply = vmmc_reg;
+   bus-width = 4;
  };
diff --git a/arch/arm/boot/dts/am335x-evmsk.dts 
b/arch/arm/boot/dts/am335x-evmsk.dts
index bc93895..563a2b1 100644
--- a/arch/arm/boot/dts/am335x-evmsk.dts
+++ b/arch/arm/boot/dts/am335x-evmsk.dts
@@ -423,4 +423,5 @@
  mmc1 {
status = okay;
vmmc-supply = vmmc_reg;
+   bus-width = 4;
  };



Thanks, I'll apply it for 3.13.

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


Re: [PATCH v2 0/9] ARM: dts: DT data for OMAP platforms for v3.13

2013-10-04 Thread Benoit Cousson

On 04/10/2013 04:00, Joel Fernandes wrote:

On 10/03/2013 08:25 AM, Benoit Cousson wrote:

+ DT list and DT maintainers.

Hi Joel,

Thanks for the update. It looks good to me.

For the new bindings added below;


   .../devicetree/bindings/crypto/omap-aes.txt| 34 ++
   .../devicetree/bindings/crypto/omap-sham.txt   | 31 +


I will need the acked-by from one of the DT maintainers.


Sure. To help with giving Ack for this, I'd like to also mention these patches
were due for long time and reposted. The supporting code is already in the 
kernel.

Also bindings were reviewed by Mark Rutland comments in the following thread
were addressed:
http://www.spinics.net/lists/arm-kernel/msg269006.html


OK, that's good news, at least it was already reviewed by Mark.

I'm fixing and pulling the series, and will add Mark's Acked-by as soon 
as he will send it.


Meanwhile some nits, I'm fixing myself this time :-)

None of your subjects is following the same guideline and the repertory 
guideline...


  omap4: dts: Add node for AES
  omap4: dts: Add node for DES3DES module
  am33xx: dts: Fix AES interrupt number
  ARM: am437x: dts: Add AES node for am437x
  ARM: am437x: dts: Add DES node for am437x

It should be ARM: dts: OMAPXXX or AMXXX...

Regards,
Benoit

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


Re: [PATCH v2 5/9] am33xx: dts: Fix AES interrupt number

2013-10-04 Thread Benoit Cousson

On 30/09/2013 17:13, Joel Fernandes wrote:

Signed-off-by: Joel Fernandes jo...@ti.com


Even if this is obvious, a small changelog is always recommended.


Thanks,
Benoit


---
  arch/arm/boot/dts/am33xx.dtsi | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/am33xx.dtsi b/arch/arm/boot/dts/am33xx.dtsi
index 0daa1b2..d7be90a 100644
--- a/arch/arm/boot/dts/am33xx.dtsi
+++ b/arch/arm/boot/dts/am33xx.dtsi
@@ -724,7 +724,7 @@
compatible = ti,omap4-aes;
ti,hwmods = aes;
reg = 0x5350 0xa0;
-   interrupts = 102;
+   interrupts = 103;
dmas = edma 6
edma 5;
dma-names = tx, rx;



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


Re: [RFC 00/15] Device Tree schemas and validation

2013-10-03 Thread Benoit Cousson

On 02/10/2013 15:54, David Gibson wrote:

On Tue, Oct 01, 2013 at 03:54:20PM -0500, Rob Herring wrote:

On Tue, Oct 1, 2013 at 10:06 AM, Benoit Cousson bcous...@baylibre.com wrote:

Hi Rob,


On 01/10/2013 15:17, Rob Herring wrote:


On 10/01/2013 03:06 AM, Benoit Cousson wrote:


+ more DT maintainers folks

Hi all,

I know this is mostly boring user space code, but I was expecting a
little bit of comments about at least the bindings syntax:-(

I'd like to know if this is the right direction and if it worth pursuing
in that direction.

The idea was to have at least some base for further discussion during
ARM KS 2013.

I feel alone :-(

If you have any comment, go ahead!



Thanks for taking this on!

This is interesting approach using the dts syntax,



Well, this was discussed a little bit on the list, and it has the big
advantage of re-using the parser already included in DTC for free.
In term or readability, it avoids to re-defining a brand new syntax for
people who are already familiar with the DTS one.



but I worry that the
validation will only be as good as the schema written and the review of
the schema.



Well, sure, but unfortunately, that will always be the case :-(
The bindings definition being quite open, there is no easy way to ensure
proper schema / bindings without careful review of the schema. There is no
such thing as a free beer... Unfortunately :-)



I think the schema needs to define the binding rather than
define the checks. Then the schema can feed the validation checks.




This format does not seem to me as easily being able to generate
documentation from the schema which I believe is one of the goals.



Indeed, but I think is it easy to generate any kind of readable format for
the documentation purpose if needed from the actual format.
Otherwise, we should consider a schema format based on kerneldoc type of
syntax to improve readability. I'm just afraid it will become harder then to
define complex schema.

BTW, what kind of documentation are you expecting here? Is is a text that
can be added on top of each schema?


I would expect the schema to replace
Documentation/devicetree/bindings/* over time. I think the thing that
needs to be worked out here is how to add free form multi-line text.


I'm not convinced that's a realistic goal.  As I see it, the
fundamental difference between a binding document and a formal schema
is that a binding defines both the syntax required of a node, and its
semantics, whereas a schema defines only syntax - the semantics still
need to be defined somewhere.



Mmm, I do not really understand what is missing in the following schema 
in term of semantic compared to the original interrupt-controller bindings?


interrupt-controller {
description = Identifies the node as an interrupt controller;
is-required;
type = bool;
};

#interrupt-cells {
description = Specifies the number of cells needed to encode an
   interrupt source. The type shall be a u32
   and the value shall be 1.
   The cell contains the interrupt number
   in the range [0-128].;
is-required;
type = integer;
value = 1;
};

As soon as you have a description you can keep the content of the 
original binding. But on top of that, you do have the schema validation 
information.


I'm not sure to understand your point. Could you elaborate?

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


Re: [PATCH v3 05/10] ARM: dts: omap3-beagle: Use reset-gpios for hsusb2_reset

2013-10-03 Thread Benoit Cousson

Hi Roger,

Yes, I will. I've been waiting for these ones for so long :-)

Thanks,
Benoit

On 03/10/2013 12:34, Roger Quadros wrote:

Hi Benoit,

Could you please take the device tree related patches [5 to 10] in this series?
Thanks.

cheers,
-roger

On 09/24/2013 11:53 AM, Roger Quadros wrote:

We no longer need to model the RESET line as a regulator since
the USB phy-nop driver accepts reset-gpios property.

Signed-off-by: Roger Quadros rog...@ti.com
---
  arch/arm/boot/dts/omap3-beagle.dts |   13 +
  1 files changed, 1 insertions(+), 12 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-beagle.dts 
b/arch/arm/boot/dts/omap3-beagle.dts
index dfd8310..71bde47 100644
--- a/arch/arm/boot/dts/omap3-beagle.dts
+++ b/arch/arm/boot/dts/omap3-beagle.dts
@@ -44,17 +44,6 @@
};
};

-   /* HS USB Port 2 RESET */
-   hsusb2_reset: hsusb2_reset_reg {
-   compatible = regulator-fixed;
-   regulator-name = hsusb2_reset;
-   regulator-min-microvolt = 330;
-   regulator-max-microvolt = 330;
-   gpio = gpio5 19 0; /* gpio_147 */
-   startup-delay-us = 7;
-   enable-active-high;
-   };
-
/* HS USB Port 2 Power */
hsusb2_power: hsusb2_power_reg {
compatible = regulator-fixed;
@@ -68,7 +57,7 @@
/* HS USB Host PHY on PORT 2 */
hsusb2_phy: hsusb2_phy {
compatible = usb-nop-xceiv;
-   reset-supply = hsusb2_reset;
+   reset-gpios = gpio5 19 GPIO_ACTIVE_LOW;/* gpio_147 */
vcc-supply = hsusb2_power;
};






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


Re: [RFC 00/15] Device Tree schemas and validation

2013-10-03 Thread Benoit Cousson

Hi Stephen,

On 02/10/2013 00:22, Stephen Warren wrote:

On 09/24/2013 10:52 AM, Benoit Cousson wrote:

Hi All,

Following the discussion that happened during LCE-2013 and the email
thread started by Tomasz few months ago [1], here is a first attempt
to introduce:
- a schema language to define the bindings accurately
- DTS validation during device tree compilation in DTC itself


Sorry, this is probably going to sound a bit negative. Hopefully you
find it constructive though.


Well, I hope so too, let's see at the end of the email :-)


The syntax for a schema is the same as the one for dts. This choice has
been made to simplify its development, to maximize the code reuse and
finally because the format is human-readable.


I'm not convinced that's a good decision.


Me neither :-), but I gave the current rational...


DT is a language for representing data.

The validation checks described by schemas are rules, or code, and not
static data.


I will not be that strict with what DTS is supposed to do. In that 
aspect DTS is just a way to represent information in a structured 
hierarchical way.
It is for my point of view no different than XML. I know that everybody 
hate XML, including me, but that shows at least what is doable with such 
language. The fact that we like it or not is a different topic.



So, while I'm sure it's possible to shoe-horn at least some reasonable
subset of DT validation into DT syntax itself, I feel it's unlikely to
yield something that's scalable enough.


I don't think we have any limit with such representation. My concern 
will be more the readability.
To be honest, a language choice is by nature completely subjective, and 
nobody will have the same taste. So we can spend weeks arguing about 
that :-)



For example, it's easy to specify that a property must be 2 cells long.
What if it could be any multiple of two? That's a lot of numbers to
explicitly enumerate as data. Sure, you can then invent syntax to
represent that specific rule (parameterized by 2), but what about the
next similar-but-different rule? The only approach I can think of to
that is to allow the schema to contain arbitrary expressions, which
would likely need to morph into arbitary statements not just
expressions. Once you're there, I think the schema would be better
represented as a programming language rather than as a data structure
that could have code hooked into it.


Sure, but how many complex cases like that do we have? I guess, we can 
handle all the use-cases required by Rob with the current syntax.
Let's assume we cover 99% of the use-cases with such language, do we 
really want to have a super complex language just for the corner cases?


Potentially, writing a C extension to DTC is still possible for that 
specific case.


Not ideal, I do agree, but we have to be pragmatic as well.

We really need to understand how scalable we have to be before deciding 
that the current representation is not good enough.



How to:
  * Associate a schema to one or several nodes

As said earlier a schema can be used to validate one or several nodes
from a dts. To do this the compatible properties from the nodes which
should be validated must be present in the schema.

timer1: timer@4a318000 {
compatible = ti,omap3430-timer;

...

To write a schema which will validate OMAP Timers like the one above,
one may write the following schema:

/dts-v1/;
/ {
compatible = ti,omap[0-9]+-timer;


What about DT nodes that don't have a compatible value? We certainly
have some of those already like /memory and /chosen. We should be able
to validate their schema too. This probably doesn't invalidate being
able to look things up by compatible value though; it just means we need
some additional mechanisms too.


Yes, that's a good point and easy to add as well.


  * Define constraints on properties

To define constraints on a property one has to create a node in a schema
which has as name the name of the property that one want to validate.

To specify constraints on the property ti,hwmods of OMAP Timers one
can write this schema:

/dts-v1/;
/ {
compatible = ti,omap[0-9]+-timer;
ti,hwmods {
...
};


compatible and ti,hwmods are both properties in the DT file. However, in
the schema above, one appears as a property, and one as a node. I don't
like that inconsistency. It'd be better if compatible was a node too.


That's already possible, you can check the timer.schema. The point is to 
simplify the representation for simple case and use a attribute instead 
of a node. But that will make 2 different representation for the same 
case, which might not be that good.



If one want to use a regular as property name one can write this schema:

/dts-v1/;
/ {
compatible = abc;
def {
name = def[0-9];


Isn't it valid to have

Re: [PATCH v2 0/9] ARM: dts: DT data for OMAP platforms for v3.13

2013-10-03 Thread Benoit Cousson

+ DT list and DT maintainers.

Hi Joel,

Thanks for the update. It looks good to me.

For the new bindings added below;

   .../devicetree/bindings/crypto/omap-aes.txt| 34 ++
   .../devicetree/bindings/crypto/omap-sham.txt   | 31 +

I will need the acked-by from one of the DT maintainers.

Regards,
Benoit

On 30/09/2013 17:12, Joel Fernandes wrote:

Following series is a collection of dts patches for the below features:
crypto:
  aes, sha on am335x
  aes, des on am437x
  aes, des on omap4
display:
   beaglebone black HDMI
   am335x-evm panel

Series is based on Benoit Cousson's for_3.13/dts branch (commit sha 45646cd)
Available at: g...@github.com:joelagnel/linux-kernel.git (branch for-benoit)

v2 changes:
  - Fixed hex capitalization
  - Dropped interrupt-parent property and use macros

Benoit Parrot (1):
   ARM: dts: AM33XX: Add LCDC info into am335x-evm

Darren Etheridge (1):
   dts: boneblack: add pinmux and hdmi node to enable display

Joel Fernandes (5):
   omap4: dts: Add node for AES
   omap4: dts: Add node for DES3DES module
   am33xx: dts: Fix AES interrupt number
   ARM: am437x: dts: Add AES node for am437x
   ARM: am437x: dts: Add DES node for am437x

Mark A. Greer (2):
   ARM: dts: Add SHAM data and documentation for AM33XX
   ARM: dts: Add AES data and documentation for AM33XX

  .../devicetree/bindings/crypto/omap-aes.txt| 34 ++
  .../devicetree/bindings/crypto/omap-sham.txt   | 31 +
  arch/arm/boot/dts/am335x-bone.dts  |  8 +++
  arch/arm/boot/dts/am335x-boneblack.dts | 48 +
  arch/arm/boot/dts/am335x-evm.dts   | 79 ++
  arch/arm/boot/dts/am335x-evmsk.dts |  8 +++
  arch/arm/boot/dts/am33xx.dtsi  | 28 
  arch/arm/boot/dts/am4372.dtsi  | 14 
  arch/arm/boot/dts/omap4.dtsi   | 18 +
  9 files changed, 268 insertions(+)
  create mode 100644 Documentation/devicetree/bindings/crypto/omap-aes.txt
  create mode 100644 Documentation/devicetree/bindings/crypto/omap-sham.txt



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


Re: [PATCH] ARM: DTS: DRA7: Add TPS659038 PMIC nodes

2013-10-03 Thread Benoit Cousson
-always-on;
 +regulator-boot-on;
 +};
 +
 +ldousb_reg: ldousb {
 +/* VDDA_3V_USB: VDDA_USBHS33 */
 +regulator-name = ldousb;
 +regulator-min-microvolt = 330;
 +regulator-max-microvolt = 330;
 +regulator-boot-on;
 +};
 +

Nit: Extra blank line not needed.

 +};
 +};
 +};
   };

Nit: You have an extra level on indentation not needed.

   i2c2 {

 Acked-by: Nishanth Menon n...@ti.com

Beside the two minors nits, the patch looks good to me.

Since, you've been waiting for some time for it, I fixed it myself and pulled 
it.
I even fixed the changelog... Lucky you :-)

You can check the updated version below.

Sorry for the delay.

Thanks,
Benoit

---
From 3b8f02a2df475c7a48e12eb1911c014f8060b167 Mon Sep 17 00:00:00 2001
From: Keerthy j-keer...@ti.com
Date: Mon, 26 Aug 2013 11:06:51 +0530
Subject: [PATCH] ARM: DTS: DRA7: Add TPS659038 PMIC nodes

Add DT nodes for TPS659038 PMIC on DRA7 boards.

It is based on top of:
http://comments.gmane.org/gmane.linux.ports.arm.omap/102459.

Documentation:
- Documentation/devicetree/bindings/mfd/palmas.txt
- Documentation/devicetree/bindings/regulator/palmas-pmic.txt

Boot Tested on DRA7 d1 Board.

Signed-off-by: Keerthy j-keer...@ti.com
Acked-by: Nishanth Menon n...@ti.com
[bcous...@baylibre.com: Fix indentation and changelog]
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 arch/arm/boot/dts/dra7-evm.dts | 112 +
 1 file changed, 112 insertions(+)

diff --git a/arch/arm/boot/dts/dra7-evm.dts b/arch/arm/boot/dts/dra7-evm.dts
index ca5dab2..fbbe406 100644
--- a/arch/arm/boot/dts/dra7-evm.dts
+++ b/arch/arm/boot/dts/dra7-evm.dts
@@ -93,6 +93,118 @@
pinctrl-names = default;
pinctrl-0 = i2c1_pins;
clock-frequency = 40;
+
+   tps659038: tps659038@58 {
+   compatible = ti,tps659038;
+   reg = 0x58;
+
+   tps659038_pmic {
+   compatible = ti,tps659038-pmic;
+
+   regulators {
+   smps123_reg: smps123 {
+   /* VDD_MPU */
+   regulator-name = smps123;
+   regulator-min-microvolt =  85;
+   regulator-max-microvolt = 125;
+   regulator-always-on;
+   regulator-boot-on;
+   };
+
+   smps45_reg: smps45 {
+   /* VDD_DSPEVE */
+   regulator-name = smps45;
+   regulator-min-microvolt =  85;
+   regulator-max-microvolt = 115;
+   regulator-boot-on;
+   };
+
+   smps6_reg: smps6 {
+   /* VDD_GPU - over VDD_SMPS6 */
+   regulator-name = smps6;
+   regulator-min-microvolt = 85;
+   regulator-max-microvolt = 1250;
+   regulator-boot-on;
+   };
+
+   smps7_reg: smps7 {
+   /* CORE_VDD */
+   regulator-name = smps7;
+   regulator-min-microvolt = 85;
+   regulator-max-microvolt = 103;
+   regulator-always-on;
+   regulator-boot-on;
+   };
+
+   smps8_reg: smps8 {
+   /* VDD_IVAHD */
+   regulator-name = smps8;
+   regulator-min-microvolt =  85;
+   regulator-max-microvolt = 125;
+   regulator-boot-on;
+   };
+
+   smps9_reg: smps9 {
+   /* VDDS1V8 */
+   regulator-name = smps9;
+   regulator-min-microvolt = 180;
+   regulator-max-microvolt = 180;
+   regulator-always-on;
+   regulator-boot-on;
+   };
+
+   ldo1_reg: ldo1

Re: [PATCH v3 05/10] ARM: dts: omap3-beagle: Use reset-gpios for hsusb2_reset

2013-10-03 Thread Benoit Cousson

On 03/10/2013 14:05, Benoit Cousson wrote:

Hi Roger,

Yes, I will. I've been waiting for these ones for so long :-)


In fact it does not apply correctly on my for_3.13/dts branch :-(

error: arch/arm/boot/dts/omap3-beagle.dts: patch does not apply
Patch failed at 0004 ARM: dts: omap3-beagle: Make USB host pin naming 
consistent


Could you rebase it?

Thanks,
Benoit




Thanks,
Benoit

On 03/10/2013 12:34, Roger Quadros wrote:

Hi Benoit,

Could you please take the device tree related patches [5 to 10] in
this series?
Thanks.

cheers,
-roger

On 09/24/2013 11:53 AM, Roger Quadros wrote:

We no longer need to model the RESET line as a regulator since
the USB phy-nop driver accepts reset-gpios property.

Signed-off-by: Roger Quadros rog...@ti.com
---
  arch/arm/boot/dts/omap3-beagle.dts |   13 +
  1 files changed, 1 insertions(+), 12 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-beagle.dts
b/arch/arm/boot/dts/omap3-beagle.dts
index dfd8310..71bde47 100644
--- a/arch/arm/boot/dts/omap3-beagle.dts
+++ b/arch/arm/boot/dts/omap3-beagle.dts
@@ -44,17 +44,6 @@
  };
  };

-/* HS USB Port 2 RESET */
-hsusb2_reset: hsusb2_reset_reg {
-compatible = regulator-fixed;
-regulator-name = hsusb2_reset;
-regulator-min-microvolt = 330;
-regulator-max-microvolt = 330;
-gpio = gpio5 19 0;/* gpio_147 */
-startup-delay-us = 7;
-enable-active-high;
-};
-
  /* HS USB Port 2 Power */
  hsusb2_power: hsusb2_power_reg {
  compatible = regulator-fixed;
@@ -68,7 +57,7 @@
  /* HS USB Host PHY on PORT 2 */
  hsusb2_phy: hsusb2_phy {
  compatible = usb-nop-xceiv;
-reset-supply = hsusb2_reset;
+reset-gpios = gpio5 19 GPIO_ACTIVE_LOW;/* gpio_147 */
  vcc-supply = hsusb2_power;
  };








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


Re: [RFC 00/15] Device Tree schemas and validation

2013-10-03 Thread Benoit Cousson

Hi David,

On 02/10/2013 16:29, David Gibson wrote:

On Tue, Oct 01, 2013 at 04:22:24PM -0600, Stephen Warren wrote:

On 09/24/2013 10:52 AM, Benoit Cousson wrote:

Hi All,

Following the discussion that happened during LCE-2013 and the email
thread started by Tomasz few months ago [1], here is a first attempt
to introduce:
- a schema language to define the bindings accurately
- DTS validation during device tree compilation in DTC itself


Sorry, this is probably going to sound a bit negative. Hopefully you
find it constructive though.


The syntax for a schema is the same as the one for dts. This choice has
been made to simplify its development, to maximize the code reuse and
finally because the format is human-readable.


I'm not convinced that's a good decision.

DT is a language for representing data.

The validation checks described by schemas are rules, or code, and not
static data.

So, while I'm sure it's possible to shoe-horn at least some reasonable
subset of DT validation into DT syntax itself, I feel it's unlikely to
yield something that's scalable enough.


I tend to agree.


For example, it's easy to specify that a property must be 2 cells long.
What if it could be any multiple of two? That's a lot of numbers to
explicitly enumerate as data. Sure, you can then invent syntax to
represent that specific rule (parameterized by 2), but what about the
next similar-but-different rule? The only approach I can think of to
that is to allow the schema to contain arbitrary expressions, which
would likely need to morph into arbitary statements not just
expressions. Once you're there, I think the schema would be better
represented as a programming language rather than as a data structure
that could have code hooked into it.


How to:
  * Associate a schema to one or several nodes

As said earlier a schema can be used to validate one or several nodes
from a dts. To do this the compatible properties from the nodes which
should be validated must be present in the schema.

timer1: timer@4a318000 {
compatible = ti,omap3430-timer;

...

To write a schema which will validate OMAP Timers like the one above,
one may write the following schema:

/dts-v1/;
/ {
compatible = ti,omap[0-9]+-timer;


What about DT nodes that don't have a compatible value? We certainly
have some of those already like /memory and /chosen. We should be able
to validate their schema too. This probably doesn't invalidate being
able to look things up by compatible value though; it just means we need
some additional mechanisms too.


More to the point, what about the properties of a node whose format is
defined not by this node's binding but by some other nodes binding.
e.g. the exact format of reg and ranges is at least partially
determined by the parent bus's binding, and interrupts is defined
partially by the interrupt parent's binding.  gpio properties are
defined by a combination of a global binding and the gpio parent,
IIRC.


Yeah, that's a general concern that Stephen raised several time as well.
We need to figure out some way to handle that.


  * Define constraints on properties

To define constraints on a property one has to create a node in a schema
which has as name the name of the property that one want to validate.

To specify constraints on the property ti,hwmods of OMAP Timers one
can write this schema:

/dts-v1/;
/ {
compatible = ti,omap[0-9]+-timer;
ti,hwmods {
...
};


compatible and ti,hwmods are both properties in the DT file. However, in
the schema above, one appears as a property, and one as a node. I don't
like that inconsistency. It'd be better if compatible was a node too.


Essentially what's going on here is that to describe the constraint on
a property, a node with corresponding name is defined to encode the
parameters of that constraint.  It kind of works, but it's forced.  It
also hits problems since nodes and properties are technically in
different namespaces, although they rarely collide in real cases.


OK, so would you suggest keeping mapping between node / attribute in DTS 
and in the schema?



If one want to use a regular as property name one can write this schema:

/dts-v1/;
/ {
compatible = abc;
def {
name = def[0-9];


Isn't it valid to have a property named name within the node itself?
How do you differentiate between specifying the node name and the name
property?


Or to look at it another way, how do you differentiate between nodes
representing encoded constraints for a property, and nodes
representing nodes directly.


What if the node name needs more validation than just a regex. For
example, suppose we want to validate the
unit-name-must-match-reg-address rule. We need to write some complex
expression using data extracted from reg to calculate the unit address.
Equally, the node name

Re: [PATCH v3 05/10] ARM: dts: omap3-beagle: Use reset-gpios for hsusb2_reset

2013-10-03 Thread Benoit Cousson

On 03/10/2013 15:58, Roger Quadros wrote:

Hi Benoit,

On 10/03/2013 04:44 PM, Benoit Cousson wrote:

On 03/10/2013 14:05, Benoit Cousson wrote:

Hi Roger,

Yes, I will. I've been waiting for these ones for so long :-)


In fact it does not apply correctly on my for_3.13/dts branch :-(

error: arch/arm/boot/dts/omap3-beagle.dts: patch does not apply
Patch failed at 0004 ARM: dts: omap3-beagle: Make USB host pin naming consistent

Could you rebase it?


Looks like it was already applied before. Could you please skip that and use 
the rest?
I've checked that the remaining patches apply fine on top of your for_3.13/dts
branch.


Indeed, it was already there :-)

Sorry for the noise.

Benoit



cheers,
-roger



On 03/10/2013 12:34, Roger Quadros wrote:

Hi Benoit,

Could you please take the device tree related patches [5 to 10] in
this series?
Thanks.

cheers,
-roger

On 09/24/2013 11:53 AM, Roger Quadros wrote:

We no longer need to model the RESET line as a regulator since
the USB phy-nop driver accepts reset-gpios property.

Signed-off-by: Roger Quadros rog...@ti.com
---
   arch/arm/boot/dts/omap3-beagle.dts |   13 +
   1 files changed, 1 insertions(+), 12 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-beagle.dts
b/arch/arm/boot/dts/omap3-beagle.dts
index dfd8310..71bde47 100644
--- a/arch/arm/boot/dts/omap3-beagle.dts
+++ b/arch/arm/boot/dts/omap3-beagle.dts
@@ -44,17 +44,6 @@
   };
   };

-/* HS USB Port 2 RESET */
-hsusb2_reset: hsusb2_reset_reg {
-compatible = regulator-fixed;
-regulator-name = hsusb2_reset;
-regulator-min-microvolt = 330;
-regulator-max-microvolt = 330;
-gpio = gpio5 19 0;/* gpio_147 */
-startup-delay-us = 7;
-enable-active-high;
-};
-
   /* HS USB Port 2 Power */
   hsusb2_power: hsusb2_power_reg {
   compatible = regulator-fixed;
@@ -68,7 +57,7 @@
   /* HS USB Host PHY on PORT 2 */
   hsusb2_phy: hsusb2_phy {
   compatible = usb-nop-xceiv;
-reset-supply = hsusb2_reset;
+reset-gpios = gpio5 19 GPIO_ACTIVE_LOW;/* gpio_147 */
   vcc-supply = hsusb2_power;
   };












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


Re: [RFC 00/15] Device Tree schemas and validation

2013-10-02 Thread Benoit Cousson

Hi Jon,

On 01/10/2013 17:17, Jon Loeliger wrote:

Hi Rob,

On 01/10/2013 15:17, Rob Herring wrote:

On 10/01/2013 03:06 AM, Benoit Cousson wrote:

+ more DT maintainers folks

Hi all,

I know this is mostly boring user space code, but I was expecting a
little bit of comments about at least the bindings syntax:-(

I'd like to know if this is the right direction and if it worth pursuing
in that direction.

The idea was to have at least some base for further discussion during
ARM KS 2013.

I feel alone :-(

If you have any comment, go ahead!



Benoit,

Sorry, I meant to ask earlier but forgot.
Shouldn't this development be based on the
upstream DTC repository and not the in-kernel
copy of the DTC?


Eventually, yes, but here the main point is to discuss the schema that 
will be used to defined bindings.
In that case, the DTC patches code are mostly a proof of concept using 
the Linux kernel as example.


Regards,
Benoit

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


Re: [RFC 00/15] Device Tree schemas and validation

2013-10-01 Thread Benoit Cousson

+ more DT maintainers folks

Hi all,

I know this is mostly boring user space code, but I was expecting a 
little bit of comments about at least the bindings syntax:-(


I'd like to know if this is the right direction and if it worth pursuing 
in that direction.


The idea was to have at least some base for further discussion during 
ARM KS 2013.


I feel alone :-(

If you have any comment, go ahead!

Thanks,
Benoit

On 24/09/2013 18:52, Benoit Cousson wrote:

Hi All,

Following the discussion that happened during LCE-2013 and the email
thread started by Tomasz few months ago [1], here is a first attempt
to introduce:
- a schema language to define the bindings accurately
- DTS validation during device tree compilation in DTC itself

[1] http://www.spinics.net/lists/arm-kernel/msg262224.html


=== What it does? ===

For now device-tree bindings are defined in a not standardized
text-based format and thus any one can write the documentation for a
binding as he wish. In addition to this there is no automated way to
check if a dts is conform to the available bindings.

The goal of this series of patch is to fix this situation by adding a
well defined way to write bindings in a human-readable format. These
bindings will be written through files called schemas.


=== What is a schema? ===

A schema is a file describing the constraints that one or several nodes
of a dts must conform to. Schemas must use the file extension .schema.
A schema can check that:
- A node has a given property
- An array has a valid size
- A node contains the required children.
- A property has the correct type.
- A property has the correct value.

A schema can as well recursively check the constraints for parent nodes.

The syntax for a schema is the same as the one for dts. This choice has
been made to simplify its development, to maximize the code reuse and
finally because the format is human-readable.


=== How to defined a schema? ===

A binding directory has been added at the root of repository. Users can
add schema files anywhere in it but a nice way would be to keep the same
structure as the binding directory in the documentation.

To demonstrate how to write a schema and its capability I will use the
OMAP DTS schemas when applicable.

How to:
  * Associate a schema to one or several nodes

As said earlier a schema can be used to validate one or several nodes
from a dts. To do this the compatible properties from the nodes which
should be validated must be present in the schema.

timer1: timer@4a318000 {
compatible = ti,omap3430-timer;
reg = 0x4a318000 0x80;
interrupts = 0x0 0x25 0x4;
ti,hwmods = timer1;
ti,timer-alwon;
};

To write a schema which will validate OMAP Timers like the one above,
one may write the following schema:

/dts-v1/;
/ {
compatible = ti,omap[0-9]+-timer;
...
};

The schema above will be used to validate every node in a dts which has
a compatible matching the following regular expression:
ti,omap[0-9]+-timer.

It is possible to specify multiple compatible inside a schema using this
syntax:
compatible = ti,omap[0-9]+-timer, ti,am[0-9]+-timer;

This time the schema will be application for both OMAP Timers and AM
Timers.


  * Define constraints on properties

To define constraints on a property one has to create a node in a schema
which has as name the name of the property that one want to validate.

To specify constraints on the property ti,hwmods of OMAP Timers one
can write this schema:

/dts-v1/;
/ {
compatible = ti,omap[0-9]+-timer;
ti,hwmods {
...
};
};

If one want to use a regular as property name one can write this schema:

/dts-v1/;
/ {
compatible = abc;
def {
name = def[0-9];
...
};
};

Above one can see that the name property override the node name.


  * Require the presence of a property

One can require the presence of a property by using the is-required
constraint.

/dts-v1/;
/ {
compatible = ti,omap[0-9]+-timer;
ti,hwmods {
is-required;
};
};

The ti,hwmods property above is set as required and its presence will
be checked in every OMAP timer.


  * Require the presence of a property inside a node or inside one of its
parents

Sometimes a property required is not directly present inside a node but
is present in one of its parents. To check this, one can use
can-be-inherited in addition to is-required.

twl {
 interrupt-controller;

 rtc {
 compatible = ti,twl4030-rtc;
 interrupts = 0xc;
 };
}

In the case of the rtc above the interrupt-controller is not present

Re: [RFC 00/15] Device Tree schemas and validation

2013-10-01 Thread Benoit Cousson

Hi Rob,

On 01/10/2013 15:17, Rob Herring wrote:

On 10/01/2013 03:06 AM, Benoit Cousson wrote:

+ more DT maintainers folks

Hi all,

I know this is mostly boring user space code, but I was expecting a
little bit of comments about at least the bindings syntax:-(

I'd like to know if this is the right direction and if it worth pursuing
in that direction.

The idea was to have at least some base for further discussion during
ARM KS 2013.

I feel alone :-(

If you have any comment, go ahead!


Thanks for taking this on!

This is interesting approach using the dts syntax,


Well, this was discussed a little bit on the list, and it has the big 
advantage of re-using the parser already included in DTC for free.
In term or readability, it avoids to re-defining a brand new syntax for 
people who are already familiar with the DTS one.



but I worry that the
validation will only be as good as the schema written and the review of
the schema.


Well, sure, but unfortunately, that will always be the case :-(
The bindings definition being quite open, there is no easy way to ensure 
proper schema / bindings without careful review of the schema. There is 
no such thing as a free beer... Unfortunately :-)



I think the schema needs to define the binding rather than
define the checks. Then the schema can feed the validation checks.



This format does not seem to me as easily being able to generate
documentation from the schema which I believe is one of the goals.


Indeed, but I think is it easy to generate any kind of readable format 
for the documentation purpose if needed from the actual format.
Otherwise, we should consider a schema format based on kerneldoc type of 
syntax to improve readability. I'm just afraid it will become harder 
then to define complex schema.


BTW, what kind of documentation are you expecting here? Is is a text 
that can be added on top of each schema?



I for
one don't care to review the documentation and the schema for every binding.

I would like to ensure we can start with the basics and have some
generic rules. Some examples:

- flag compatible strings in dts files that are not documented


This is almost done with the last patch of the series. Nodes are already 
checked, properties are missing.



- check required properties


Done as well.


- check properties against cell sizes


Yeah, that one is still to be done.


- a node with reg property must have a unit address


Easy to add.


- flag properties with _


Easy to add as well.


- check properties are the correct data type


Already done for a couple of data type.

Thanks for your comments. Being the very first one, you might get a free 
beer... meaning there might be such thing as a free beer :-)


Thanks,
Benoit



Thanks,
Benoit

On 24/09/2013 18:52, Benoit Cousson wrote:

Hi All,

Following the discussion that happened during LCE-2013 and the email
thread started by Tomasz few months ago [1], here is a first attempt
to introduce:
- a schema language to define the bindings accurately
- DTS validation during device tree compilation in DTC itself

[1] http://www.spinics.net/lists/arm-kernel/msg262224.html


=== What it does? ===

For now device-tree bindings are defined in a not standardized
text-based format and thus any one can write the documentation for a
binding as he wish. In addition to this there is no automated way to
check if a dts is conform to the available bindings.

The goal of this series of patch is to fix this situation by adding a
well defined way to write bindings in a human-readable format. These
bindings will be written through files called schemas.


=== What is a schema? ===

A schema is a file describing the constraints that one or several nodes
of a dts must conform to. Schemas must use the file extension .schema.
A schema can check that:
 - A node has a given property
 - An array has a valid size
 - A node contains the required children.
 - A property has the correct type.
 - A property has the correct value.

A schema can as well recursively check the constraints for parent nodes.

The syntax for a schema is the same as the one for dts. This choice has
been made to simplify its development, to maximize the code reuse and
finally because the format is human-readable.


=== How to defined a schema? ===

A binding directory has been added at the root of repository. Users can
add schema files anywhere in it but a nice way would be to keep the same
structure as the binding directory in the documentation.

To demonstrate how to write a schema and its capability I will use the
OMAP DTS schemas when applicable.

How to:
   * Associate a schema to one or several nodes

As said earlier a schema can be used to validate one or several nodes
from a dts. To do this the compatible properties from the nodes which
should be validated must be present in the schema.

 timer1: timer@4a318000 {
 compatible = ti,omap3430-timer;
 reg = 0x4a318000 0x80;
 interrupts = 0x0

Re: [PATCH 0/9] ARM: dts: DT data for OMAP platforms for v3.13

2013-09-26 Thread Benoit Cousson

Hi Joel,

On 26/09/2013 00:01, Joel Fernandes wrote:

Following series is a collection of dts patches for the below features:
crypto:
  aes, sha on am335x
  aes, des on am437x
  aes, des on omap4
display:
   beaglebone black HDMI
   am335x-evm panel

Series is based on Benoit Cousson's for_3.13/dts branch (commit sha 45646cd)
Available at: g...@github.com:joelagnel/linux-kernel.git (branch for-benoit)


Thanks for the update and rebase.

I'll check the series ASAP.

Thanks,
Benoit



Benoit Parrot (1):
   ARM: dts: AM33XX: Add LCDC info into am335x-evm

Darren Etheridge (1):
   dts: boneblack: add pinmux and hdmi node to enable display

Joel Fernandes (5):
   omap4: dts: Add node for AES
   omap4: dts: Add node for DES3DES module
   am33xx: dts: Fix AES interrupt number
   ARM: am437x: dts: Add AES node for am437x
   ARM: am437x: dts: Add DES node for am437x

Mark A. Greer (2):
   ARM: dts: Add SHAM data and documentation for AM33XX
   ARM: dts: Add AES data and documentation for AM33XX

  .../devicetree/bindings/crypto/omap-aes.txt| 34 ++
  .../devicetree/bindings/crypto/omap-sham.txt   | 31 +
  arch/arm/boot/dts/am335x-bone.dts  |  8 +++
  arch/arm/boot/dts/am335x-boneblack.dts | 48 +
  arch/arm/boot/dts/am335x-evm.dts   | 79 ++
  arch/arm/boot/dts/am335x-evmsk.dts |  8 +++
  arch/arm/boot/dts/am33xx.dtsi  | 30 
  arch/arm/boot/dts/am4372.dtsi  | 16 +
  arch/arm/boot/dts/omap4.dtsi   | 20 ++
  9 files changed, 274 insertions(+)
  create mode 100644 Documentation/devicetree/bindings/crypto/omap-aes.txt
  create mode 100644 Documentation/devicetree/bindings/crypto/omap-sham.txt



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


Re: [PATCH 1/9] omap4: dts: Add node for AES

2013-09-26 Thread Benoit Cousson

On 26/09/2013 00:01, Joel Fernandes wrote:

OMAP4 has an AES module that uses the omap-aes crypto driver.
Add DT entries for the same.

Signed-off-by: Joel Fernandes jo...@ti.com
---
  arch/arm/boot/dts/omap4.dtsi | 10 ++
  1 file changed, 10 insertions(+)

diff --git a/arch/arm/boot/dts/omap4.dtsi b/arch/arm/boot/dts/omap4.dtsi
index 45708e1..4267a74 100644
--- a/arch/arm/boot/dts/omap4.dtsi
+++ b/arch/arm/boot/dts/omap4.dtsi
@@ -663,5 +663,15 @@
ram-bits = 12;
ti,has-mailbox;
};
+
+   aes: aes@4B501000 {
+   compatible = ti,omap4-aes;
+   ti,hwmods = aes;
+   reg = 0x4B501000 0xa0;


Nit: Please use lower case for hexa value.


+   interrupt-parent = gic;


You don't have to add the interrupt-parent, it is already set by default 
at the root of the tree.


We did not add it for most nodes. Some are still there becasue I missed 
them during the review :-)



+   interrupts = 0 85 0x4;


For interrupt, you should use the macros now for better readability.

 +  interrupts = GIC_SPI 85 IRQ_TYPE_LEVEL_HIGH;

Regards,
Benoit


+   dmas = sdma 111, sdma 110;
+   dma-names = tx, rx;
+   };
};
  };



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


Re: [PATCH] ARM: DTS: omap3-devkit8000.dts: fix a typo

2013-09-24 Thread Benoit Cousson

Hi Aaro,

On 21/09/2013 01:40, Aaro Koskinen wrote:

gpmc,sync-clki-ps is not defined/documented, it should be
gpmc,sync-clk-ps instead.


Thanks for the fix. I've just applied it with a slight change in the 
subject for consistency:


ARM: dts: omap3-devkit8000: fix a typo in GMPC node

Regards,
Benoit



Signed-off-by: Aaro Koskinen aaro.koski...@iki.fi
---
  arch/arm/boot/dts/omap3-devkit8000.dts | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/omap3-devkit8000.dts 
b/arch/arm/boot/dts/omap3-devkit8000.dts
index 7ef2827..4665421 100644
--- a/arch/arm/boot/dts/omap3-devkit8000.dts
+++ b/arch/arm/boot/dts/omap3-devkit8000.dts
@@ -125,7 +125,7 @@
nand-bus-width = 16;

gpmc,device-nand;
-   gpmc,sync-clki-ps = 0;
+   gpmc,sync-clk-ps = 0;
gpmc,cs-on-ns = 0;
gpmc,cs-rd-off-ns = 44;
gpmc,cs-wr-off-ns = 44;



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


Re: [PATCH 2/2] ARM: dts: dra7-evm: Add mmc2 node for eMMC support

2013-09-24 Thread Benoit Cousson

+ Sekhar

Hi Balaji,

On 26/08/2013 15:53, Balaji T K wrote:

Add mmc2 dt node to dra7-evm board
and model eMMC vcc as fixed regulator.

Signed-off-by: Balaji T K balaj...@ti.com
---
  arch/arm/boot/dts/dra7-evm.dts |   14 ++
  1 files changed, 14 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/dra7-evm.dts b/arch/arm/boot/dts/dra7-evm.dts
index a59bbd0..2062724 100644
--- a/arch/arm/boot/dts/dra7-evm.dts
+++ b/arch/arm/boot/dts/dra7-evm.dts
@@ -17,6 +17,13 @@
device_type = memory;
reg = 0x8000 0x6000; /* 1536 MB */
};
+
+   mmc2_3v3: fixedregulator-mmc2 {
+   compatible = regulator-fixed;
+   regulator-name = mmc2_3v3;
+   regulator-min-microvolt = 330;
+   regulator-max-microvolt = 330;
+   };
  };

  dra7_pmx_core {
@@ -257,3 +264,10 @@
vmmc-supply = ldo1_reg;
bus-width = 4;
  };
+
+mmc2 {
+   status = okay;
+   vmmc-supply = mmc2_3v3;
+   bus-width = 8;
+   ti,non-removable;


Sekhar just posted a series to replace that with a non-TI attribute: 
non-removable.


I'm not sure if this got merged, but it might be good to use the 
standard attribute instead.


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


[RFC 00/15] Device Tree schemas and validation

2013-09-24 Thread Benoit Cousson
Hi All,

Following the discussion that happened during LCE-2013 and the email
thread started by Tomasz few months ago [1], here is a first attempt
to introduce:
- a schema language to define the bindings accurately
- DTS validation during device tree compilation in DTC itself

[1] http://www.spinics.net/lists/arm-kernel/msg262224.html


=== What it does? ===

For now device-tree bindings are defined in a not standardized
text-based format and thus any one can write the documentation for a
binding as he wish. In addition to this there is no automated way to
check if a dts is conform to the available bindings.

The goal of this series of patch is to fix this situation by adding a
well defined way to write bindings in a human-readable format. These
bindings will be written through files called schemas.


=== What is a schema? ===

A schema is a file describing the constraints that one or several nodes
of a dts must conform to. Schemas must use the file extension .schema.
A schema can check that:
- A node has a given property
- An array has a valid size
- A node contains the required children.
- A property has the correct type.
- A property has the correct value.

A schema can as well recursively check the constraints for parent nodes.

The syntax for a schema is the same as the one for dts. This choice has
been made to simplify its development, to maximize the code reuse and
finally because the format is human-readable.


=== How to defined a schema? ===

A binding directory has been added at the root of repository. Users can
add schema files anywhere in it but a nice way would be to keep the same
structure as the binding directory in the documentation.

To demonstrate how to write a schema and its capability I will use the
OMAP DTS schemas when applicable.

How to:
 * Associate a schema to one or several nodes

As said earlier a schema can be used to validate one or several nodes
from a dts. To do this the compatible properties from the nodes which
should be validated must be present in the schema.

timer1: timer@4a318000 {
compatible = ti,omap3430-timer;
reg = 0x4a318000 0x80;
interrupts = 0x0 0x25 0x4;
ti,hwmods = timer1;
ti,timer-alwon;
};

To write a schema which will validate OMAP Timers like the one above,
one may write the following schema:

/dts-v1/;
/ {
compatible = ti,omap[0-9]+-timer;
...
};

The schema above will be used to validate every node in a dts which has
a compatible matching the following regular expression:
ti,omap[0-9]+-timer.

It is possible to specify multiple compatible inside a schema using this
syntax:
compatible = ti,omap[0-9]+-timer, ti,am[0-9]+-timer;

This time the schema will be application for both OMAP Timers and AM
Timers.


 * Define constraints on properties

To define constraints on a property one has to create a node in a schema
which has as name the name of the property that one want to validate.

To specify constraints on the property ti,hwmods of OMAP Timers one
can write this schema:

/dts-v1/;
/ {
compatible = ti,omap[0-9]+-timer;
ti,hwmods {
...
};
};

If one want to use a regular as property name one can write this schema:

/dts-v1/;
/ {
compatible = abc;
def {
name = def[0-9];
...
};
};

Above one can see that the name property override the node name.


 * Require the presence of a property

One can require the presence of a property by using the is-required
constraint.

/dts-v1/;
/ {
compatible = ti,omap[0-9]+-timer;
ti,hwmods {
is-required;
};
};

The ti,hwmods property above is set as required and its presence will
be checked in every OMAP timer.


 * Require the presence of a property inside a node or inside one of its
parents

Sometimes a property required is not directly present inside a node but
is present in one of its parents. To check this, one can use
can-be-inherited in addition to is-required.

twl {
interrupt-controller;

rtc {
compatible = ti,twl4030-rtc;
interrupts = 0xc;
};
}

In the case of the rtc above the interrupt-controller is not present,
but it is present in its parent. If inheriting the property from the
parent makes senses like here one can specify in the schema that
interrupt-controller is required in the rtc node and that the property
can be inherited from a parent.

/dts-v1/;
/ {
compatible = ti,twl[0-9]+-rtc;
interrupt-controller {
is-required;
can-be-inherited;
};
};


 * Require a node to contains a given list of children

One may want to check if a node has some 

[RFC 03/15] scripts/dtc: validate each nodes and properties

2013-09-24 Thread Benoit Cousson
From: Fabien Parent fpar...@baylibre.com

Add support to navigate through the device tree and try to validate each node
which has an associated schema in the schema index. So far, only the framework
is added and no validation is really done yet.

Signed-off-by: Fabien Parent fpar...@baylibre.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 scripts/dtc/schema.c | 234 ++-
 1 file changed, 233 insertions(+), 1 deletion(-)

diff --git a/scripts/dtc/schema.c b/scripts/dtc/schema.c
index dd134d6..a797821 100644
--- a/scripts/dtc/schema.c
+++ b/scripts/dtc/schema.c
@@ -9,9 +9,21 @@ static const char *const SCHEMA_EXT = .schema;
 static const char *const VALUE_PROPNAME = value;
 static int exit_on_failure = 0;
 
+struct node_list {
+   struct node *n;
+   struct node_list *next;
+};
+
+struct prop_constraints {
+   const char *name;
+};
+
 struct node_constraints {
pcre *re_compat;
char *filepath;
+   struct boot_info *bi;
+   struct node *dt;
+
const char *compatible;
 };
 
@@ -54,6 +66,34 @@ static int get_next_string_offset(struct property *p, int 
offset)
return -1;
 }
 
+static struct property *get_property_matching_pattern(struct property **list,
+ const char *pattern)
+{
+   struct property *p;
+   pcre *re;
+   int is_matching;
+
+   assert(list);
+   assert(pattern);
+
+   re = compile_pattern(pattern);
+   if (!re)
+   die(Invalid pattern: %s\n, pattern);
+
+   for (p = *list; p; p = p-next) {
+   assert(p-name);
+   is_matching = pcre_exec(re, 0, p-name, strlen(p-name),
+   0, 0, NULL, 0) = 0;
+   if (is_matching) {
+   *list = p-next;
+   break;
+   }
+   }
+
+   pcre_free(re);
+   return p;
+}
+
 static int is_prop_value(const char *p)
 {
int is_value = 1;
@@ -70,12 +110,203 @@ static int is_prop_value(const char *p)
 
 /** Schema Validation */
 
+static void free_property_constraints(struct prop_constraints *pc)
+{
+   if (!pc)
+   return;
+
+   free(pc);
+}
+
+static struct prop_constraints*
+load_property_constraints(struct node *schema)
+{
+   struct property *p;
+   struct prop_constraints *pc;
+
+   assert(schema);
+
+   pc = xmalloc(sizeof(*pc));
+   memset(pc, 0, sizeof(*pc));
+
+   p = get_property(schema, name);
+   if (p)
+   pc-name = p-val.val;
+
+   return pc;
+}
+
+static int validate_properties(struct node *n,
+  struct node *schema,
+  struct node_list *path);
+
+static int validate_property(struct node *n,
+struct property *p,
+struct prop_constraints *pc,
+struct node *schema,
+struct node_list *path)
+{
+   int ret = 1;
+
+   assert(n);
+   assert(schema);
+   assert(pc);
+   assert(path);
+
+   free_property_constraints(pc);
+   return ret;
+}
+
+static int validate_properties(struct node *n,
+  struct node *schema,
+  struct node_list *path)
+{
+   struct property *p;
+   struct property *iter;
+   struct prop_constraints *pc;
+   int ret = 1;
+
+   assert(n);
+   assert(schema);
+   assert(path);
+
+   pc = load_property_constraints(schema);
+   assert(pc);
+
+   iter = n-proplist;
+   p = get_property_matching_pattern(iter, pc-name ?: schema-name);
+   ret = validate_property(n, p, pc, schema, path);
+
+   /* if other properties match the pattern */
+   while (iter  p) {
+   p = get_property_matching_pattern(iter, schema-name);
+   if (p)
+   ret = validate_property(n, p, pc, schema, path);
+   else
+   break;
+   }
+
+   return ret;
+}
+
+static int validate_node(struct node *n,
+struct node_constraints *nc,
+struct node_list *path)
+{
+   struct node *iter;
+   int ret = 1;
+
+   assert(n);
+   assert(path);
+   assert(nc);
+   assert(nc-dt);
+
+   for (iter = nc-dt-children; iter; iter = iter-next_sibling)
+   ret = validate_properties(n, iter, path);
+
+   return ret;
+}
+
+static struct node_constraints *get_node_constraints_of(struct schema_db *db,
+   const char *compat,
+   int *i)
+{
+   int has_match;
+   struct node_constraints *n;
+
+   assert(db);
+   assert(compat);
+   assert(i);
+
+   for (; *i  db-size; (*i)++) {
+   n = db-buffer[*i

[RFC 01/15] scripts/dtc: fix most memory leaks in dtc

2013-09-24 Thread Benoit Cousson
From: Fabien Parent fpar...@baylibre.com

There are a few memory leaks in dtc which until now were not that important
since they were all in the parser and only one instance of the parser was run
per instance of dtc. The following commits will add a validation of dts through
schema which have the same syntax as dts, i.e. the parser of dts will be reused
to parse schema. The consequence is that instead of having the parser running
only one time for an instance of the dtc process, the parser will run
many many times and thus the leak that were not important until now becomes
urgent to fix.

dtc-lexer: Do not duplicate the string which contains literals because the
string is directly converted afterward to an integer and is never used again.
livetree: Add a bunch of free helper functions to clean properly the dt.

Signed-off-by: Fabien Parent fpar...@baylibre.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 scripts/dtc/dtc-lexer.l |   2 +-
 scripts/dtc/dtc-lexer.lex.c_shipped |   2 +-
 scripts/dtc/dtc.c   |   1 +
 scripts/dtc/dtc.h   |   1 +
 scripts/dtc/livetree.c  | 108 +---
 5 files changed, 105 insertions(+), 9 deletions(-)

diff --git a/scripts/dtc/dtc-lexer.l b/scripts/dtc/dtc-lexer.l
index 3b41bfc..4f63fbf 100644
--- a/scripts/dtc/dtc-lexer.l
+++ b/scripts/dtc/dtc-lexer.l
@@ -146,7 +146,7 @@ static int pop_input_file(void);
}
 
 V1([0-9]+|0[xX][0-9a-fA-F]+)(U|L|UL|LL|ULL)? {
-   yylval.literal = xstrdup(yytext);
+   yylval.literal = yytext;
DPRINT(Literal: '%s'\n, yylval.literal);
return DT_LITERAL;
}
diff --git a/scripts/dtc/dtc-lexer.lex.c_shipped 
b/scripts/dtc/dtc-lexer.lex.c_shipped
index 2d30f41..5c0d27c 100644
--- a/scripts/dtc/dtc-lexer.lex.c_shipped
+++ b/scripts/dtc/dtc-lexer.lex.c_shipped
@@ -1054,7 +1054,7 @@ case 10:
 YY_RULE_SETUP
 #line 148 dtc-lexer.l
 {
-   yylval.literal = xstrdup(yytext);
+   yylval.literal = yytext;
DPRINT(Literal: '%s'\n, yylval.literal);
return DT_LITERAL;
}
diff --git a/scripts/dtc/dtc.c b/scripts/dtc/dtc.c
index a375683..215ae92 100644
--- a/scripts/dtc/dtc.c
+++ b/scripts/dtc/dtc.c
@@ -256,5 +256,6 @@ int main(int argc, char *argv[])
die(Unknown output format \%s\\n, outform);
}
 
+   free_dt(bi);
exit(0);
 }
diff --git a/scripts/dtc/dtc.h b/scripts/dtc/dtc.h
index 3e42a07..9c45fd2 100644
--- a/scripts/dtc/dtc.h
+++ b/scripts/dtc/dtc.h
@@ -245,6 +245,7 @@ struct boot_info {
 struct boot_info *build_boot_info(struct reserve_info *reservelist,
  struct node *tree, uint32_t boot_cpuid_phys);
 void sort_tree(struct boot_info *bi);
+void free_dt(struct boot_info *bi);
 
 /* Checks */
 
diff --git a/scripts/dtc/livetree.c b/scripts/dtc/livetree.c
index b61465f..5c8692c 100644
--- a/scripts/dtc/livetree.c
+++ b/scripts/dtc/livetree.c
@@ -20,6 +20,10 @@
 
 #include dtc.h
 
+static void free_node_list(struct node *n);
+static void free_node(struct node *n);
+static void free_property(struct property *p);
+
 /*
  * Tree building functions
  */
@@ -144,7 +148,7 @@ struct node *merge_nodes(struct node *old_node, struct node 
*new_node)
 
/* Add new node labels to old node */
for_each_label_withdel(new_node-labels, l)
-   add_label(old_node-labels, l-label);
+   add_label(old_node-labels, xstrdup(l-label));
 
/* Move properties from the new node to the old node.  If there
 * is a collision, replace the old value with the new */
@@ -156,7 +160,7 @@ struct node *merge_nodes(struct node *old_node, struct node 
*new_node)
 
if (new_prop-deleted) {
delete_property_by_name(old_node, new_prop-name);
-   free(new_prop);
+   free_property(new_prop);
continue;
}
 
@@ -165,7 +169,7 @@ struct node *merge_nodes(struct node *old_node, struct node 
*new_node)
if (streq(old_prop-name, new_prop-name)) {
/* Add new labels to old property */
for_each_label_withdel(new_prop-labels, l)
-   add_label(old_prop-labels, l-label);
+   add_label(old_prop-labels, 
xstrdup(l-label));
 
old_prop-val = new_prop-val;
old_prop-deleted = 0;
@@ -191,7 +195,7 @@ struct node *merge_nodes(struct node *old_node, struct node 
*new_node)
 
if (new_child-deleted) {
delete_node_by_name(old_node, new_child-name);
-   free(new_child);
+   free_node(new_child

[RFC 02/15] scripts/dtc: build schema index for dts validation

2013-09-24 Thread Benoit Cousson
From: Fabien Parent fpar...@baylibre.com

Add the infrastructure for dts validation through schema. The code build
an index of all the schemas found in a path given by the user on the
command line. This index will be used for the validation of a dts, it will be
used to know if a schema exists for a particular node and where to find it.

The association between a node of a dts and a schema is made through the
compatible property of the former.

timer1: timer@4a318000 {
compatible = ti,omap3430-timer;
reg = 0x4a318000 0x80;
interrupts = 0x0 0x25 0x4;
ti,hwmods = timer1;
ti,timer-alwon;
};

A schema for this node would probably be something like this:
/dts-v1/;
/ {
compatible = ti,omap3430-timer;
...
};

The compatible property in the schema is specified through a regular
expression so if the schema must validate timers for every omap device,
something like this would probably be more appropriate:
compatible = ti,omap[0-9]+-timer;

It is possible to specify several compatible in a single schema like this:
compatible = ti,omap3430-timer, ti,omap4430-timer;

The following syntax is also available:
compatible {
description = A small description;
value = ti,omap4430-timer;
};

Signed-off-by: Fabien Parent fpar...@baylibre.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 scripts/dtc/.gitignore|   2 +-
 scripts/dtc/Makefile  |   9 +-
 scripts/dtc/dtc.c |  19 ++-
 scripts/dtc/dtc.h |  11 ++
 scripts/dtc/schema-test.c |  67 +++
 scripts/dtc/schema.c  | 288 ++
 6 files changed, 390 insertions(+), 6 deletions(-)
 create mode 100644 scripts/dtc/schema-test.c
 create mode 100644 scripts/dtc/schema.c

diff --git a/scripts/dtc/.gitignore b/scripts/dtc/.gitignore
index 095acb4..ff556dd 100644
--- a/scripts/dtc/.gitignore
+++ b/scripts/dtc/.gitignore
@@ -2,4 +2,4 @@ dtc
 dtc-lexer.lex.c
 dtc-parser.tab.c
 dtc-parser.tab.h
-
+schema-test
diff --git a/scripts/dtc/Makefile b/scripts/dtc/Makefile
index 2a48022..7da5209 100644
--- a/scripts/dtc/Makefile
+++ b/scripts/dtc/Makefile
@@ -1,15 +1,18 @@
 # scripts/dtc makefile
 
-hostprogs-y:= dtc
+hostprogs-y:= dtc schema-test
 always := $(hostprogs-y)
 
 dtc-objs   := dtc.o flattree.o fstree.o data.o livetree.o treesource.o \
-  srcpos.o checks.o util.o
+  srcpos.o checks.o util.o schema.o
 dtc-objs   += dtc-lexer.lex.o dtc-parser.tab.o
 
+schema-test-objs := $(dtc-objs:dtc.o=) schema-test.o
+
 # Source files need to get at the userspace version of libfdt_env.h to compile
 
 HOSTCFLAGS_DTC := -I$(src) -I$(src)/libfdt
+HOST_LOADLIBES := -lpcre
 
 HOSTCFLAGS_checks.o := $(HOSTCFLAGS_DTC)
 HOSTCFLAGS_data.o := $(HOSTCFLAGS_DTC)
@@ -20,6 +23,8 @@ HOSTCFLAGS_livetree.o := $(HOSTCFLAGS_DTC)
 HOSTCFLAGS_srcpos.o := $(HOSTCFLAGS_DTC)
 HOSTCFLAGS_treesource.o := $(HOSTCFLAGS_DTC)
 HOSTCFLAGS_util.o := $(HOSTCFLAGS_DTC)
+HOSTCFLAGS_schema.o := $(HOSTCFLAGS_DTC)
+HOSTCFLAGS_schema-test.o := $(HOSTCFLAGS_DTC)
 
 HOSTCFLAGS_dtc-lexer.lex.o := $(HOSTCFLAGS_DTC)
 HOSTCFLAGS_dtc-parser.tab.o := $(HOSTCFLAGS_DTC)
diff --git a/scripts/dtc/dtc.c b/scripts/dtc/dtc.c
index 215ae92..a7881f0 100644
--- a/scripts/dtc/dtc.c
+++ b/scripts/dtc/dtc.c
@@ -96,16 +96,21 @@ static void  __attribute__ ((noreturn)) usage(void)
fprintf(stderr, \t-W [no-]checkname\n);
fprintf(stderr, \t-E [no-]checkname\n);
fprintf(stderr, \t\t\tenable or disable warnings and errors\n);
+   fprintf(stderr, \t-M schema folder);
+   fprintf(stderr,
+   \t\tCheck the dts using schemas from the specified folder\n);
exit(3);
 }
 
 int main(int argc, char *argv[])
 {
struct boot_info *bi;
+   struct schema_db *sdb;
const char *inform = dts;
const char *outform = dts;
const char *outname = -;
const char *depname = NULL;
+   const char *schemadir = NULL;
int force = 0, sort = 0;
const char *arg;
int opt;
@@ -118,7 +123,7 @@ int main(int argc, char *argv[])
minsize= 0;
padsize= 0;
 
-   while ((opt = getopt(argc, argv, hI:O:o:V:d:R:S:p:fqb:i:vH:sW:E:))
+   while ((opt = getopt(argc, argv, hI:O:o:V:d:R:S:p:fqb:i:vH:sW:E:M:))
!= EOF) {
switch (opt) {
case 'I':
@@ -130,6 +135,9 @@ int main(int argc, char *argv[])
case 'o':
outname = optarg;
break;
+   case 'M':
+   schemadir = optarg;
+   break;
case 'V':
outversion = strtol(optarg, NULL, 0);
break;
@@ -212,9 +220,14 @@ int main(int argc, char *argv[])
fprintf(depfile, %s:, outname);
}
 
-   if (streq(inform, dts))
+   if (streq(inform, dts)) {
bi

[RFC 15/15] scripts/dtc: add verbose options

2013-09-24 Thread Benoit Cousson
From: Fabien Parent fpar...@baylibre.com

The verbose option '-B' will show additional messages in addition
to all validation errors. Right now the level 0 prints every nodes
which don't have at least one schema associated to it. Level 1
prints every properties which were not validated due to missing
constraints.
Activate the verbose mode by default into the Makefile.

Usage example:
dtc -M ./bindings -B 1 file.dts

A count of errors found so far as also been added and is printed
on each error.

Signed-off-by: Fabien Parent fpar...@baylibre.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 scripts/Makefile.lib |   2 +-
 scripts/dtc/dtc.c|  11 -
 scripts/dtc/dtc.h|   1 +
 scripts/dtc/schema.c | 124 ---
 4 files changed, 118 insertions(+), 20 deletions(-)

diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
index 358dd69..ea1484e 100644
--- a/scripts/Makefile.lib
+++ b/scripts/Makefile.lib
@@ -264,7 +264,7 @@ $(obj)/%.dtb.S: $(obj)/%.dtb
 quiet_cmd_dtc = DTC $@
 cmd_dtc = $(CPP) $(dtc_cpp_flags) -x assembler-with-cpp -o $(dtc-tmp) $ ; \
$(objtree)/scripts/dtc/dtc -O dtb -o $@ -b 0 \
-   -M $(objtree)/bindings \
+   -M $(objtree)/bindings -B 1 \
-i $(dir $) $(DTC_FLAGS) \
-d $(depfile).dtc.tmp $(dtc-tmp) ; \
cat $(depfile).pre.tmp $(depfile).dtc.tmp  $(depfile)
diff --git a/scripts/dtc/dtc.c b/scripts/dtc/dtc.c
index a7881f0..8fee7ca 100644
--- a/scripts/dtc/dtc.c
+++ b/scripts/dtc/dtc.c
@@ -99,6 +99,8 @@ static void  __attribute__ ((noreturn)) usage(void)
fprintf(stderr, \t-M schema folder);
fprintf(stderr,
\t\tCheck the dts using schemas from the specified folder\n);
+   fprintf(stderr, \t-B number\n);
+   fprintf(stderr, \t\tLevel of verbosity from the schema validation\n);
exit(3);
 }
 
@@ -111,7 +113,7 @@ int main(int argc, char *argv[])
const char *outname = -;
const char *depname = NULL;
const char *schemadir = NULL;
-   int force = 0, sort = 0;
+   int force = 0, sort = 0, verbose = 0;
const char *arg;
int opt;
FILE *outf = NULL;
@@ -123,7 +125,7 @@ int main(int argc, char *argv[])
minsize= 0;
padsize= 0;
 
-   while ((opt = getopt(argc, argv, hI:O:o:V:d:R:S:p:fqb:i:vH:sW:E:M:))
+   while ((opt = getopt(argc, argv, hI:O:o:V:d:R:S:p:fqb:i:vH:sW:E:M:B:))
!= EOF) {
switch (opt) {
case 'I':
@@ -192,6 +194,10 @@ int main(int argc, char *argv[])
parse_checks_option(false, true, optarg);
break;
 
+   case 'B':
+   verbose = strtol(optarg, NULL, 0);
+   break;
+
case 'h':
default:
usage();
@@ -223,6 +229,7 @@ int main(int argc, char *argv[])
if (streq(inform, dts)) {
bi = dt_from_source(arg);
if (schemadir) {
+   set_verbosity_level(verbose);
sdb = build_schema_db(schemadir);
validate_dt(sdb, bi);
free_schema_db(sdb);
diff --git a/scripts/dtc/dtc.h b/scripts/dtc/dtc.h
index 64fdc8a..a4731e0 100644
--- a/scripts/dtc/dtc.h
+++ b/scripts/dtc/dtc.h
@@ -293,6 +293,7 @@ int validate_dt(struct schema_db *db, struct boot_info *bi);
 struct schema_db *build_schema_db(const char *dir);
 void free_schema_db(struct schema_db *db);
 void exit_on_schema_validation_failure(int exit);
+void set_verbosity_level(int verbosity);
 void add_to_schema_db(struct schema_db *db, const char *file);
 struct schema_db *new_schema_db(void);
 
diff --git a/scripts/dtc/schema.c b/scripts/dtc/schema.c
index e349e01..3a2f831 100644
--- a/scripts/dtc/schema.c
+++ b/scripts/dtc/schema.c
@@ -46,6 +46,8 @@
 static const char *const SCHEMA_EXT = .schema;
 static const char *const VALUE_PROPNAME = value;
 static int exit_on_failure = 0;
+static int verbose;
+static int error_count;
 
 struct str_list {
char *str;
@@ -57,6 +59,11 @@ struct node_list {
struct node_list *next;
 };
 
+struct property_list {
+   struct property *property;
+   struct property_list *next;
+};
+
 struct range {
uint32_t low;
uint32_t high;
@@ -236,7 +243,7 @@ static void dt_error(struct node_list *path,
 
assert(format);
 
-   fprintf(stderr, FATAL ERROR);
+   fprintf(stderr, [%d] FATAL ERROR, ++error_count);
if (p) {
fprintf(stderr,  in %s:%d:%d,
p-loc.file, p-loc.line, p-loc.col);
@@ -581,15 +588,42 @@ static int check_value(struct property *p, struct 
prop_constraints *pc)
return 1;
 }
 
+static void remove_from_property_list(struct property *p,
+ struct property_list **plist)
+{
+   struct

[RFC 05/15] scripts/dtc: check type on properties

2013-09-24 Thread Benoit Cousson
From: Fabien Parent fpar...@baylibre.com

Add the ability to check if a property has the correct type. Right now dtc only
handles the two trivial types: integer array, string array. Since at the end
everything is an array of byte which may or may not be terminated by a null
byte this was enough.

A nice thing to add for the future would be to be able to specify the types
more precisely.

Add as well two test files for this feature.

/ {
compatible = abc;

abc = 0xa 0xb 0xc;
def = def, gef;
};

To check that the property abc is an integer array and that the property def
is a string array for the dts above one can use the following schema:

/ {
compatible = abc;

abc {
type = integer;
};

def {
type = string;
};
};

Signed-off-by: Fabien Parent fpar...@baylibre.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 scripts/dtc/data.c   | 22 
 scripts/dtc/dtc.h|  9 +++
 scripts/dtc/schema-test.c|  5 
 scripts/dtc/schema.c | 44 
 scripts/dtc/tests/schemas/types-1.schema | 12 +
 scripts/dtc/tests/schemas/types-2.schema |  7 +
 scripts/dtc/tests/test1.dts  | 10 
 7 files changed, 104 insertions(+), 5 deletions(-)
 create mode 100644 scripts/dtc/tests/schemas/types-1.schema
 create mode 100644 scripts/dtc/tests/schemas/types-2.schema
 create mode 100644 scripts/dtc/tests/test1.dts

diff --git a/scripts/dtc/data.c b/scripts/dtc/data.c
index 4a40c5b..9e03718 100644
--- a/scripts/dtc/data.c
+++ b/scripts/dtc/data.c
@@ -75,6 +75,7 @@ struct data data_copy_escape_string(const char *s, int len)
char *q;
 
d = data_grow_for(empty_data, strlen(s)+1);
+   d.type = STRING;
 
q = d.val;
while (i  len) {
@@ -93,6 +94,7 @@ struct data data_copy_escape_string(const char *s, int len)
 struct data data_copy_file(FILE *f, size_t maxlen)
 {
struct data d = empty_data;
+   d.type = STRING;
 
while (!feof(f)  (d.len  maxlen)) {
size_t chunksize, ret;
@@ -157,6 +159,7 @@ struct data data_merge(struct data d1, struct data d2)
struct marker *m2 = d2.markers;
 
d = data_append_markers(data_append_data(d1, d2.val, d2.len), m2);
+   d.type = d2.type ? d2.type : d1.type;
 
/* Adjust for the length of d1 */
for_each_marker(m2)
@@ -178,23 +181,30 @@ struct data data_append_integer(struct data d, uint64_t 
value, int bits)
switch (bits) {
case 8:
value_8 = value;
-   return data_append_data(d, value_8, 1);
+   d = data_append_data(d, value_8, 1);
+   break;
 
case 16:
value_16 = cpu_to_fdt16(value);
-   return data_append_data(d, value_16, 2);
+   d = data_append_data(d, value_16, 2);
+   break;
 
case 32:
value_32 = cpu_to_fdt32(value);
-   return data_append_data(d, value_32, 4);
+   d = data_append_data(d, value_32, 4);
+   break;
 
case 64:
value_64 = cpu_to_fdt64(value);
-   return data_append_data(d, value_64, 8);
+   d = data_append_data(d, value_64, 8);
+   break;
 
default:
die(Invalid literal size (%d)\n, bits);
}
+
+   d.type = INTEGER;
+   return d;
 }
 
 struct data data_append_re(struct data d, const struct fdt_reserve_entry *re)
@@ -219,7 +229,9 @@ struct data data_append_addr(struct data d, uint64_t addr)
 
 struct data data_append_byte(struct data d, uint8_t byte)
 {
-   return data_append_data(d, byte, 1);
+   d = data_append_data(d, byte, 1);
+   d.type = INTEGER;
+   return d;
 }
 
 struct data data_append_zeroes(struct data d, int len)
diff --git a/scripts/dtc/dtc.h b/scripts/dtc/dtc.h
index e61dde7..a9b8602 100644
--- a/scripts/dtc/dtc.h
+++ b/scripts/dtc/dtc.h
@@ -82,10 +82,19 @@ struct  marker {
struct marker *next;
 };
 
+enum datatype {
+   UNDEFINED,
+   BOOLEAN,
+   INTEGER,
+   STRING,
+};
+
 struct data {
int len;
char *val;
struct marker *markers;
+
+   enum datatype type;
 };
 
 
diff --git a/scripts/dtc/schema-test.c b/scripts/dtc/schema-test.c
index 0eb2499..57c86d0 100644
--- a/scripts/dtc/schema-test.c
+++ b/scripts/dtc/schema-test.c
@@ -18,6 +18,11 @@ struct schema_test {
 };
 
 static struct schema_test tests[] = {
+   /* Types */
+   {Types #1, tests/test1.dts,
+tests/schemas/types-1.schema, 1},
+   {Types #2, tests/test1.dts,
+tests/schemas/types-2.schema, 0},
 };
 
 int main(void)
diff --git a/scripts/dtc/schema.c b/scripts/dtc/schema.c
index b190241..c01cdee 100644
--- a/scripts/dtc/schema.c
+++ b/scripts/dtc/schema.c
@@ -33,6 +33,7 @@ struct node_list {
 
 struct prop_constraints {
const

[RFC 10/15] scripts/dtc: add count limit on nodes

2013-09-24 Thread Benoit Cousson
From: Fabien Parent fpar...@baylibre.com

Add the possibility to specify in a schema a count limit for the nodes matching
the schema:
- count: if there is a match between a dts and a schema then there must
be exactly X match between the dts and the schema at the end of the
validation process.
- max-count: if there is a match between a dts and a schema then there must
be at most X match between the dts and the schema at the end of the
validation process.
This can be used to check if a specific node appears the right amount of time
in the dts.

Add as well four test files for this feature.

/ {
timer1 {
compatible = ti,omap-4430-timer;
...
};

timer2 {
compatible = ti,omap-4430-timer;
...
};
};

If in the above dts there must be exactly two timer one can check this
constraints with the following schema:

/ {
compatible = ti,omap-4430-timer;
count = 2;
};

Note: If the dts doesn't specify any timer the dts will still be valid. To
ensure that the timer is really present 2 times one should might wants to
specify constraints on then children of a node, but this feature is not
yet available.

Signed-off-by: Fabien Parent fpar...@baylibre.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 scripts/dtc/schema-test.c  | 10 
 scripts/dtc/schema.c   | 63 --
 scripts/dtc/tests/schemas/nodes-count-1.schema |  5 ++
 scripts/dtc/tests/schemas/nodes-count-2.schema |  5 ++
 scripts/dtc/tests/schemas/nodes-count-3.schema |  5 ++
 scripts/dtc/tests/schemas/nodes-count-4.schema |  5 ++
 6 files changed, 89 insertions(+), 4 deletions(-)
 create mode 100644 scripts/dtc/tests/schemas/nodes-count-1.schema
 create mode 100644 scripts/dtc/tests/schemas/nodes-count-2.schema
 create mode 100644 scripts/dtc/tests/schemas/nodes-count-3.schema
 create mode 100644 scripts/dtc/tests/schemas/nodes-count-4.schema

diff --git a/scripts/dtc/schema-test.c b/scripts/dtc/schema-test.c
index a8a5664..128a265 100644
--- a/scripts/dtc/schema-test.c
+++ b/scripts/dtc/schema-test.c
@@ -65,6 +65,16 @@ static struct schema_test tests[] = {
 tests/schemas/pattern-matching-1.schema, 1},
{Pattern Matching #2, tests/test1.dts,
 tests/schemas/pattern-matching-2.schema, 0},
+
+   /* Nodes Count */
+   {Nodes Count #1, tests/test1.dts,
+tests/schemas/nodes-count-1.schema, 1},
+   {Nodes Count #2, tests/test1.dts,
+tests/schemas/nodes-count-2.schema, 1},
+   {Nodes Count #3, tests/test1.dts,
+tests/schemas/nodes-count-3.schema, 0},
+   {Nodes Count #4, tests/test1.dts,
+tests/schemas/nodes-count-4.schema, 0},
 };
 
 int main(void)
diff --git a/scripts/dtc/schema.c b/scripts/dtc/schema.c
index d96129f..b7cfb37 100644
--- a/scripts/dtc/schema.c
+++ b/scripts/dtc/schema.c
@@ -88,7 +88,10 @@ struct node_constraints {
struct boot_info *bi;
struct node *dt;
 
-   const char *compatible;
+   char *compatible;
+   uint32_t count_requested;
+   uint32_t count;
+   uint32_t max_count;
 };
 
 struct schema_db {
@@ -657,6 +660,23 @@ static int validate_properties(struct node *n,
return ret;
 }
 
+static void load_node_constraints(struct node_constraints *nc,
+ struct node *n)
+{
+   struct property *p;
+
+   assert(n);
+   assert(nc);
+
+   nc-count = 0;
+
+   p = get_property(n, count);
+   nc-count_requested = p ? prop_val_to_uint32(p, 0) : 0;
+
+   p = get_property(n, max-count);
+   nc-max_count = p ? prop_val_to_uint32(p, 0) : ULONG_MAX;
+}
+
 static int validate_node(struct node *n,
 struct node_constraints *nc,
 struct node_list *path)
@@ -698,6 +718,7 @@ static struct node_constraints 
*get_node_constraints_of(struct schema_db *db,
n-bi = dt_from_source(n-filepath);
n-dt = n-bi-dt;
}
+   n-count++;
(*i)++;
return n;
}
@@ -705,6 +726,33 @@ static struct node_constraints 
*get_node_constraints_of(struct schema_db *db,
return NULL;
 }
 
+static int check_nodes_count(struct schema_db *db)
+{
+   int i;
+   int ret = 1;
+   struct node_constraints *n;
+
+   for (i = 0; i  db-size; i++) {
+   n = db-buffer[i];
+
+   if (n-count_requested) {
+   DT_ERROR_IF(n-count != n-count_requested, NULL, NULL,
+   There is %u instance of %s instead 
+   of %u.\n,
+   n-count,
+   n-compatible,
+   n-count_requested);
+   } else {
+   DT_ERROR_IF(n-count  n-max_count, NULL, NULL,
+   There is too

[RFC 06/15] scripts/dtc: check for required properties

2013-09-24 Thread Benoit Cousson
From: Fabien Parent fpar...@baylibre.com

Add the ability to specify inside a schema that a property is required to be
present in the validated node. By default a property can be missing but one can
require its presence inside a node via the 'is-required' property.

Add as well two test files for this feature.

timer1: timer@4a318000 {
compatible = ti,omap3430-timer;
reg = 0x4a318000 0x80;
interrupts = 0x0 0x25 0x4;
ti,hwmods = timer1;
ti,timer-alwon;
};

To make the ti,hwmods a required property inside an omap timer, one can use the
following schema:
/dts-v1/;
/ {
compatible = ti,omap[0-9]+-timer;
ti,hwmods {
is-required;
};
};

Signed-off-by: Fabien Parent fpar...@baylibre.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 scripts/dtc/schema-test.c| 6 ++
 scripts/dtc/schema.c | 6 ++
 scripts/dtc/tests/schemas/required-property-1.schema | 7 +++
 scripts/dtc/tests/schemas/required-property-2.schema | 7 +++
 4 files changed, 26 insertions(+)
 create mode 100644 scripts/dtc/tests/schemas/required-property-1.schema
 create mode 100644 scripts/dtc/tests/schemas/required-property-2.schema

diff --git a/scripts/dtc/schema-test.c b/scripts/dtc/schema-test.c
index 57c86d0..8ac4f58 100644
--- a/scripts/dtc/schema-test.c
+++ b/scripts/dtc/schema-test.c
@@ -18,6 +18,12 @@ struct schema_test {
 };
 
 static struct schema_test tests[] = {
+   /* Required Properties */
+   {Required Property #1, tests/test1.dts,
+tests/schemas/required-property-1.schema, 0},
+   {Required Property #2, tests/test1.dts,
+tests/schemas/required-property-2.schema, 1},
+
/* Types */
{Types #1, tests/test1.dts,
 tests/schemas/types-1.schema, 1},
diff --git a/scripts/dtc/schema.c b/scripts/dtc/schema.c
index c01cdee..97ea5b0 100644
--- a/scripts/dtc/schema.c
+++ b/scripts/dtc/schema.c
@@ -34,6 +34,7 @@ struct node_list {
 struct prop_constraints {
const char *name;
char *type;
+   int is_required;
 };
 
 struct node_constraints {
@@ -199,6 +200,8 @@ load_property_constraints(struct node *schema)
pc = xmalloc(sizeof(*pc));
memset(pc, 0, sizeof(*pc));
 
+   pc-is_required = get_property(schema, is-required) != NULL;
+
p = get_property(schema, name);
if (p)
pc-name = p-val.val;
@@ -255,6 +258,9 @@ static int validate_property(struct node *n,
assert(pc);
assert(path);
 
+   if (pc-is_required  !p)
+   DT_ERROR(path, NULL, Missing property '%s'\n, schema-name);
+
if (!p)
goto end;
 
diff --git a/scripts/dtc/tests/schemas/required-property-1.schema 
b/scripts/dtc/tests/schemas/required-property-1.schema
new file mode 100644
index 000..469fa5b
--- /dev/null
+++ b/scripts/dtc/tests/schemas/required-property-1.schema
@@ -0,0 +1,7 @@
+/dts-v1/;
+/ {
+   compatible = compat1;
+   abc {
+   is-required;
+   };
+};
diff --git a/scripts/dtc/tests/schemas/required-property-2.schema 
b/scripts/dtc/tests/schemas/required-property-2.schema
new file mode 100644
index 000..35bdde1
--- /dev/null
+++ b/scripts/dtc/tests/schemas/required-property-2.schema
@@ -0,0 +1,7 @@
+/dts-v1/;
+/ {
+   compatible = compat1;
+   mypropstr {
+   is-required;
+   };
+};
-- 
1.8.1.2

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


[RFC 08/15] scripts/dtc: check array size

2013-09-24 Thread Benoit Cousson
From: Fabien Parent fpar...@baylibre.com

Add constraints on array size:
- length: specify the exact length that an array must have.
- min-length: specify the minimum number of elements an array must have.
- max-length: specify the maximum number of elements an array must have.

Add as well four test files for the feature.

Usage example:
node {
compatible = array_size;
myarray = 0 1 2 3 4;
};

Schema:
/dts-v1/;
/ {
compatible = array_size;

myarray {
length = 5;
};
};

Signed-off-by: Fabien Parent fpar...@baylibre.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 scripts/dtc/data.c|  5 +++
 scripts/dtc/dtc.h |  1 +
 scripts/dtc/schema-test.c | 10 ++
 scripts/dtc/schema.c  | 52 +++
 scripts/dtc/tests/schemas/array-size-1.schema | 13 +++
 scripts/dtc/tests/schemas/array-size-2.schema |  8 +
 scripts/dtc/tests/schemas/array-size-3.schema |  8 +
 scripts/dtc/tests/schemas/array-size-4.schema |  8 +
 8 files changed, 105 insertions(+)
 create mode 100644 scripts/dtc/tests/schemas/array-size-1.schema
 create mode 100644 scripts/dtc/tests/schemas/array-size-2.schema
 create mode 100644 scripts/dtc/tests/schemas/array-size-3.schema
 create mode 100644 scripts/dtc/tests/schemas/array-size-4.schema

diff --git a/scripts/dtc/data.c b/scripts/dtc/data.c
index 9e03718..5284936 100644
--- a/scripts/dtc/data.c
+++ b/scripts/dtc/data.c
@@ -76,6 +76,7 @@ struct data data_copy_escape_string(const char *s, int len)
 
d = data_grow_for(empty_data, strlen(s)+1);
d.type = STRING;
+   d.array_size++;
 
q = d.val;
while (i  len) {
@@ -95,6 +96,7 @@ struct data data_copy_file(FILE *f, size_t maxlen)
 {
struct data d = empty_data;
d.type = STRING;
+   d.array_size++;
 
while (!feof(f)  (d.len  maxlen)) {
size_t chunksize, ret;
@@ -159,6 +161,7 @@ struct data data_merge(struct data d1, struct data d2)
struct marker *m2 = d2.markers;
 
d = data_append_markers(data_append_data(d1, d2.val, d2.len), m2);
+   d.array_size += d2.array_size;
d.type = d2.type ? d2.type : d1.type;
 
/* Adjust for the length of d1 */
@@ -204,6 +207,7 @@ struct data data_append_integer(struct data d, uint64_t 
value, int bits)
}
 
d.type = INTEGER;
+   d.array_size++;
return d;
 }
 
@@ -231,6 +235,7 @@ struct data data_append_byte(struct data d, uint8_t byte)
 {
d = data_append_data(d, byte, 1);
d.type = INTEGER;
+   d.array_size++;
return d;
 }
 
diff --git a/scripts/dtc/dtc.h b/scripts/dtc/dtc.h
index a9b8602..64fdc8a 100644
--- a/scripts/dtc/dtc.h
+++ b/scripts/dtc/dtc.h
@@ -95,6 +95,7 @@ struct data {
struct marker *markers;
 
enum datatype type;
+   size_t array_size;
 };
 
 
diff --git a/scripts/dtc/schema-test.c b/scripts/dtc/schema-test.c
index 99a4142..bfc9e43 100644
--- a/scripts/dtc/schema-test.c
+++ b/scripts/dtc/schema-test.c
@@ -35,6 +35,16 @@ static struct schema_test tests[] = {
 tests/schemas/types-1.schema, 1},
{Types #2, tests/test1.dts,
 tests/schemas/types-2.schema, 0},
+
+   /* Array Size */
+   {Array Size #1, tests/test1.dts,
+tests/schemas/array-size-1.schema, 1},
+   {Array Size #2, tests/test1.dts,
+tests/schemas/array-size-2.schema, 0},
+   {Array Size #3, tests/test1.dts,
+tests/schemas/array-size-3.schema, 0},
+   {Array Size #4, tests/test1.dts,
+tests/schemas/array-size-4.schema, 0},
 };
 
 int main(void)
diff --git a/scripts/dtc/schema.c b/scripts/dtc/schema.c
index 95fc44b..95ad925 100644
--- a/scripts/dtc/schema.c
+++ b/scripts/dtc/schema.c
@@ -5,6 +5,7 @@
 #include dirent.h
 #include pcre.h
 #include stdio.h
+#include limits.h
 
 #define DT_ERROR(path, p, format, ...) \
do { \
@@ -36,6 +37,8 @@ struct prop_constraints {
char *type;
int is_required;
int can_be_inherited;
+   size_t min_length;
+   size_t max_length;
 };
 
 struct node_constraints {
@@ -73,6 +76,28 @@ static pcre *compile_pattern(const char *pattern)
return re;
 }
 
+static uint32_t prop_val_to_uint32(struct property *p, int i)
+{
+   assert(p);
+   assert(i = 0);
+
+   switch (p-val.len / p-val.array_size) {
+   case 1:
+   return ((uint8_t *) p-val.val)[i];
+
+   case 2:
+   return fdt16_to_cpu(((uint16_t *) p-val.val)[i]);
+
+   case 4:
+   return fdt32_to_cpu(((uint32_t *) p-val.val)[i]);
+
+   default:
+   die(reach unreachable.);
+   }
+
+   return 0;
+}
+
 static int get_next_string_offset(struct property *p, int offset)
 {
assert(p);
@@ -203,6 +228,7 @@ load_property_constraints(struct node *schema)
 
pc-is_required = get_property(schema, is-required

[RFC 04/15] scripts/dtc: add procedure to handle dts errors

2013-09-24 Thread Benoit Cousson
From: Fabien Parent fpar...@baylibre.com

The parser was not keeping enough information to allow a good error reporting.
Source Location information has been added inside a property instance to be
able to precisely tell where an error happened when a property does not match
its constraints as specified inside a schema.
Add as well a routine to print error message using these informations in case
of validation error.

Signed-off-by: Fabien Parent fpar...@baylibre.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 scripts/dtc/dtc-parser.tab.c_shipped | 595 +++
 scripts/dtc/dtc-parser.y |   9 +
 scripts/dtc/dtc.h|   7 +
 scripts/dtc/schema.c |  69 
 4 files changed, 345 insertions(+), 335 deletions(-)

diff --git a/scripts/dtc/dtc-parser.tab.c_shipped 
b/scripts/dtc/dtc-parser.tab.c_shipped
index ee1d8c3..d6d800a 100644
--- a/scripts/dtc/dtc-parser.tab.c_shipped
+++ b/scripts/dtc/dtc-parser.tab.c_shipped
@@ -1,8 +1,8 @@
-/* A Bison parser, made by GNU Bison 2.5.  */
+/* A Bison parser, made by GNU Bison 2.7.12-4996.  */
 
 /* Bison implementation for Yacc-like parsers in C

-  Copyright (C) 1984, 1989-1990, 2000-2011 Free Software Foundation, Inc.
+  Copyright (C) 1984, 1989-1990, 2000-2013 Free Software Foundation, Inc.

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -44,7 +44,7 @@
 #define YYBISON 1
 
 /* Bison version.  */
-#define YYBISON_VERSION 2.5
+#define YYBISON_VERSION 2.7.12-4996
 
 /* Skeleton name.  */
 #define YYSKELETON_NAME yacc.c
@@ -58,14 +58,11 @@
 /* Pull parsers.  */
 #define YYPULL 1
 
-/* Using locations.  */
-#define YYLSP_NEEDED 0
 
 
 
 /* Copy the first part of user declarations.  */
-
-/* Line 268 of yacc.c  */
+/* Line 371 of yacc.c  */
 #line 21 dtc-parser.y
 
 #include stdio.h
@@ -85,14 +82,16 @@ extern int treesource_error;
 static unsigned long long eval_literal(const char *s, int base, int bits);
 static unsigned char eval_char_literal(const char *s);
 
+/* Line 371 of yacc.c  */
+#line 87 dtc-parser.tab.c
 
-/* Line 268 of yacc.c  */
-#line 91 dtc-parser.tab.c
-
-/* Enabling traces.  */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
+# ifndef YY_NULL
+#  if defined __cplusplus  201103L = __cplusplus
+#   define YY_NULL nullptr
+#  else
+#   define YY_NULL 0
+#  endif
+# endif
 
 /* Enabling verbose error messages.  */
 #ifdef YYERROR_VERBOSE
@@ -102,11 +101,14 @@ static unsigned char eval_char_literal(const char *s);
 # define YYERROR_VERBOSE 0
 #endif
 
-/* Enabling the token table.  */
-#ifndef YYTOKEN_TABLE
-# define YYTOKEN_TABLE 0
-#endif
 
+/* Enabling traces.  */
+#ifndef YYDEBUG
+# define YYDEBUG 0
+#endif
+#if YYDEBUG
+extern int yydebug;
+#endif
 
 /* Tokens.  */
 #ifndef YYTOKENTYPE
@@ -140,12 +142,10 @@ static unsigned char eval_char_literal(const char *s);
 #endif
 
 
-
 #if ! defined YYSTYPE  ! defined YYSTYPE_IS_DECLARED
 typedef union YYSTYPE
 {
-
-/* Line 293 of yacc.c  */
+/* Line 387 of yacc.c  */
 #line 40 dtc-parser.y
 
char *propnodename;
@@ -168,21 +168,36 @@ typedef union YYSTYPE
uint64_t integer;
 
 
-
-/* Line 293 of yacc.c  */
-#line 174 dtc-parser.tab.c
+/* Line 387 of yacc.c  */
+#line 173 dtc-parser.tab.c
 } YYSTYPE;
 # define YYSTYPE_IS_TRIVIAL 1
 # define yystype YYSTYPE /* obsolescent; will be withdrawn */
 # define YYSTYPE_IS_DECLARED 1
 #endif
 
+extern YYSTYPE yylval;
 
-/* Copy the second part of user declarations.  */
+#ifdef YYPARSE_PARAM
+#if defined __STDC__ || defined __cplusplus
+int yyparse (void *YYPARSE_PARAM);
+#else
+int yyparse ();
+#endif
+#else /* ! YYPARSE_PARAM */
+#if defined __STDC__ || defined __cplusplus
+int yyparse (void);
+#else
+int yyparse ();
+#endif
+#endif /* ! YYPARSE_PARAM */
 
 
-/* Line 343 of yacc.c  */
-#line 186 dtc-parser.tab.c
+
+/* Copy the second part of user declarations.  */
+
+/* Line 390 of yacc.c  */
+#line 201 dtc-parser.tab.c
 
 #ifdef short
 # undef short
@@ -235,24 +250,33 @@ typedef short int yytype_int16;
 # if defined YYENABLE_NLS  YYENABLE_NLS
 #  if ENABLE_NLS
 #   include libintl.h /* INFRINGES ON USER NAME SPACE */
-#   define YY_(msgid) dgettext (bison-runtime, msgid)
+#   define YY_(Msgid) dgettext (bison-runtime, Msgid)
 #  endif
 # endif
 # ifndef YY_
-#  define YY_(msgid) msgid
+#  define YY_(Msgid) Msgid
+# endif
+#endif
+
+#ifndef __attribute__
+/* This feature is available in gcc versions 2.5 and later.  */
+# if (! defined __GNUC__ || __GNUC__  2 \
+  || (__GNUC__ == 2  __GNUC_MINOR__  5))
+#  define __attribute__(Spec) /* empty */
 # endif
 #endif
 
 /* Suppress unused-variable warnings by using E.  */
 #if ! defined lint || defined __GNUC__
-# define YYUSE(e) ((void) (e))
+# define YYUSE(E) ((void) (E))
 #else
-# define YYUSE(e) /* empty */
+# define YYUSE(E) /* empty */
 #endif
 
+
 /* Identity function, used to suppress warnings about constant

[RFC 11/15] scripts/dtc: check for children nodes

2013-09-24 Thread Benoit Cousson
From: Fabien Parent fpar...@baylibre.com

Add the ability to check if a node has some required children nodes.
Add as well two test files for this feature.

node {
compatible = comp;

subnode1 {
};

subnode2 {
};

abc {
};
};

One can check if 'node' has the following subnode 'subnode1', 'subnode2', and
'abc' with the schema below:

/dts-v1/;
/ {
compatible = comp;
children = abc, subnode[0-9];
};

Signed-off-by: Fabien Parent fpar...@baylibre.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 scripts/dtc/schema-test.c |  6 +++
 scripts/dtc/schema.c  | 47 +++
 scripts/dtc/tests/schemas/children-nodes-1.schema |  5 +++
 scripts/dtc/tests/schemas/children-nodes-2.schema |  5 +++
 scripts/dtc/tests/test1.dts   |  4 ++
 5 files changed, 67 insertions(+)
 create mode 100644 scripts/dtc/tests/schemas/children-nodes-1.schema
 create mode 100644 scripts/dtc/tests/schemas/children-nodes-2.schema

diff --git a/scripts/dtc/schema-test.c b/scripts/dtc/schema-test.c
index 128a265..9f1ce31 100644
--- a/scripts/dtc/schema-test.c
+++ b/scripts/dtc/schema-test.c
@@ -75,6 +75,12 @@ static struct schema_test tests[] = {
 tests/schemas/nodes-count-3.schema, 0},
{Nodes Count #4, tests/test1.dts,
 tests/schemas/nodes-count-4.schema, 0},
+
+   /* Children nodes */
+   {Children Nodes #1, tests/test1.dts,
+tests/schemas/children-nodes-1.schema, 1},
+   {Children Nodes #2, tests/test1.dts,
+tests/schemas/children-nodes-2.schema, 0},
 };
 
 int main(void)
diff --git a/scripts/dtc/schema.c b/scripts/dtc/schema.c
index b7cfb37..a454a19 100644
--- a/scripts/dtc/schema.c
+++ b/scripts/dtc/schema.c
@@ -47,6 +47,11 @@ static const char *const SCHEMA_EXT = .schema;
 static const char *const VALUE_PROPNAME = value;
 static int exit_on_failure = 0;
 
+struct str_list {
+   char *str;
+   struct str_list *next;
+};
+
 struct node_list {
struct node *n;
struct node_list *next;
@@ -92,6 +97,7 @@ struct node_constraints {
uint32_t count_requested;
uint32_t count;
uint32_t max_count;
+   struct str_list *children;
 };
 
 struct schema_db {
@@ -664,6 +670,8 @@ static void load_node_constraints(struct node_constraints 
*nc,
  struct node *n)
 {
struct property *p;
+   int i = 0;
+   struct str_list *iter;
 
assert(n);
assert(nc);
@@ -675,6 +683,15 @@ static void load_node_constraints(struct node_constraints 
*nc,
 
p = get_property(n, max-count);
nc-max_count = p ? prop_val_to_uint32(p, 0) : ULONG_MAX;
+
+   p = get_property(n, children);
+   while (p  i  p-val.len  i = 0) {
+   iter = xmalloc(sizeof(*iter));
+   iter-str = xstrdup(p-val.val + i);
+   iter-next = nc-children;
+   nc-children = iter;
+   i = get_next_string_offset(p, i);
+   }
 }
 
 static int validate_node(struct node *n,
@@ -682,7 +699,10 @@ static int validate_node(struct node *n,
 struct node_list *path)
 {
struct node *iter;
+   struct str_list *pattern;
int ret = 1;
+   pcre *re;
+   int has_child;
 
assert(n);
assert(path);
@@ -692,6 +712,27 @@ static int validate_node(struct node *n,
for (iter = nc-dt-children; iter; iter = iter-next_sibling)
ret = validate_properties(n, iter, path);
 
+   /* Check whether the node has all the required children nodes */
+   for (pattern = nc-children;
+pattern;
+pattern = pattern-next) {
+   re = compile_pattern(pattern-str);
+   if (!re)
+   die(Invalid pattern: %s\n, pattern-str);
+
+   has_child = 0;
+   for (iter = n-children; iter; iter = iter-next_sibling) {
+   has_child |= pcre_exec(re, 0, iter-name,
+  strlen(iter-name), 0, 0,
+  NULL, 0) = 0;
+   }
+
+   pcre_free(re);
+   DT_ERROR_IF(!has_child, path, NULL,
+   Missing child node '%s'\n, pattern-str);
+   }
+
+end:
return ret;
 }
 
@@ -1021,9 +1062,15 @@ struct schema_db *build_schema_db(const char *dir)
 
 static void free_node_constraints(struct node_constraints *nc)
 {
+   struct str_list *iter, *iter_next;
+
if (!nc)
return;
 
+   for_each_safe(nc-children, iter, iter_next) {
+   free(iter-str);
+   }
+
pcre_free(nc-re_compat);
free_dt(nc-bi);
free(nc-filepath);
diff --git a/scripts/dtc/tests/schemas/children-nodes-1.schema 
b/scripts/dtc/tests/schemas/children-nodes-1.schema
new file mode 100644
index 000..8f1cf9a
--- /dev/null
+++ b/scripts/dtc

[RFC 09/15] scripts/dtc: check value of properties

2013-09-24 Thread Benoit Cousson
From: Fabien Parent fpar...@baylibre.com

Add the ability to check whether a property has a given value or not.
Add as well 7 test files for this feature.

abc {
   prop1 = 0 1 2 3;
   prop2 = value0, value1, value3;
};



To check whether an integer array contains value from a given range
use the following constraint:
prop1 {
type = integer;
value = 0x0 0xF;
};

To check whether a string array contains value that match a given pattern
use the following constraint:
prop2 {
type = string;
value = value[0-9];
};

To check whether a particular element of an array has the correct value one
can use the following constraint:
prop1 {
type = integer;
value@2 = 2;
};

or

prop2 {
type = string;
value@1 = value1;
};

Signed-off-by: Fabien Parent fpar...@baylibre.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 scripts/dtc/schema-test.c  |  20 ++
 scripts/dtc/schema.c   | 288 +
 scripts/dtc/tests/schemas/integer-array-1.schema   |  16 ++
 scripts/dtc/tests/schemas/integer-array-2.schema   |   9 +
 scripts/dtc/tests/schemas/integer-array-3.schema   |   8 +
 .../dtc/tests/schemas/pattern-matching-1.schema|  10 +
 .../dtc/tests/schemas/pattern-matching-2.schema|  10 +
 scripts/dtc/tests/schemas/string-array-1.schema|  20 ++
 scripts/dtc/tests/schemas/string-array-2.schema|   9 +
 scripts/dtc/tests/test1.dts|   4 +
 10 files changed, 394 insertions(+)
 create mode 100644 scripts/dtc/tests/schemas/integer-array-1.schema
 create mode 100644 scripts/dtc/tests/schemas/integer-array-2.schema
 create mode 100644 scripts/dtc/tests/schemas/integer-array-3.schema
 create mode 100644 scripts/dtc/tests/schemas/pattern-matching-1.schema
 create mode 100644 scripts/dtc/tests/schemas/pattern-matching-2.schema
 create mode 100644 scripts/dtc/tests/schemas/string-array-1.schema
 create mode 100644 scripts/dtc/tests/schemas/string-array-2.schema

diff --git a/scripts/dtc/schema-test.c b/scripts/dtc/schema-test.c
index bfc9e43..a8a5664 100644
--- a/scripts/dtc/schema-test.c
+++ b/scripts/dtc/schema-test.c
@@ -45,6 +45,26 @@ static struct schema_test tests[] = {
 tests/schemas/array-size-3.schema, 0},
{Array Size #4, tests/test1.dts,
 tests/schemas/array-size-4.schema, 0},
+
+   /* String Array */
+   {String Array Values #1, tests/test1.dts,
+tests/schemas/string-array-1.schema, 1},
+   {String Array Values #2, tests/test1.dts,
+tests/schemas/string-array-2.schema, 0},
+
+   /* Integer Array */
+   {Integer Array Values #1, tests/test1.dts,
+tests/schemas/integer-array-1.schema, 1},
+   {Integer Array Values #2, tests/test1.dts,
+tests/schemas/integer-array-2.schema, 0},
+   {Integer Array Values #3, tests/test1.dts,
+tests/schemas/integer-array-3.schema, 0},
+
+   /* Pattern Matching */
+   {Pattern Matching #1, tests/test1.dts,
+tests/schemas/pattern-matching-1.schema, 1},
+   {Pattern Matching #2, tests/test1.dts,
+tests/schemas/pattern-matching-2.schema, 0},
 };
 
 int main(void)
diff --git a/scripts/dtc/schema.c b/scripts/dtc/schema.c
index 95ad925..d96129f 100644
--- a/scripts/dtc/schema.c
+++ b/scripts/dtc/schema.c
@@ -7,6 +7,26 @@
 #include stdio.h
 #include limits.h
 
+#define sorted_list_add(x, e) \
+   do { \
+   typeof(x) prev, i; \
+   if (!x) {\
+   x = e; \
+   break; \
+   } \
+   for (prev = x, i = x-next; \
+i  i-id  e-id; \
+prev = i, i = i-next) \
+   ; \
+   e-next = i; \
+   prev-next = e; \
+   } while (0)
+
+#define for_each_safe(list, iter, iter_next) \
+   for (iter = list, iter_next = list ? list-next : NULL;\
+iter; \
+iter = iter_next, iter_next = iter_next ? iter_next-next : NULL)
+
 #define DT_ERROR(path, p, format, ...) \
do { \
dt_error(path, p, format, ##__VA_ARGS__); \
@@ -32,6 +52,21 @@ struct node_list {
struct node_list *next;
 };
 
+struct range {
+   uint32_t low;
+   uint32_t high;
+   int id;
+
+   struct range *next;
+};
+
+struct pattern {
+   const char *text;
+   int id;
+
+   struct pattern *next;
+};
+
 struct prop_constraints {
const char *name;
char *type;
@@ -39,6 +74,12 @@ struct prop_constraints {
int can_be_inherited;
size_t min_length;
size_t max_length;
+
+   union {
+   struct pattern *patterns;
+   struct range *ranges;
+   } value;
+   enum datatype value_type;
 };
 
 struct node_constraints {
@@ -207,11 +248,139 @@ static void dt_error(struct node_list *path,
exit(1);
 }
 
+static

[RFC 12/15] scripts/dtc: check constraints on parents

2013-09-24 Thread Benoit Cousson
From: Fabien Parent fpar...@baylibre.com

Add the ability to specify constraints on the parents of a node.
Add as well seven test files for this feature.

node {
compatible = abcomp;
abc = abc;

subnode {
compatible = comp;
abc = def;
};
};

The schema below tests whether 'subnode' has a parent named 'node' and whether
it has a compatible property equal to abcomp and a 'abc' property equal to
abc. In the case of the node above the constraints couldn't be check by
inheriting the properties via 'can-be-inherited' since they are overwritten
by the node 'subnode'.

/dts-v1/;
/ {
compatible = comp;

parents {
node {
compatible {
type = string;
value = abcomp;
};

abc {
type = string;
value = abc;
};
};
};
};

It is possible to set conditional constraints on parents of the following form:
if (node_compatible == compat1)
check_this_parent_constraints();
else if (node_compatible == compat2)
check_that_parent_constraints();

To do this one should put the parent constraints at the same place as the
compatible definition in a schema file.

/dts-v1/;
/ {
compatible {
value@0 {
value = compat1;
parents {
node {
myprop {
type = int;
value@0 = 0xf;
};
};
};
};

value@1 {
value = compat2;
parents {
node {
myprop {
type = int;
value@0 = 0xa;
};
};
};
};
};
};

This schema will check that if the compatible of a node is compat1 then it
must have a parent node node which has an integer array property myprop
which has as first element the value 0xf, otherwise if the node has the
compatible compat2 then the first element of the same property must have the
value 0xa.

Signed-off-by: Fabien Parent fpar...@baylibre.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 scripts/dtc/schema-test.c   |  16 +++
 scripts/dtc/schema.c| 126 +++-
 scripts/dtc/tests/schemas/parent-nodes-1.schema |  23 +
 scripts/dtc/tests/schemas/parent-nodes-2.schema |  12 +++
 scripts/dtc/tests/schemas/parent-nodes-3.schema |  14 +++
 scripts/dtc/tests/schemas/parent-nodes-4.schema |  27 +
 scripts/dtc/tests/schemas/parent-nodes-5.schema |  15 +++
 scripts/dtc/tests/schemas/parent-nodes-6.schema |  13 +++
 scripts/dtc/tests/schemas/parent-nodes-7.schema |  13 +++
 9 files changed, 257 insertions(+), 2 deletions(-)
 create mode 100644 scripts/dtc/tests/schemas/parent-nodes-1.schema
 create mode 100644 scripts/dtc/tests/schemas/parent-nodes-2.schema
 create mode 100644 scripts/dtc/tests/schemas/parent-nodes-3.schema
 create mode 100644 scripts/dtc/tests/schemas/parent-nodes-4.schema
 create mode 100644 scripts/dtc/tests/schemas/parent-nodes-5.schema
 create mode 100644 scripts/dtc/tests/schemas/parent-nodes-6.schema
 create mode 100644 scripts/dtc/tests/schemas/parent-nodes-7.schema

diff --git a/scripts/dtc/schema-test.c b/scripts/dtc/schema-test.c
index 9f1ce31..5075c24 100644
--- a/scripts/dtc/schema-test.c
+++ b/scripts/dtc/schema-test.c
@@ -81,6 +81,22 @@ static struct schema_test tests[] = {
 tests/schemas/children-nodes-1.schema, 1},
{Children Nodes #2, tests/test1.dts,
 tests/schemas/children-nodes-2.schema, 0},
+
+   /* Parent nodes */
+   {Parent Nodes #1, tests/test1.dts,
+tests/schemas/parent-nodes-1.schema, 1},
+   {Parent Nodes #2, tests/test1.dts,
+tests/schemas/parent-nodes-2.schema, 0},
+   {Parent Nodes #3, tests/test1.dts,
+tests/schemas/parent-nodes-3.schema, 0},
+   {Parent Nodes #4, tests/test1.dts,
+tests/schemas/parent-nodes-4.schema, 1},
+   {Parent Nodes #5, tests/test1.dts,
+tests/schemas/parent-nodes-5.schema, 0},
+   {Parent Nodes #6, tests/test1.dts,
+tests/schemas/parent-nodes-6.schema, 0},
+   {Parent Nodes #7, tests/test1.dts,
+tests/schemas/parent-nodes-7.schema, 1},
 };
 
 int main(void)
diff --git a/scripts/dtc/schema.c b/scripts/dtc/schema.c
index a454a19..e349e01 100644
--- a/scripts/dtc/schema.c
+++ b/scripts/dtc/schema.c
@@ -694,6 +694,123 @@ static void load_node_constraints(struct node_constraints 
*nc,
}
 }
 
+static struct node *find_parent_node(struct node *schema,
+struct node_list *path)
+{
+   struct property *p;
+   char *name;
+
+   if (!path)
+   return NULL;
+
+   assert(schema);
+   assert(path-n);
+
+   p = get_property(schema, name);
+   if (p) {
+   assert(p-val.type == STRING

[RFC 13/15] bindings: OMAP: add new schema files

2013-09-24 Thread Benoit Cousson
From: Fabien Parent fpar...@baylibre.com

Introduce a couple of real schema for OMAP DTS files. For the moment validate
only: MPU, DSP, INTC, IVA, TIME and COUNTER.

Signed-off-by: Fabien Parent fpar...@baylibre.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 bindings/arm/omap/counter.schema |  28 +
 bindings/arm/omap/dsp.schema |  18 ++
 bindings/arm/omap/intc.schema|  48 +++
 bindings/arm/omap/iva.schema |  38 
 bindings/arm/omap/l3-noc.schema  |  38 
 bindings/arm/omap/mpu.schema |  19 ++
 bindings/arm/omap/omap.schema|  62 
 bindings/arm/omap/timer.schema   | 124 +++
 8 files changed, 375 insertions(+)
 create mode 100644 bindings/arm/omap/counter.schema
 create mode 100644 bindings/arm/omap/dsp.schema
 create mode 100644 bindings/arm/omap/intc.schema
 create mode 100644 bindings/arm/omap/iva.schema
 create mode 100644 bindings/arm/omap/l3-noc.schema
 create mode 100644 bindings/arm/omap/mpu.schema
 create mode 100644 bindings/arm/omap/omap.schema
 create mode 100644 bindings/arm/omap/timer.schema

diff --git a/bindings/arm/omap/counter.schema b/bindings/arm/omap/counter.schema
new file mode 100644
index 000..63b0272
--- /dev/null
+++ b/bindings/arm/omap/counter.schema
@@ -0,0 +1,28 @@
+/**
+ * OMAP Counter-32K bindings
+ */
+
+/dts-v1/;
+
+/ {
+compatible {
+description = Must be 'ti,omap-counter32k' for OMAP controllers.;
+value = ti,omap-counter32k;
+};
+
+reg {
+description = Contains timer register address range (base address
+   and length).;
+is-required;
+type = integer;
+length = 2;
+};
+
+ti,hwmods {
+description = Name of the hwmod associated to the counter,
+   which is typically 'counter_32k'.;
+is-required;
+type = string;
+value = counter_32k;
+};
+};
diff --git a/bindings/arm/omap/dsp.schema b/bindings/arm/omap/dsp.schema
new file mode 100644
index 000..7087f60
--- /dev/null
+++ b/bindings/arm/omap/dsp.schema
@@ -0,0 +1,18 @@
+/**
+ * TI - DSP (Digital Signal Processor)
+ */
+
+/dts-v1/;
+
+/ {
+compatible {
+description = Should be 'ti,omap3-c64' for OMAP3  4;
+value = ti,omap3-c64;
+};
+
+ti,hwmods {
+is-required;
+type = string;
+value = dsp;
+};
+};
diff --git a/bindings/arm/omap/intc.schema b/bindings/arm/omap/intc.schema
new file mode 100644
index 000..564c80e
--- /dev/null
+++ b/bindings/arm/omap/intc.schema
@@ -0,0 +1,48 @@
+/**
+ * OMAP Interrupt Controller
+ *
+ * OMAP2/3 are using a TI interrupt controller that can support several
+ * configurable number of interrupts.
+ */
+
+/dts-v1/;
+
+/ {
+compatible {
+description = Must be 'ti,omap-counter32k' for OMAP controllers.;
+value = ti,omap2-intc;
+};
+
+interrupt-controller {
+description = Identifies the node as an interrupt controller;
+is-required;
+type = bool;
+};
+
+#interrupt-cells {
+description = Specifies the number of cells needed to encode an
+   interrupt source. The type shall be a u32
+   and the value shall be 1.
+   The cell contains the interrupt number
+   in the range [0-128].;
+is-required;
+type = integer;
+value = 1;
+};
+
+ti,intc-size {
+description = Number of interrupts handled
+   by the interrupt controller;
+is-required;
+type = integer;
+length = 1;
+};
+
+reg {
+description = physical base address and size of the intc
+   registers map.;
+is-required;
+type = integer;
+length = 2;
+};
+};
diff --git a/bindings/arm/omap/iva.schema b/bindings/arm/omap/iva.schema
new file mode 100644
index 000..582c104
--- /dev/null
+++ b/bindings/arm/omap/iva.schema
@@ -0,0 +1,38 @@
+/**
+ * TI - IVA (Imaging and Video Accelerator) subsystem
+ *
+ * The IVA contain various audio, video or imaging HW accelerator
+ * depending of the version.
+ */
+
+/dts-v1/;
+
+/ {
+compatible {
+value@0 {
+description = for OMAP4;
+value = ti,ivahd;
+};
+
+value@1 {
+description = for OMAP3;
+value = ti,iva2.2;
+};
+
+value@2 {
+description = for OMAP2430;
+value = ti,iva2.1;
+};
+
+value@3 {
+description = for OMAP2420;
+value = ti,iva1;
+};
+};
+
+ti,hwmods {
+is-required;
+type = string;
+value = iva;
+};
+};
diff --git a/bindings/arm/omap/l3-noc.schema b/bindings/arm/omap/l3-noc.schema
new file mode 100644
index 000..0611c4d
--- /dev/null
+++ b/bindings/arm/omap/l3-noc.schema
@@ -0,0

[RFC 14/15] scripts/dtc: validate dts against schema bindings

2013-09-24 Thread Benoit Cousson
From: Fabien Parent fpar...@baylibre.com

Add the path of the bindings schema directory on the command line used
for compiling the dts files. The dts files will be validated against all the
matching schemas found.

Signed-off-by: Fabien Parent fpar...@baylibre.com
Signed-off-by: Benoit Cousson bcous...@baylibre.com
---
 scripts/Makefile.lib | 1 +
 1 file changed, 1 insertion(+)

diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
index 49392ec..358dd69 100644
--- a/scripts/Makefile.lib
+++ b/scripts/Makefile.lib
@@ -264,6 +264,7 @@ $(obj)/%.dtb.S: $(obj)/%.dtb
 quiet_cmd_dtc = DTC $@
 cmd_dtc = $(CPP) $(dtc_cpp_flags) -x assembler-with-cpp -o $(dtc-tmp) $ ; \
$(objtree)/scripts/dtc/dtc -O dtb -o $@ -b 0 \
+   -M $(objtree)/bindings \
-i $(dir $) $(DTC_FLAGS) \
-d $(depfile).dtc.tmp $(dtc-tmp) ; \
cat $(depfile).pre.tmp $(depfile).dtc.tmp  $(depfile)
-- 
1.8.1.2

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


Re: [PATCH 1/2] ARM: dts: Fix muxing and regulator for wl12xx on the SDIO bus for pandaboard

2013-09-18 Thread Benoit Cousson

Hi Tony,

On 18/09/2013 02:02, Tony Lindgren wrote:

* Luca Coelho l...@coelho.fi [130916 23:35]:

On Tue, 2013-09-17 at 09:26 +0300, Luca Coelho wrote:

Both patches look good to me, though I didn't have the time to retest
them.


Actually I don't even have a Blaze device anymore, so I can't really
test the second patch. :(


OK no problem, I've tested it on panda es.


Do we have someone out-there that still own a Blaze?

Anyway, I'm about to send a DTS fix branch for -rc2, so I'll include 
these two patches.


Thanks,
Benoit


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


[GIT PULL] ARM: DTS: Fix OMAP bugs for 3.12-rc

2013-09-18 Thread Benoit Cousson
Hi Tony,

Please pull few fixes for OMAP DTS.

Thanks,
Benoit



The following changes since commit 272b98c6455f00884f0350f775c5342358ebb73f:

  Linux 3.12-rc1 (2013-09-16 16:17:51 -0400)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/bcousson/linux-omap-dt.git 
tags/for_3.12-rc2/dts_signed

for you to fetch changes up to 775d2418f309052641d94c896f73dc779cf7ba1b:

  ARM: dts: Fix muxing and regulator for wl12xx on the SDIO bus for blaze 
(2013-09-18 11:14:42 +0200)


Fix BBB LDO voltage to avoid HDMI destruction
Fix OMAP5 wrong attribute
Fix typo in beagle xM strings


Felipe Balbi (2):
  ARM: dts: OMAP5: fix reg property size
  ARM: dts: OMAP5: fix ocp2scp DTS data

Koen Kooi (1):
  ARM: dts: am335x-bone*: add DT for BeagleBone Black

Robert Nelson (1):
  ARM: dts: omap3-beagle-xm: fix string error in compatible property

Tony Lindgren (2):
  ARM: dts: Fix muxing and regulator for wl12xx on the SDIO bus for 
pandaboard
  ARM: dts: Fix muxing and regulator for wl12xx on the SDIO bus for blaze

 arch/arm/boot/dts/Makefile|   1 +
 arch/arm/boot/dts/am335x-bone-common.dtsi | 262 ++
 arch/arm/boot/dts/am335x-bone.dts | 256 +
 arch/arm/boot/dts/am335x-boneblack.dts|  17 ++
 arch/arm/boot/dts/omap3-beagle-xm.dts |   2 +-
 arch/arm/boot/dts/omap4-panda-common.dtsi |  46 +-
 arch/arm/boot/dts/omap4-sdp.dts   |  39 -
 arch/arm/boot/dts/omap5.dtsi  |   7 +-
 8 files changed, 369 insertions(+), 261 deletions(-)
 create mode 100644 arch/arm/boot/dts/am335x-bone-common.dtsi
 create mode 100644 arch/arm/boot/dts/am335x-boneblack.dts
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] ARM: dts: igep00x0: Add pinmux configuration for MCBSP2.

2013-09-18 Thread Benoit Cousson

Hi Enric,

On 10/09/2013 17:38, Enric Balletbo Serra wrote:

2013/9/10 Enric Balletbo i Serra eballe...@gmail.com:

Add pinmux configuration for MCBSP2 connected to the TDM interface. With
this configuration the Headset modules works as expected.

Signed-off-by: Enric Balletbo i Serra eballe...@gmail.com
Acked-by: Javier Martinez Canillas jav...@dowhile0.org
---
  arch/arm/boot/dts/omap3-igep.dtsi | 14 ++
  1 file changed, 14 insertions(+)

diff --git a/arch/arm/boot/dts/omap3-igep.dtsi 
b/arch/arm/boot/dts/omap3-igep.dtsi
index bc48b11..2326d11 100644
--- a/arch/arm/boot/dts/omap3-igep.dtsi
+++ b/arch/arm/boot/dts/omap3-igep.dtsi
@@ -48,6 +48,15 @@
 ;
 };

+   mcbsp2_pins: pinmux_mcbsp2_pins {
+   pinctrl-single,pins = 
+   0x10c (PIN_INPUT | MUX_MODE0)   /* 
mcbsp2_fsx.mcbsp2_fsx */
+   0x10e (PIN_INPUT | MUX_MODE0)   /* 
mcbsp2_clkx.mcbsp2_clkx */
+   0x110 (PIN_INPUT | MUX_MODE0)   /* 
mcbsp2_dr.mcbsp2.dr */
+   0x112 (PIN_OUTPUT | MUX_MODE0)  /* 
mcbsp2_dx.mcbsp2_dx */
+   ;
+   };
+
 mmc1_pins: pinmux_mmc1_pins {
 pinctrl-single,pins = 
 0x114 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc1_clk.sdmmc1_clk */
@@ -93,6 +102,11 @@
 clock-frequency = 40;
  };

+mcbsp2 {
+   pinctrl-names = default;
+   pinctrl-0 = mcbsp2_pins;
+};
+
  mmc1 {
pinctrl-names = default;
pinctrl-0 = mmc1_pins;
--
1.8.1.2



Hi Benoit,

I sent this patch some time ago to be merged as a fix for 3.11, but
seems was not merged. Would be possible include this patch in these
series ?


I'm really sorry I missed that one :-(
I'm applying it right now, and will update my pull request.

Thanks,
Benoit


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


Re: [GIT PULL] ARM: DTS: Fix OMAP bugs for 3.12-rc

2013-09-18 Thread Benoit Cousson

Hi Enric

On 18/09/2013 12:24, Enric Balletbo Serra wrote:

Hi Benoit,


2013/9/18 Benoit Cousson bcous...@baylibre.com:

Hi Tony,

Please pull few fixes for OMAP DTS.

Thanks,
Benoit



The following changes since commit 272b98c6455f00884f0350f775c5342358ebb73f:

   Linux 3.12-rc1 (2013-09-16 16:17:51 -0400)

are available in the git repository at:

   git://git.kernel.org/pub/scm/linux/kernel/git/bcousson/linux-omap-dt.git 
tags/for_3.12-rc2/dts_signed

for you to fetch changes up to 775d2418f309052641d94c896f73dc779cf7ba1b:

   ARM: dts: Fix muxing and regulator for wl12xx on the SDIO bus for blaze 
(2013-09-18 11:14:42 +0200)


Fix BBB LDO voltage to avoid HDMI destruction
Fix OMAP5 wrong attribute
Fix typo in beagle xM strings


Felipe Balbi (2):
   ARM: dts: OMAP5: fix reg property size
   ARM: dts: OMAP5: fix ocp2scp DTS data

Koen Kooi (1):
   ARM: dts: am335x-bone*: add DT for BeagleBone Black

Robert Nelson (1):
   ARM: dts: omap3-beagle-xm: fix string error in compatible property

Tony Lindgren (2):
   ARM: dts: Fix muxing and regulator for wl12xx on the SDIO bus for 
pandaboard
   ARM: dts: Fix muxing and regulator for wl12xx on the SDIO bus for blaze

  arch/arm/boot/dts/Makefile|   1 +
  arch/arm/boot/dts/am335x-bone-common.dtsi | 262 ++
  arch/arm/boot/dts/am335x-bone.dts | 256 +
  arch/arm/boot/dts/am335x-boneblack.dts|  17 ++
  arch/arm/boot/dts/omap3-beagle-xm.dts |   2 +-
  arch/arm/boot/dts/omap4-panda-common.dtsi |  46 +-
  arch/arm/boot/dts/omap4-sdp.dts   |  39 -
  arch/arm/boot/dts/omap5.dtsi  |   7 +-
  8 files changed, 369 insertions(+), 261 deletions(-)
  create mode 100644 arch/arm/boot/dts/am335x-bone-common.dtsi
  create mode 100644 arch/arm/boot/dts/am335x-boneblack.dts
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


On July 5th, I sent the following patch

 http://www.spinics.net/lists/linux-omap/msg96935.html

and on Sep 10th I sent the same patch rebased with upstream and Acked
by Javier. I consider this patch as a fix, as is required to make the
sound work on IGEP boards but it's not included in this pull request.
Maybe you forget it due your email change. Can you consider adding
this patch, at least, in your next pull request? Thanks in advance.


Sorry I missed it, and will send an updated pull-request in five minutes 
from now... If you do not see anything from me after 6 minutes you can 
complain.



Merci beaucoup,


De rien.

Regards,
Benoit

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


[GIT PULL] ARM: DTS: Fix OMAP bugs for 3.12-rc, take #2

2013-09-18 Thread Benoit Cousson
Hi Tony,

Please pull few fixes for OMAP DTS. This take #2 contains one more fix I missed 
from Enric.

Thanks,
Benoit



The following changes since commit 272b98c6455f00884f0350f775c5342358ebb73f:

  Linux 3.12-rc1 (2013-09-16 16:17:51 -0400)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/bcousson/linux-omap-dt.git 
tags/for_3.12-rc2/dts_signed

for you to fetch changes up to 65399f03266e138506417920952e1c8ed022ec47:

  ARM: dts: igep00x0: Add pinmux configuration for MCBSP2 (2013-09-18 14:31:58 
+0200)


Fix BBB LDO voltage to avoid HDMI destruction
Fix OMAP5 wrong attribute
Fix typo in beagle xM strings
Fix missing pinmux and regulator for OMAP4 wifi
Fix missing pinmux for igep headset


Enric Balletbo i Serra (1):
  ARM: dts: igep00x0: Add pinmux configuration for MCBSP2

Felipe Balbi (2):
  ARM: dts: OMAP5: fix reg property size
  ARM: dts: OMAP5: fix ocp2scp DTS data

Koen Kooi (1):
  ARM: dts: am335x-bone*: add DT for BeagleBone Black

Robert Nelson (1):
  ARM: dts: omap3-beagle-xm: fix string error in compatible property

Tony Lindgren (2):
  ARM: dts: Fix muxing and regulator for wl12xx on the SDIO bus for 
pandaboard
  ARM: dts: Fix muxing and regulator for wl12xx on the SDIO bus for blaze

 arch/arm/boot/dts/Makefile|   1 +
 arch/arm/boot/dts/am335x-bone-common.dtsi | 262 ++
 arch/arm/boot/dts/am335x-bone.dts | 256 +
 arch/arm/boot/dts/am335x-boneblack.dts|  17 ++
 arch/arm/boot/dts/omap3-beagle-xm.dts |   2 +-
 arch/arm/boot/dts/omap3-igep.dtsi |  14 ++
 arch/arm/boot/dts/omap4-panda-common.dtsi |  46 +-
 arch/arm/boot/dts/omap4-sdp.dts   |  39 -
 arch/arm/boot/dts/omap5.dtsi  |   7 +-
 9 files changed, 383 insertions(+), 261 deletions(-)
 create mode 100644 arch/arm/boot/dts/am335x-bone-common.dtsi
 create mode 100644 arch/arm/boot/dts/am335x-boneblack.dts
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


  1   2   3   4   5   6   7   8   9   10   >