2014-01-25 21:29:35

by Marek Belisko

[permalink] [raw]
Subject: [PATCH 0/9] ARM: dts: omap3-gta04: Various devicetree updates.

This pathes fix some wrong property issues and add some new devices to
devicetree. This was tested on linux-next (next-20140124).

Marek Belisko (6):
ARM: dts: omap3-gta04: Fix mmc1 properties.
ARM: dts: omap3-gta04: Add basic sound support.
ARM: dts: omap3-gta04: Add twl4030 charger.
ARM: dts: omap3-gta04: Add touchscreen properties.
ARM: dts: omap3-gta04: Add support for magnetometer.
ARM: dts: omap3-gta04: Add ti,omap36xx to compatible property to avoid
problems with booting.

NeilBrown (3):
ARM: dts: omap3-gta04: Fix 'aux' gpio key flags.
ARM: dts: omap3-gta04: Add bma180 accelerometer.
ARM: dts: omap3-gta04: Enable mmc2 for wifi.

arch/arm/boot/dts/omap3-gta04.dts | 58 ++++++++++++++++++++++++++++++++++++---
1 file changed, 54 insertions(+), 4 deletions(-)

--
1.8.3.2


2014-01-25 21:29:38

by Marek Belisko

[permalink] [raw]
Subject: [PATCH 1/9] ARM: dts: omap3-gta04: Fix 'aux' gpio key flags.

From: NeilBrown <[email protected]>

It should be ACTIVE_HIGH.

Signed-off-by: NeilBrown <[email protected]>
---
arch/arm/boot/dts/omap3-gta04.dts | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/omap3-gta04.dts b/arch/arm/boot/dts/omap3-gta04.dts
index b9b55c9..9d37184 100644
--- a/arch/arm/boot/dts/omap3-gta04.dts
+++ b/arch/arm/boot/dts/omap3-gta04.dts
@@ -32,7 +32,7 @@
aux-button {
label = "aux";
linux,code = <169>;
- gpios = <&gpio1 7 GPIO_ACTIVE_LOW>;
+ gpios = <&gpio1 7 GPIO_ACTIVE_HIGH>;
gpio-key,wakeup;
};
};
--
1.8.3.2

2014-01-25 21:29:49

by Marek Belisko

[permalink] [raw]
Subject: [PATCH 6/9] ARM: dts: omap3-gta04: Add twl4030 charger.

Signed-off-by: Marek Belisko <[email protected]>
---
arch/arm/boot/dts/omap3-gta04.dts | 4 ++++
1 file changed, 4 insertions(+)

diff --git a/arch/arm/boot/dts/omap3-gta04.dts b/arch/arm/boot/dts/omap3-gta04.dts
index a924a843..f72e408 100644
--- a/arch/arm/boot/dts/omap3-gta04.dts
+++ b/arch/arm/boot/dts/omap3-gta04.dts
@@ -198,3 +198,7 @@
pinctrl-0 = <&uart3_pins>;
};

+&charger {
+ bb_uvolt = <3200000>;
+ bb_uamp = <150>;
+};
--
1.8.3.2

2014-01-25 21:29:45

by Marek Belisko

[permalink] [raw]
Subject: [PATCH 2/9] ARM: dts: omap3-gta04: Add bma180 accelerometer.

From: NeilBrown <[email protected]>

Signed-off-by: NeilBrown <[email protected]>
---
arch/arm/boot/dts/omap3-gta04.dts | 8 ++++++++
1 file changed, 8 insertions(+)

diff --git a/arch/arm/boot/dts/omap3-gta04.dts b/arch/arm/boot/dts/omap3-gta04.dts
index 9d37184..e315675 100644
--- a/arch/arm/boot/dts/omap3-gta04.dts
+++ b/arch/arm/boot/dts/omap3-gta04.dts
@@ -94,6 +94,14 @@
reg = <0x77>;
};

+ /* accelerometer */
+ bma180@41 {
+ compatible = "bosch,bma180";
+ reg = <0x41>;
+ interrupt-parent = <&gpio3>;
+ interrupts = <19 IRQ_TYPE_LEVEL_HIGH>;
+ };
+
/* leds */
tca6507@45 {
compatible = "ti,tca6507";
--
1.8.3.2

2014-01-25 21:29:51

by Marek Belisko

[permalink] [raw]
Subject: [PATCH 7/9] ARM: dts: omap3-gta04: Add touchscreen properties.

Signed-off-by: Marek Belisko <[email protected]>
---
arch/arm/boot/dts/omap3-gta04.dts | 10 ++++++++++
1 file changed, 10 insertions(+)

diff --git a/arch/arm/boot/dts/omap3-gta04.dts b/arch/arm/boot/dts/omap3-gta04.dts
index f72e408..151ed3b 100644
--- a/arch/arm/boot/dts/omap3-gta04.dts
+++ b/arch/arm/boot/dts/omap3-gta04.dts
@@ -150,6 +150,16 @@
reg = <0x4>;
};
};
+
+ /* touchscreen */
+ tsc2007@48 {
+ compatible = "ti,tsc2007";
+ reg = <0x48>;
+ interrupt-parent = <&gpio6>;
+ interrupts = <0 IRQ_TYPE_EDGE_FALLING>;
+ gpios = <&gpio6 0 GPIO_ACTIVE_LOW>;
+ ti,x-plate-ohms = <600>;
+ };
};

&i2c3 {
--
1.8.3.2

2014-01-25 21:30:00

by Marek Belisko

[permalink] [raw]
Subject: [PATCH 9/9] ARM: dts: omap3-gta04: Add ti,omap36xx to compatible property to avoid problems with booting.

Without that change booting leads to crash with more warnings like below:
[ 0.284454] omap_hwmod: uart4: cannot clk_get main_clk uart4_fck
[ 0.284484] omap_hwmod: uart4: cannot _init_clocks
[ 0.284484] ------------[ cut here ]------------
[ 0.284545] WARNING: CPU: 0 PID: 1 at arch/arm/mach-omap2/omap_hwmod.c:2543 _init+0x300/0x3e4()
[ 0.284545] omap_hwmod: uart4: couldn't init clocks
[ 0.284576] Modules linked in:
[ 0.284606] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.13.0-next-20140124-00020-gd2aefec-dirty #26
[ 0.284637] [<c00151c0>] (unwind_backtrace) from [<c0011e20>] (show_stack+0x10/0x14)
[ 0.284667] [<c0011e20>] (show_stack) from [<c0568544>] (dump_stack+0x7c/0x94)
[ 0.284729] [<c0568544>] (dump_stack) from [<c003ff94>] (warn_slowpath_common+0x6c/0x90)
[ 0.284729] [<c003ff94>] (warn_slowpath_common) from [<c003ffe8>] (warn_slowpath_fmt+0x30/0x40)
[ 0.284759] [<c003ffe8>] (warn_slowpath_fmt) from [<c07d1be8>] (_init+0x300/0x3e4)
[ 0.284790] [<c07d1be8>] (_init) from [<c07d217c>] (__omap_hwmod_setup_all+0x40/0x8c)
[ 0.284820] [<c07d217c>] (__omap_hwmod_setup_all) from [<c0008918>] (do_one_initcall+0xe8/0x14c)
[ 0.284851] [<c0008918>] (do_one_initcall) from [<c07c5c18>] (kernel_init_freeable+0x104/0x1c8)
[ 0.284881] [<c07c5c18>] (kernel_init_freeable) from [<c0563524>] (kernel_init+0x8/0x118)
[ 0.284912] [<c0563524>] (kernel_init) from [<c000e368>] (ret_from_fork+0x14/0x2c)
[ 0.285064] ---[ end trace 63de210ad43b627d ]---

Reference:
https://lkml.org/lkml/2013/10/8/553

Signed-off-by: Marek Belisko <[email protected]>
---
arch/arm/boot/dts/omap3-gta04.dts | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/omap3-gta04.dts b/arch/arm/boot/dts/omap3-gta04.dts
index ea1b94d..998fe1e 100644
--- a/arch/arm/boot/dts/omap3-gta04.dts
+++ b/arch/arm/boot/dts/omap3-gta04.dts
@@ -13,7 +13,7 @@

/ {
model = "OMAP3 GTA04";
- compatible = "ti,omap3-gta04", "ti,omap3";
+ compatible = "ti,omap3-gta04", "ti,omap36xx", "ti,omap3";

cpus {
cpu@0 {
--
1.8.3.2

2014-01-25 21:29:57

by Marek Belisko

[permalink] [raw]
Subject: [PATCH 8/9] ARM: dts: omap3-gta04: Add support for magnetometer.

Signed-off-by: NeilBrown <[email protected]>
---
arch/arm/boot/dts/omap3-gta04.dts | 6 ++++++
1 file changed, 6 insertions(+)

diff --git a/arch/arm/boot/dts/omap3-gta04.dts b/arch/arm/boot/dts/omap3-gta04.dts
index 151ed3b..ea1b94d 100644
--- a/arch/arm/boot/dts/omap3-gta04.dts
+++ b/arch/arm/boot/dts/omap3-gta04.dts
@@ -100,6 +100,12 @@
regulator-max-microvolt = <3150000>;
};
};
+
+ /* compass aka magnetometer */
+ hmc5843@1e {
+ compatible = "honeywell,hmc5843";
+ reg = <0x1e>;
+ };
};

#include "twl4030.dtsi"
--
1.8.3.2

2014-01-25 21:31:25

by Marek Belisko

[permalink] [raw]
Subject: [PATCH 5/9] ARM: dts: omap3-gta04: Add basic sound support.

Signed-off-by: NeilBrown <[email protected]>
---
arch/arm/boot/dts/omap3-gta04.dts | 15 +++++++++++++++
1 file changed, 15 insertions(+)

diff --git a/arch/arm/boot/dts/omap3-gta04.dts b/arch/arm/boot/dts/omap3-gta04.dts
index 7e09410..a924a843 100644
--- a/arch/arm/boot/dts/omap3-gta04.dts
+++ b/arch/arm/boot/dts/omap3-gta04.dts
@@ -36,6 +36,14 @@
gpio-key,wakeup;
};
};
+
+ sound {
+ compatible = "ti,omap-twl4030";
+ ti,model = "gta04";
+
+ ti,mcbsp = <&mcbsp2>;
+ ti,codec = <&twl_audio>;
+ };
};

&omap3_pmx_core {
@@ -79,6 +87,13 @@
reg = <0x48>;
interrupts = <7>; /* SYS_NIRQ cascaded to intc */
interrupt-parent = <&intc>;
+
+ twl_audio: audio {
+ compatible = "ti,twl4030-audio";
+ codec {
+ };
+ };
+
vaux4: regulator-vaux4 {
compatible = "ti,twl4030-vaux4";
regulator-min-microvolt = <2800000>;
--
1.8.3.2

2014-01-25 21:29:43

by Marek Belisko

[permalink] [raw]
Subject: [PATCH 3/9] ARM: dts: omap3-gta04: Fix mmc1 properties.

Does not have an aux supply, and must be non-removable.

Otherwise it is removed during suspend and filesystem gets confused.

Signed-off-by: NeilBrown <[email protected]>
---
arch/arm/boot/dts/omap3-gta04.dts | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/omap3-gta04.dts b/arch/arm/boot/dts/omap3-gta04.dts
index e315675..6011151 100644
--- a/arch/arm/boot/dts/omap3-gta04.dts
+++ b/arch/arm/boot/dts/omap3-gta04.dts
@@ -149,8 +149,8 @@
pinctrl-names = "default";
pinctrl-0 = <&mmc1_pins>;
vmmc-supply = <&vmmc1>;
- vmmc_aux-supply = <&vsim>;
bus-width = <4>;
+ ti,non-removable;
};

&mmc2 {
--
1.8.3.2

2014-01-25 21:31:56

by Marek Belisko

[permalink] [raw]
Subject: [PATCH 4/9] ARM: dts: omap3-gta04: Enable mmc2 for wifi.

From: NeilBrown <[email protected]>

This requires vaux4.

Reset line isn't used yet, so wifi isn't reliable.
But it does work once per boot.

Signed-off-by: NeilBrown <[email protected]>
---
arch/arm/boot/dts/omap3-gta04.dts | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/omap3-gta04.dts b/arch/arm/boot/dts/omap3-gta04.dts
index 6011151..7e09410 100644
--- a/arch/arm/boot/dts/omap3-gta04.dts
+++ b/arch/arm/boot/dts/omap3-gta04.dts
@@ -79,6 +79,11 @@
reg = <0x48>;
interrupts = <7>; /* SYS_NIRQ cascaded to intc */
interrupt-parent = <&intc>;
+ vaux4: regulator-vaux4 {
+ compatible = "ti,twl4030-vaux4";
+ regulator-min-microvolt = <2800000>;
+ regulator-max-microvolt = <3150000>;
+ };
};
};

@@ -154,7 +159,9 @@
};

&mmc2 {
- status = "disabled";
+ vmmc-supply = <&vaux4>;
+ bus-width = <4>;
+ ti,non-removable;
};

&mmc3 {
--
1.8.3.2

2014-02-13 23:08:32

by Tony Lindgren

[permalink] [raw]
Subject: Re: [PATCH 1/9] ARM: dts: omap3-gta04: Fix 'aux' gpio key flags.

* Marek Belisko <[email protected]> [140125 13:31]:
> From: NeilBrown <[email protected]>
>
> It should be ACTIVE_HIGH.
>
> Signed-off-by: NeilBrown <[email protected]>
> ---
> arch/arm/boot/dts/omap3-gta04.dts | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/arm/boot/dts/omap3-gta04.dts b/arch/arm/boot/dts/omap3-gta04.dts
> index b9b55c9..9d37184 100644
> --- a/arch/arm/boot/dts/omap3-gta04.dts
> +++ b/arch/arm/boot/dts/omap3-gta04.dts
> @@ -32,7 +32,7 @@
> aux-button {
> label = "aux";
> linux,code = <169>;
> - gpios = <&gpio1 7 GPIO_ACTIVE_LOW>;
> + gpios = <&gpio1 7 GPIO_ACTIVE_HIGH>;
> gpio-key,wakeup;
> };
> };

Picking this one into omap-for-v3.14/fixes thanks.

Tony

2014-02-13 23:09:08

by Tony Lindgren

[permalink] [raw]
Subject: Re: [PATCH 3/9] ARM: dts: omap3-gta04: Fix mmc1 properties.

* Marek Belisko <[email protected]> [140125 13:31]:
> Does not have an aux supply, and must be non-removable.
>
> Otherwise it is removed during suspend and filesystem gets confused.
>
> Signed-off-by: NeilBrown <[email protected]>
> ---
> arch/arm/boot/dts/omap3-gta04.dts | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/arm/boot/dts/omap3-gta04.dts b/arch/arm/boot/dts/omap3-gta04.dts
> index e315675..6011151 100644
> --- a/arch/arm/boot/dts/omap3-gta04.dts
> +++ b/arch/arm/boot/dts/omap3-gta04.dts
> @@ -149,8 +149,8 @@
> pinctrl-names = "default";
> pinctrl-0 = <&mmc1_pins>;
> vmmc-supply = <&vmmc1>;
> - vmmc_aux-supply = <&vsim>;
> bus-width = <4>;
> + ti,non-removable;
> };
>
> &mmc2 {

Taking this too into omap-for-v3.14/fixes.

Tony

2014-02-28 22:25:25

by Tony Lindgren

[permalink] [raw]
Subject: Re: [PATCH 5/9] ARM: dts: omap3-gta04: Add basic sound support.

* Marek Belisko <[email protected]> [140125 13:31]:

Hmm care to add descriptions and repost the remaining patches
that I did not yet pick up for the fixes?

> Signed-off-by: NeilBrown <[email protected]>

Hmm should this also have From: NeilBrown <[email protected]>?

Also, while at it, maybe change your long time habit of adding
a period to the end of the subject line? That is of course
if you don't insist on having it, it's not usually used if
you look at git log --pretty=oneline :)

Regards,

Tony

> ---
> arch/arm/boot/dts/omap3-gta04.dts | 15 +++++++++++++++
> 1 file changed, 15 insertions(+)
>
> diff --git a/arch/arm/boot/dts/omap3-gta04.dts b/arch/arm/boot/dts/omap3-gta04.dts
> index 7e09410..a924a843 100644
> --- a/arch/arm/boot/dts/omap3-gta04.dts
> +++ b/arch/arm/boot/dts/omap3-gta04.dts
> @@ -36,6 +36,14 @@
> gpio-key,wakeup;
> };
> };
> +
> + sound {
> + compatible = "ti,omap-twl4030";
> + ti,model = "gta04";
> +
> + ti,mcbsp = <&mcbsp2>;
> + ti,codec = <&twl_audio>;
> + };
> };
>
> &omap3_pmx_core {
> @@ -79,6 +87,13 @@
> reg = <0x48>;
> interrupts = <7>; /* SYS_NIRQ cascaded to intc */
> interrupt-parent = <&intc>;
> +
> + twl_audio: audio {
> + compatible = "ti,twl4030-audio";
> + codec {
> + };
> + };
> +
> vaux4: regulator-vaux4 {
> compatible = "ti,twl4030-vaux4";
> regulator-min-microvolt = <2800000>;
> --
> 1.8.3.2
>

2014-02-28 22:40:05

by Belisko Marek

[permalink] [raw]
Subject: Re: [PATCH 5/9] ARM: dts: omap3-gta04: Add basic sound support.

Hi Tony,

On Fri, Feb 28, 2014 at 11:25 PM, Tony Lindgren <[email protected]> wrote:
> * Marek Belisko <[email protected]> [140125 13:31]:
>
> Hmm care to add descriptions and repost the remaining patches
> that I did not yet pick up for the fixes?
Sure I'll do.
>
>> Signed-off-by: NeilBrown <[email protected]>
>
> Hmm should this also have From: NeilBrown <[email protected]>?
Maybe I did some changes and forgot add my Signed-off-by? I'll recheck.
>
> Also, while at it, maybe change your long time habit of adding
> a period to the end of the subject line? That is of course
> if you don't insist on having it, it's not usually used if
> you look at git log --pretty=oneline :)
Sure . Thanks for notice ;). It there possibility that missing patches
go to 3.15?
>
> Regards,
>
> Tony
>
>> ---
>> arch/arm/boot/dts/omap3-gta04.dts | 15 +++++++++++++++
>> 1 file changed, 15 insertions(+)
>>
>> diff --git a/arch/arm/boot/dts/omap3-gta04.dts b/arch/arm/boot/dts/omap3-gta04.dts
>> index 7e09410..a924a843 100644
>> --- a/arch/arm/boot/dts/omap3-gta04.dts
>> +++ b/arch/arm/boot/dts/omap3-gta04.dts
>> @@ -36,6 +36,14 @@
>> gpio-key,wakeup;
>> };
>> };
>> +
>> + sound {
>> + compatible = "ti,omap-twl4030";
>> + ti,model = "gta04";
>> +
>> + ti,mcbsp = <&mcbsp2>;
>> + ti,codec = <&twl_audio>;
>> + };
>> };
>>
>> &omap3_pmx_core {
>> @@ -79,6 +87,13 @@
>> reg = <0x48>;
>> interrupts = <7>; /* SYS_NIRQ cascaded to intc */
>> interrupt-parent = <&intc>;
>> +
>> + twl_audio: audio {
>> + compatible = "ti,twl4030-audio";
>> + codec {
>> + };
>> + };
>> +
>> vaux4: regulator-vaux4 {
>> compatible = "ti,twl4030-vaux4";
>> regulator-min-microvolt = <2800000>;
>> --
>> 1.8.3.2
>>

BR,

marek

--
as simple and primitive as possible
-------------------------------------------------
Marek Belisko - OPEN-NANDRA
Freelance Developer

Ruska Nova Ves 219 | Presov, 08005 Slovak Republic
Tel: +421 915 052 184
skype: marekwhite
twitter: #opennandra
web: http://open-nandra.com

2014-02-28 22:47:07

by Tony Lindgren

[permalink] [raw]
Subject: Re: [PATCH 5/9] ARM: dts: omap3-gta04: Add basic sound support.

* Belisko Marek <[email protected]> [140228 14:42]:
> Sure . Thanks for notice ;). It there possibility that missing patches
> go to 3.15?

Sure if you update them over next few days.

Regards,

Tony