[PATCH 3/4] ARM: dts: sbc-t3x: add TV out display alias

2014-11-23 Thread Dmitry Lifshitz
Add display alias for TV out.

Signed-off-by: Dmitry Lifshitz lifsh...@compulab.co.il
---
 arch/arm/boot/dts/omap3-sbc-t3517.dts |1 +
 arch/arm/boot/dts/omap3-sbc-t3530.dts |1 +
 arch/arm/boot/dts/omap3-sbc-t3730.dts |1 +
 3 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-sbc-t3517.dts 
b/arch/arm/boot/dts/omap3-sbc-t3517.dts
index 4ec5d86..1798653 100644
--- a/arch/arm/boot/dts/omap3-sbc-t3517.dts
+++ b/arch/arm/boot/dts/omap3-sbc-t3517.dts
@@ -11,6 +11,7 @@
 
aliases {
display0 = dvi0;
+   display1 = tv0;
};
 
/* Only one GPMC smsc9220 on SBC-T3517, CM-T3517 uses am35x Ethernet */
diff --git a/arch/arm/boot/dts/omap3-sbc-t3530.dts 
b/arch/arm/boot/dts/omap3-sbc-t3530.dts
index 8dfc1df..c994f0f 100644
--- a/arch/arm/boot/dts/omap3-sbc-t3530.dts
+++ b/arch/arm/boot/dts/omap3-sbc-t3530.dts
@@ -11,6 +11,7 @@
 
aliases {
display0 = dvi0;
+   display1 = tv0;
};
 };
 
diff --git a/arch/arm/boot/dts/omap3-sbc-t3730.dts 
b/arch/arm/boot/dts/omap3-sbc-t3730.dts
index 6b69864..5bdddf2 100644
--- a/arch/arm/boot/dts/omap3-sbc-t3730.dts
+++ b/arch/arm/boot/dts/omap3-sbc-t3730.dts
@@ -11,6 +11,7 @@
 
aliases {
display0 = dvi0;
+   display1 = tv0;
};
 };
 
-- 
1.7.5.4

--
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


[PATCH 0/4] ARM: dts: sbc-t3x: add audio and TV out support

2014-11-23 Thread Dmitry Lifshitz
Add support for more SBC-T3x single board computers features:

* Audio on CM-T3x30
* TV out on CM-T3x

This patch set adds missing I2C1 pinmux required for CM-T3x EEPROM and 
CM-T3x30 audio support.

Dmitry Lifshitz (4):
  ARM: dts: cm-t3x: add I2C1 pinmux
  ARM: dts: cm-t3x: add TV out support
  ARM: dts: sbc-t3x: add TV out display alias
  ARM: dts: sbc-t3x30: add audio support

 arch/arm/boot/dts/omap3-cm-t3x.dtsi   |   48 +
 arch/arm/boot/dts/omap3-cm-t3x30.dtsi |   18 
 arch/arm/boot/dts/omap3-sb-t35.dtsi   |   16 +++
 arch/arm/boot/dts/omap3-sbc-t3517.dts |1 +
 arch/arm/boot/dts/omap3-sbc-t3530.dts |1 +
 arch/arm/boot/dts/omap3-sbc-t3730.dts |1 +
 6 files changed, 85 insertions(+), 0 deletions(-)

-- 
1.7.5.4

--
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


[PATCH 2/4] ARM: dts: cm-t3x: add TV out support

2014-11-23 Thread Dmitry Lifshitz
Add TV out support.

Signed-off-by: Dmitry Lifshitz lifsh...@compulab.co.il
---
 arch/arm/boot/dts/omap3-cm-t3x.dtsi   |   22 ++
 arch/arm/boot/dts/omap3-cm-t3x30.dtsi |4 
 2 files changed, 26 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-cm-t3x.dtsi 
b/arch/arm/boot/dts/omap3-cm-t3x.dtsi
index 620a3f4..63bea24 100644
--- a/arch/arm/boot/dts/omap3-cm-t3x.dtsi
+++ b/arch/arm/boot/dts/omap3-cm-t3x.dtsi
@@ -56,6 +56,17 @@
regulator-min-microvolt = 330;
regulator-max-microvolt = 330;
};
+
+   tv0: connector@1 {
+   compatible = svideo-connector;
+   label = tv;
+
+   port {
+   tv_connector_in: endpoint {
+   remote-endpoint = venc_out;
+   };
+   };
+   };
 };
 
 omap3_pmx_core {
@@ -221,3 +232,14 @@
linux,wakeup;
};
 };
+
+venc {
+   status = ok;
+
+   port {
+   venc_out: endpoint {
+   remote-endpoint = tv_connector_in;
+   ti,channels = 2;
+   };
+   };
+};
diff --git a/arch/arm/boot/dts/omap3-cm-t3x30.dtsi 
b/arch/arm/boot/dts/omap3-cm-t3x30.dtsi
index 3cbaf98..9cc7185 100644
--- a/arch/arm/boot/dts/omap3-cm-t3x30.dtsi
+++ b/arch/arm/boot/dts/omap3-cm-t3x30.dtsi
@@ -66,6 +66,10 @@
 #include twl4030_omap3.dtsi
 #include dt-bindings/input/input.h
 
+venc {
+   vdda-supply = vdac;
+};
+
 mmc1 {
vmmc-supply = vmmc1;
 };
-- 
1.7.5.4

--
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


[PATCH 4/4] ARM: dts: sbc-t3x30: add audio support

2014-11-23 Thread Dmitry Lifshitz
Add audio related DT nodes

Signed-off-by: Dmitry Lifshitz lifsh...@compulab.co.il
---
 arch/arm/boot/dts/omap3-cm-t3x.dtsi   |   16 
 arch/arm/boot/dts/omap3-cm-t3x30.dtsi |   14 ++
 arch/arm/boot/dts/omap3-sb-t35.dtsi   |   16 
 3 files changed, 46 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-cm-t3x.dtsi 
b/arch/arm/boot/dts/omap3-cm-t3x.dtsi
index 63bea24..6ea6d46 100644
--- a/arch/arm/boot/dts/omap3-cm-t3x.dtsi
+++ b/arch/arm/boot/dts/omap3-cm-t3x.dtsi
@@ -155,6 +155,15 @@
OMAP3_CORE1_IOPAD(0x21bc, PIN_INPUT_PULLUP | MUX_MODE0) 
/* i2c1_sda */
;
};
+
+   mcbsp2_pins: pinmux_mcbsp2_pins {
+   pinctrl-single,pins = 
+   OMAP3_CORE1_IOPAD(0x213c, PIN_INPUT | MUX_MODE0)
/* mcbsp2_fsx */
+   OMAP3_CORE1_IOPAD(0x213e, PIN_INPUT | MUX_MODE0)
/* mcbsp2_clkx */
+   OMAP3_CORE1_IOPAD(0x2140, PIN_INPUT | MUX_MODE0)
/* mcbsp2_dr */
+   OMAP3_CORE1_IOPAD(0x2142, PIN_OUTPUT | MUX_MODE0)   
/* mcbsp2_dx */
+   ;
+   };
 };
 
 uart3 {
@@ -243,3 +252,10 @@
};
};
 };
+
+mcbsp2 {
+   status = ok;
+
+   pinctrl-names = default;
+   pinctrl-0 = mcbsp2_pins;
+};
diff --git a/arch/arm/boot/dts/omap3-cm-t3x30.dtsi 
b/arch/arm/boot/dts/omap3-cm-t3x30.dtsi
index 9cc7185..9a4a3ab 100644
--- a/arch/arm/boot/dts/omap3-cm-t3x30.dtsi
+++ b/arch/arm/boot/dts/omap3-cm-t3x30.dtsi
@@ -10,6 +10,14 @@
cpu0-supply = vcc;
};
};
+
+   sound {
+   compatible = ti,omap-twl4030;
+   ti,model = cm-t35;
+
+   ti,mcbsp = mcbsp2;
+   ti,codec = twl_audio;
+   };
 };
 
 omap3_pmx_core {
@@ -59,6 +67,12 @@
reg = 0x48;
interrupts = 7; /* SYS_NIRQ cascaded to intc */
interrupt-parent = intc;
+
+   twl_audio: audio {
+   compatible = ti,twl4030-audio;
+   codec {
+   };
+   };
};
 };
 
diff --git a/arch/arm/boot/dts/omap3-sb-t35.dtsi 
b/arch/arm/boot/dts/omap3-sb-t35.dtsi
index aff733e..827f614 100644
--- a/arch/arm/boot/dts/omap3-sb-t35.dtsi
+++ b/arch/arm/boot/dts/omap3-sb-t35.dtsi
@@ -43,6 +43,16 @@
};
};
};
+
+   audio_amp: audio_amp {
+   compatible = regulator-fixed;
+   regulator-name = audio_amp;
+   pinctrl-names = default;
+   pinctrl-0 = sb_t35_audio_amp;
+   gpio = gpio2 29 GPIO_ACTIVE_LOW;   /* gpio_61 */
+   enable-active-low;
+   regulator-always-on;
+   };
 };
 
 omap3_pmx_core {
@@ -65,6 +75,12 @@
OMAP3_CORE1_IOPAD(0x21c4, PIN_INPUT_PULLUP | MUX_MODE0) 
/* i2c3_sda */
;
};
+
+   sb_t35_audio_amp: pinmux_sb_t35_audio_amp {
+   pinctrl-single,pins = 
+   OMAP3_CORE1_IOPAD(0x20c8, PIN_OUTPUT | MUX_MODE4) /* 
gpmc_nbe1.gpio_61 */
+   ;
+   };
 };
 
 i2c3 {
-- 
1.7.5.4

--
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


[PATCH 1/4] ARM: dts: cm-t3x: add I2C1 pinmux

2014-11-23 Thread Dmitry Lifshitz
Add missing I2C1 pinmux setup.

Signed-off-by: Dmitry Lifshitz lifsh...@compulab.co.il
---
 arch/arm/boot/dts/omap3-cm-t3x.dtsi |   10 ++
 1 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-cm-t3x.dtsi 
b/arch/arm/boot/dts/omap3-cm-t3x.dtsi
index 3a98ce1..620a3f4 100644
--- a/arch/arm/boot/dts/omap3-cm-t3x.dtsi
+++ b/arch/arm/boot/dts/omap3-cm-t3x.dtsi
@@ -137,6 +137,13 @@
OMAP3_CORE1_IOPAD(0x21ce, PIN_INPUT_PULLDOWN | 
MUX_MODE0) /* mcspi1_cs0 */
;
};
+
+   i2c1_pins: pinmux_i2c1_pins {
+   pinctrl-single,pins = 
+   OMAP3_CORE1_IOPAD(0x21ba, PIN_INPUT_PULLUP | MUX_MODE0) 
/* i2c1_scl */
+   OMAP3_CORE1_IOPAD(0x21bc, PIN_INPUT_PULLUP | MUX_MODE0) 
/* i2c1_sda */
+   ;
+   };
 };
 
 uart3 {
@@ -155,6 +162,9 @@
 };
 
 i2c1 {
+   pinctrl-names = default;
+   pinctrl-0 = i2c1_pins;
+
clock-frequency = 40;
 
at24@50 {
-- 
1.7.5.4

--
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


[PATCH 4/9] sound/soc/omap/am3517evm.c: fix error return code

2014-11-23 Thread Julia Lawall
From: Julia Lawall julia.law...@lip6.fr

It was forgotten to initialize ret to the result of calling
snd_soc_dai_set_sysclk, unlike at the other calls in the same function.

A simplified version of the semantic match that finds this problem is as
follows: (http://coccinelle.lip6.fr/)

// smpl
(
if@p1 (\(ret  0\|ret != 0\))
 { ... return ret; }
|
ret@p1 = 0
)
... when != ret = e1
when != ret
*if(...)
{
  ... when != ret = e2
  when forall
 return ret;
}

// /smpl

Signed-off-by: Julia Lawall julia.law...@lip6.fr

---
 sound/soc/omap/am3517evm.c |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/omap/am3517evm.c b/sound/soc/omap/am3517evm.c
index 009533a..df65f98 100644
--- a/sound/soc/omap/am3517evm.c
+++ b/sound/soc/omap/am3517evm.c
@@ -59,7 +59,7 @@ static int am3517evm_hw_params(struct snd_pcm_substream 
*substream,
return ret;
}
 
-   snd_soc_dai_set_sysclk(cpu_dai, OMAP_MCBSP_FSR_SRC_FSX, 0,
+   ret = snd_soc_dai_set_sysclk(cpu_dai, OMAP_MCBSP_FSR_SRC_FSX, 0,
SND_SOC_CLOCK_IN);
if (ret  0) {
printk(KERN_ERR can't set CPU system clock 
OMAP_MCBSP_FSR_SRC_FSX\n);

--
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


[PATCH 1/1] video: fbdev-OMAP2: Deletion of unnecessary checks before the function call i2c_put_adapter

2014-11-23 Thread SF Markus Elfring
From: Markus Elfring elfr...@users.sourceforge.net
Date: Sun, 23 Nov 2014 14:07:22 +0100

The i2c_put_adapter() function tests whether its argument is NULL
and then returns immediately. Thus the test around the call is not needed.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring elfr...@users.sourceforge.net
---
 drivers/video/fbdev/omap2/displays-new/connector-dvi.c | 9 +++--
 1 file changed, 3 insertions(+), 6 deletions(-)

diff --git a/drivers/video/fbdev/omap2/displays-new/connector-dvi.c 
b/drivers/video/fbdev/omap2/displays-new/connector-dvi.c
index 74de2bc..196c61a 100644
--- a/drivers/video/fbdev/omap2/displays-new/connector-dvi.c
+++ b/drivers/video/fbdev/omap2/displays-new/connector-dvi.c
@@ -262,8 +262,7 @@ static int dvic_probe_pdata(struct platform_device *pdev)
 
in = omap_dss_find_output(pdata-source);
if (in == NULL) {
-   if (ddata-i2c_adapter)
-   i2c_put_adapter(ddata-i2c_adapter);
+   i2c_put_adapter(ddata-i2c_adapter);
 
dev_err(pdev-dev, Failed to find video source\n);
return -EPROBE_DEFER;
@@ -352,8 +351,7 @@ static int dvic_probe(struct platform_device *pdev)
 err_reg:
omap_dss_put_device(ddata-in);
 
-   if (ddata-i2c_adapter)
-   i2c_put_adapter(ddata-i2c_adapter);
+   i2c_put_adapter(ddata-i2c_adapter);
 
return r;
 }
@@ -371,8 +369,7 @@ static int __exit dvic_remove(struct platform_device *pdev)
 
omap_dss_put_device(in);
 
-   if (ddata-i2c_adapter)
-   i2c_put_adapter(ddata-i2c_adapter);
+   i2c_put_adapter(ddata-i2c_adapter);
 
return 0;
 }
-- 
2.1.3

--
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/4] i2c: omap: implement workaround for handling invalid BB-bit values

2014-11-23 Thread Alexander Kochetkov

23 нояб. 2014 г., в 7:43, Felipe Balbi ba...@ti.com написал(а):

 maybe there was a typo? I tested on v3.18-rc3 :-)

I do my tests on kernel from angstrom with almost all i2c-omap patches 
backported from linux/master.
Then I rebased them to wrong (old) kernel version and posted to the list.

Angstrom kernel is from meta-ti layer. It's the same kernel as for arago.
http://arago-project.org/wiki/index.php/Main_Page

I would really like to switch to the recent kernel, but I don't know how good 
codec engine (CE) is supported on it.
Initially all ti drivers for codec engine was done for 2.6.x kernels and later 
some of them was ported for 3.2.x.

Felipe, do you know how CE is supported on v3.18-rc3?

Regards,
Alexander.

--
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 01/11] pinctrl: exynos: Add BUS1 pin controller for exynos7

2014-11-23 Thread Vivek Gautam
Hi Alim,


On Sat, Nov 22, 2014 at 7:07 PM, Alim Akhtar alim.akh...@gmail.com wrote:
 Hi Vivek,

 On Fri, Nov 21, 2014 at 7:05 PM, Vivek Gautam gautam.vi...@samsung.com 
 wrote:
 USB and Power regulator on Exynos7 require gpios available
 in BUS1 pin controller block.
 So adding the BUS1 pinctrl support.

 Signed-off-by: Naveen Krishna Ch naveenkrishna...@gmail.com
 Signed-off-by: Vivek Gautam gautam.vi...@samsung.com
 Cc: Linus Walleij linus.wall...@linaro.org
 ---
  drivers/pinctrl/samsung/pinctrl-exynos.c |   12 
  1 file changed, 12 insertions(+)

 diff --git a/drivers/pinctrl/samsung/pinctrl-exynos.c 
 b/drivers/pinctrl/samsung/pinctrl-exynos.c
 index d5d4cfc..caca5b5 100644
 --- a/drivers/pinctrl/samsung/pinctrl-exynos.c
 +++ b/drivers/pinctrl/samsung/pinctrl-exynos.c
 @@ -1300,6 +1300,13 @@ static const struct samsung_pin_bank_data 
 exynos7_pin_banks7[] __initconst = {
 EXYNOS_PIN_BANK_EINTG(8, 0x060, gpr3, 0x0c),
  };

 +/* pin banks of exynos7 pin-controller - BUS1 */
 +static const struct samsung_pin_bank_data exynos7_pin_banks8[] __initconst 
 = {
 +   EXYNOS_PIN_BANK_EINTG(8, 0x020, gpf0, 0x00),
 +   EXYNOS_PIN_BANK_EINTG(8, 0x0a0, gpf4, 0x10),
 +   EXYNOS_PIN_BANK_EINTG(6, 0x120, gph1, 0x20),
 +};
 +
 Looks like you are just trying to touch pin banks only related to USB
 stuffs, but as this patch does not have any dependencies on other
 patches in this series, will you consider adding other pin banks of
 BUS1, just for completeness of BUS1 pin-controller.

True, this just touches the USB related pinctrl.
Will add the rest pin banks of BUS1 for completeness.
Thanks for pointing out. :-)

[snip]



-- 
Best Regards
Vivek Gautam
Samsung RD Institute, Bangalore
India
--
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