All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM
@ 2010-12-07 12:40 Koen Kooi
  2010-12-07 12:54 ` Koen Kooi
                   ` (2 more replies)
  0 siblings, 3 replies; 14+ messages in thread
From: Koen Kooi @ 2010-12-07 12:40 UTC (permalink / raw)
  To: linux-omap; +Cc: Koen Kooi, Koen Kooi

From: Koen Kooi <koen@dominion.thruhere.net>

Signed-off-by: Koen Kooi <koen@beagleboard.org>
---
 arch/arm/mach-omap2/board-omap3beagle.c |   27 +++++++++++++++++++++++----
 1 files changed, 23 insertions(+), 4 deletions(-)

diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c
index f1a8ede..9c9bd96 100644
--- a/arch/arm/mach-omap2/board-omap3beagle.c
+++ b/arch/arm/mach-omap2/board-omap3beagle.c
@@ -297,12 +297,31 @@ static int beagle_twl_gpio_setup(struct device *dev,
 	gpio_request(gpio + 1, "EHCI_nOC");
 	gpio_direction_input(gpio + 1);
 
-	/* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, active low) */
+	/* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, XM active
+	 * high / others active low) */
 	gpio_request(gpio + TWL4030_GPIO_MAX, "nEN_USB_PWR");
-	gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
+	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
+		gpio_direction_output(gpio + TWL4030_GPIO_MAX, 1);
+	else
+		gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
+
+	/* DVI reset GPIO is different between revisions */
+	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
+		beagle_dvi_device.reset_gpio = 129;
+	else
+		beagle_dvi_device.reset_gpio = 170;
+
+	 /* Power on DVI, Serial and PWR led */
+	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
+		gpio_request(gpio + 1, "nDVI_PWR_EN");
+		gpio_direction_output(gpio + 1, 0);
+	}
 
-	/* TWL4030_GPIO_MAX + 1 == ledB, PMU_STAT (out, active low LED) */
-	gpio_leds[2].gpio = gpio + TWL4030_GPIO_MAX + 1;
+	/* Power on camera interface on P7/P8 or DVI on A2 and beyond */
+	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
+		gpio_request(gpio + 2, "CAM_EN");
+		gpio_direction_output(gpio + 2, 1);
+	}
 
 	return 0;
 }
-- 
1.6.6.1


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

* Re: [PATCH] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM
  2010-12-07 12:40 [PATCH] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM Koen Kooi
@ 2010-12-07 12:54 ` Koen Kooi
  2010-12-14 14:11 ` Koen Kooi
  2010-12-19 14:42 ` [PATCH v2] " Koen Kooi
  2 siblings, 0 replies; 14+ messages in thread
From: Koen Kooi @ 2010-12-07 12:54 UTC (permalink / raw)
  To: linux-omap@vger.kernel.org List


Op 7 dec 2010, om 13:40 heeft Koen Kooi het volgende geschreven:
> 
> +	/* Power on camera interface on P7/P8 or DVI on A2 and beyond */
> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
> +		gpio_request(gpio + 2, "CAM_EN");
> +		gpio_direction_output(gpio + 2, 1);
> +	}


For people testing this patch, you won't get DVI working properly till you apply this patch:

http://sakoman.com/cgi-bin/gitweb.cgi?p=linux-omap-2.6.git;a=commitdiff;h=9fd4ea134e6282be6ceb06a8d79a3b07af2297ae

regards,

Koen

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

* Re: [PATCH] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM
  2010-12-07 12:40 [PATCH] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM Koen Kooi
  2010-12-07 12:54 ` Koen Kooi
@ 2010-12-14 14:11 ` Koen Kooi
  2010-12-14 14:24   ` Anand Gadiyar
  2010-12-19 14:42 ` [PATCH v2] " Koen Kooi
  2 siblings, 1 reply; 14+ messages in thread
From: Koen Kooi @ 2010-12-14 14:11 UTC (permalink / raw)
  To: Linux OMAP Mailing List

Any comments on this?

Op 7 dec 2010, om 13:40 heeft Koen Kooi het volgende geschreven:

> From: Koen Kooi <koen@dominion.thruhere.net>
> 
> Signed-off-by: Koen Kooi <koen@beagleboard.org>
> ---
> arch/arm/mach-omap2/board-omap3beagle.c |   27 +++++++++++++++++++++++----
> 1 files changed, 23 insertions(+), 4 deletions(-)
> 
> diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c
> index f1a8ede..9c9bd96 100644
> --- a/arch/arm/mach-omap2/board-omap3beagle.c
> +++ b/arch/arm/mach-omap2/board-omap3beagle.c
> @@ -297,12 +297,31 @@ static int beagle_twl_gpio_setup(struct device *dev,
> 	gpio_request(gpio + 1, "EHCI_nOC");
> 	gpio_direction_input(gpio + 1);
> 
> -	/* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, active low) */
> +	/* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, XM active
> +	 * high / others active low) */
> 	gpio_request(gpio + TWL4030_GPIO_MAX, "nEN_USB_PWR");
> -	gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
> +		gpio_direction_output(gpio + TWL4030_GPIO_MAX, 1);
> +	else
> +		gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
> +
> +	/* DVI reset GPIO is different between revisions */
> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
> +		beagle_dvi_device.reset_gpio = 129;
> +	else
> +		beagle_dvi_device.reset_gpio = 170;
> +
> +	 /* Power on DVI, Serial and PWR led */
> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
> +		gpio_request(gpio + 1, "nDVI_PWR_EN");
> +		gpio_direction_output(gpio + 1, 0);
> +	}
> 
> -	/* TWL4030_GPIO_MAX + 1 == ledB, PMU_STAT (out, active low LED) */
> -	gpio_leds[2].gpio = gpio + TWL4030_GPIO_MAX + 1;
> +	/* Power on camera interface on P7/P8 or DVI on A2 and beyond */
> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
> +		gpio_request(gpio + 2, "CAM_EN");
> +		gpio_direction_output(gpio + 2, 1);
> +	}
> 
> 	return 0;
> }
> -- 
> 1.6.6.1
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 


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

* Re: [PATCH] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM
  2010-12-14 14:11 ` Koen Kooi
@ 2010-12-14 14:24   ` Anand Gadiyar
  2010-12-18  2:07     ` Tony Lindgren
  0 siblings, 1 reply; 14+ messages in thread
From: Anand Gadiyar @ 2010-12-14 14:24 UTC (permalink / raw)
  To: Koen Kooi; +Cc: Linux OMAP Mailing List

On 12/14/2010 7:41 PM, Koen Kooi wrote:
> Any comments on this?
> 
> Op 7 dec 2010, om 13:40 heeft Koen Kooi het volgende geschreven:
> 
>> From: Koen Kooi <koen@dominion.thruhere.net>
>>


You may want to add a description here. For instance you're
making the PMU STAT led disappear - and I'm not sure it's
deliberate.

>> Signed-off-by: Koen Kooi <koen@beagleboard.org>
>> ---
>> arch/arm/mach-omap2/board-omap3beagle.c |   27 +++++++++++++++++++++++----
>> 1 files changed, 23 insertions(+), 4 deletions(-)
>>
>> diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c
>> index f1a8ede..9c9bd96 100644
>> --- a/arch/arm/mach-omap2/board-omap3beagle.c
>> +++ b/arch/arm/mach-omap2/board-omap3beagle.c
>> @@ -297,12 +297,31 @@ static int beagle_twl_gpio_setup(struct device *dev,
>> 	gpio_request(gpio + 1, "EHCI_nOC");
>> 	gpio_direction_input(gpio + 1);
>>
>> -	/* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, active low) */
>> +	/* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, XM active
>> +	 * high / others active low) */


Just nitpicking. The multi-line comments are not as per
Documentation/CodingStyle.




>> 	gpio_request(gpio + TWL4030_GPIO_MAX, "nEN_USB_PWR");
>> -	gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
>> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
>> +		gpio_direction_output(gpio + TWL4030_GPIO_MAX, 1);
>> +	else
>> +		gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
>> +
>> +	/* DVI reset GPIO is different between revisions */
>> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
>> +		beagle_dvi_device.reset_gpio = 129;
>> +	else
>> +		beagle_dvi_device.reset_gpio = 170;
>> +
>> +	 /* Power on DVI, Serial and PWR led */
>> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
>> +		gpio_request(gpio + 1, "nDVI_PWR_EN");
>> +		gpio_direction_output(gpio + 1, 0);
>> +	}
>>
>> -	/* TWL4030_GPIO_MAX + 1 == ledB, PMU_STAT (out, active low LED) */
>> -	gpio_leds[2].gpio = gpio + TWL4030_GPIO_MAX + 1;

This disappeared. So no more PMU STAT led?

>> +	/* Power on camera interface on P7/P8 or DVI on A2 and beyond */
>> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
>> +		gpio_request(gpio + 2, "CAM_EN");
>> +		gpio_direction_output(gpio + 2, 1);
>> +	}
>>
>> 	return 0;
>> }

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

* Re: [PATCH] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM
  2010-12-14 14:24   ` Anand Gadiyar
@ 2010-12-18  2:07     ` Tony Lindgren
  2010-12-18  8:22       ` Koen Kooi
  0 siblings, 1 reply; 14+ messages in thread
From: Tony Lindgren @ 2010-12-18  2:07 UTC (permalink / raw)
  To: Anand Gadiyar; +Cc: Koen Kooi, Linux OMAP Mailing List

* Anand Gadiyar <gadiyar@ti.com> [101214 06:25]:
> On 12/14/2010 7:41 PM, Koen Kooi wrote:
> > Any comments on this?
...

> >>
> >> -	/* TWL4030_GPIO_MAX + 1 == ledB, PMU_STAT (out, active low LED) */
> >> -	gpio_leds[2].gpio = gpio + TWL4030_GPIO_MAX + 1;
> 
> This disappeared. So no more PMU STAT led?

Koen, any update on this?

Tony

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

* Re: [PATCH] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM
  2010-12-18  2:07     ` Tony Lindgren
@ 2010-12-18  8:22       ` Koen Kooi
  0 siblings, 0 replies; 14+ messages in thread
From: Koen Kooi @ 2010-12-18  8:22 UTC (permalink / raw)
  To: Tony Lindgren; +Cc: Anand Gadiyar, Linux OMAP Mailing List


Op 18 dec 2010, om 03:07 heeft Tony Lindgren het volgende geschreven:

> * Anand Gadiyar <gadiyar@ti.com> [101214 06:25]:
>> On 12/14/2010 7:41 PM, Koen Kooi wrote:
>>> Any comments on this?
> ...
> 
>>>> 
>>>> -	/* TWL4030_GPIO_MAX + 1 == ledB, PMU_STAT (out, active low LED) */
>>>> -	gpio_leds[2].gpio = gpio + TWL4030_GPIO_MAX + 1;
>> 
>> This disappeared. So no more PMU STAT led?
> 
> Koen, any update on this?

I'll send and updated patch after the weekend.

regards,

Koen

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

* [PATCH v2] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM
  2010-12-07 12:40 [PATCH] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM Koen Kooi
  2010-12-07 12:54 ` Koen Kooi
  2010-12-14 14:11 ` Koen Kooi
@ 2010-12-19 14:42 ` Koen Kooi
  2010-12-19 14:47   ` Nishanth Menon
                     ` (2 more replies)
  2 siblings, 3 replies; 14+ messages in thread
From: Koen Kooi @ 2010-12-19 14:42 UTC (permalink / raw)
  To: linux-omap; +Cc: Koen Kooi, Koen Kooi

Signed-off-by: Koen Kooi <koen@beagleboard.org>

---

Changes since v1:
	* Reenable the PMU stat LED

 arch/arm/mach-omap2/board-omap3beagle.c |   26 ++++++++++++++++++++++++--
 1 files changed, 24 insertions(+), 2 deletions(-)

diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c
index f1a8ede..4756ac7 100644
--- a/arch/arm/mach-omap2/board-omap3beagle.c
+++ b/arch/arm/mach-omap2/board-omap3beagle.c
@@ -297,13 +297,35 @@ static int beagle_twl_gpio_setup(struct device *dev,
 	gpio_request(gpio + 1, "EHCI_nOC");
 	gpio_direction_input(gpio + 1);
 
-	/* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, active low) */
+	/* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, XM active
+	 * high / others active low) */
 	gpio_request(gpio + TWL4030_GPIO_MAX, "nEN_USB_PWR");
-	gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
+	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
+		gpio_direction_output(gpio + TWL4030_GPIO_MAX, 1);
+	else
+		gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
+
+	/* DVI reset GPIO is different between revisions */
+	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
+		beagle_dvi_device.reset_gpio = 129;
+	else
+		beagle_dvi_device.reset_gpio = 170;
+
+	 /* Power on DVI, Serial and PWR led */
+	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
+		gpio_request(gpio + 1, "nDVI_PWR_EN");
+		gpio_direction_output(gpio + 1, 0);
+	}
 
 	/* TWL4030_GPIO_MAX + 1 == ledB, PMU_STAT (out, active low LED) */
 	gpio_leds[2].gpio = gpio + TWL4030_GPIO_MAX + 1;
 
+	/* Power on camera interface on P7/P8 or DVI on A2 and beyond */
+	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
+		gpio_request(gpio + 2, "CAM_EN");
+		gpio_direction_output(gpio + 2, 1);
+	}
+
 	return 0;
 }
 
-- 
1.6.6.1


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

* Re: [PATCH v2] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM
  2010-12-19 14:42 ` [PATCH v2] " Koen Kooi
@ 2010-12-19 14:47   ` Nishanth Menon
  2010-12-19 14:56     ` Koen Kooi
  2010-12-20 18:48   ` Kevin Hilman
  2011-01-06 18:29   ` Nishanth Menon
  2 siblings, 1 reply; 14+ messages in thread
From: Nishanth Menon @ 2010-12-19 14:47 UTC (permalink / raw)
  To: Koen Kooi; +Cc: linux-omap, Koen Kooi, Koen Kooi

Koen Kooi wrote, on 12/19/2010 08:42 AM:
$subject - should'nt you be doing this in separate patches? easier to 
track with git bisect at a later date than a whole sale change?

also could you reword it as:
omap3: beagleboard: power on ECHI

and so on?

btw, why are we enabling camera here? should'nt that be done in camera's 
probe function? no?

> Signed-off-by: Koen Kooi<koen@beagleboard.org>
>
> ---
>
> Changes since v1:
> 	* Reenable the PMU stat LED
>
>   arch/arm/mach-omap2/board-omap3beagle.c |   26 ++++++++++++++++++++++++--
>   1 files changed, 24 insertions(+), 2 deletions(-)
>
> diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c
> index f1a8ede..4756ac7 100644
> --- a/arch/arm/mach-omap2/board-omap3beagle.c
> +++ b/arch/arm/mach-omap2/board-omap3beagle.c
> @@ -297,13 +297,35 @@ static int beagle_twl_gpio_setup(struct device *dev,
>   	gpio_request(gpio + 1, "EHCI_nOC");
>   	gpio_direction_input(gpio + 1);
>
> -	/* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, active low) */
> +	/* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, XM active
> +	 * high / others active low) */
>   	gpio_request(gpio + TWL4030_GPIO_MAX, "nEN_USB_PWR");
> -	gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
> +		gpio_direction_output(gpio + TWL4030_GPIO_MAX, 1);
> +	else
> +		gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
> +
> +	/* DVI reset GPIO is different between revisions */
> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
> +		beagle_dvi_device.reset_gpio = 129;
> +	else
> +		beagle_dvi_device.reset_gpio = 170;
> +
> +	 /* Power on DVI, Serial and PWR led */
> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
> +		gpio_request(gpio + 1, "nDVI_PWR_EN");
> +		gpio_direction_output(gpio + 1, 0);
> +	}
>
>   	/* TWL4030_GPIO_MAX + 1 == ledB, PMU_STAT (out, active low LED) */
>   	gpio_leds[2].gpio = gpio + TWL4030_GPIO_MAX + 1;
>
> +	/* Power on camera interface on P7/P8 or DVI on A2 and beyond */
> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
> +		gpio_request(gpio + 2, "CAM_EN");
> +		gpio_direction_output(gpio + 2, 1);
> +	}
> +
>   	return 0;
>   }
>


-- 
Regards,
Nishanth Menon

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

* Re: [PATCH v2] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM
  2010-12-19 14:47   ` Nishanth Menon
@ 2010-12-19 14:56     ` Koen Kooi
  2010-12-19 15:22       ` Nishanth Menon
  0 siblings, 1 reply; 14+ messages in thread
From: Koen Kooi @ 2010-12-19 14:56 UTC (permalink / raw)
  To: Nishanth Menon; +Cc: Linux OMAP Mailing List


Op 19 dec 2010, om 15:47 heeft Nishanth Menon het volgende geschreven:

> Koen Kooi wrote, on 12/19/2010 08:42 AM:
> $subject - should'nt you be doing this in separate patches? easier to track with git bisect at a later date than a whole sale change?

Is that really needed?

> btw, why are we enabling camera here? should'nt that be done in camera's probe function? no?

On P7/P8 it's the camera, but on A2 and above it's the LDO that powers the TFP410, so if you want to have output on DVI you need to turn it on. I'm not sure if it should be part of the DVI init since it has different functions on different board revisions.

regards,

Koen 

>> Signed-off-by: Koen Kooi<koen@beagleboard.org>
>> 
>> ---
>> 
>> Changes since v1:
>> 	* Reenable the PMU stat LED
>> 
>>  arch/arm/mach-omap2/board-omap3beagle.c |   26 ++++++++++++++++++++++++--
>>  1 files changed, 24 insertions(+), 2 deletions(-)
>> 
>> diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c
>> index f1a8ede..4756ac7 100644
>> --- a/arch/arm/mach-omap2/board-omap3beagle.c
>> +++ b/arch/arm/mach-omap2/board-omap3beagle.c
>> @@ -297,13 +297,35 @@ static int beagle_twl_gpio_setup(struct device *dev,
>>  	gpio_request(gpio + 1, "EHCI_nOC");
>>  	gpio_direction_input(gpio + 1);
>> 
>> -	/* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, active low) */
>> +	/* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, XM active
>> +	 * high / others active low) */
>>  	gpio_request(gpio + TWL4030_GPIO_MAX, "nEN_USB_PWR");
>> -	gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
>> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
>> +		gpio_direction_output(gpio + TWL4030_GPIO_MAX, 1);
>> +	else
>> +		gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
>> +
>> +	/* DVI reset GPIO is different between revisions */
>> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
>> +		beagle_dvi_device.reset_gpio = 129;
>> +	else
>> +		beagle_dvi_device.reset_gpio = 170;
>> +
>> +	 /* Power on DVI, Serial and PWR led */
>> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
>> +		gpio_request(gpio + 1, "nDVI_PWR_EN");
>> +		gpio_direction_output(gpio + 1, 0);
>> +	}
>> 
>>  	/* TWL4030_GPIO_MAX + 1 == ledB, PMU_STAT (out, active low LED) */
>>  	gpio_leds[2].gpio = gpio + TWL4030_GPIO_MAX + 1;
>> 
>> +	/* Power on camera interface on P7/P8 or DVI on A2 and beyond */
>> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
>> +		gpio_request(gpio + 2, "CAM_EN");
>> +		gpio_direction_output(gpio + 2, 1);
>> +	}
>> +
>>  	return 0;
>>  }
>> 
> 
> 
> -- 
> Regards,
> Nishanth Menon


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

* Re: [PATCH v2] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM
  2010-12-19 14:56     ` Koen Kooi
@ 2010-12-19 15:22       ` Nishanth Menon
  0 siblings, 0 replies; 14+ messages in thread
From: Nishanth Menon @ 2010-12-19 15:22 UTC (permalink / raw)
  To: Koen Kooi; +Cc: Linux OMAP Mailing List

Koen Kooi wrote, on 12/19/2010 08:56 AM:
>
> Op 19 dec 2010, om 15:47 heeft Nishanth Menon het volgende geschreven:
>
>> Koen Kooi wrote, on 12/19/2010 08:42 AM:
>> $subject - should'nt you be doing this in separate patches? easier to track with git bisect at a later date than a whole sale change?
>
> Is that really needed?
it is usually recommended to keep each separate functionality 
introduced/fixed independent of the other.

>
>> btw, why are we enabling camera here? should'nt that be done in camera's probe function? no?
>
> On P7/P8 it's the camera, but on A2 and above it's the LDO that powers the TFP410, so if you want to have output on DVI you need to turn it on.
 >I'm not sure if it should be part of the DVI init since it has 
different functions on different board revisions.
P7/P8 were not production Beagles if my memory serves me right.. DVI 
init makes more sense to me.

-- 
Regards,
Nishanth Menon

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

* Re: [PATCH v2] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM
  2010-12-19 14:42 ` [PATCH v2] " Koen Kooi
  2010-12-19 14:47   ` Nishanth Menon
@ 2010-12-20 18:48   ` Kevin Hilman
  2011-01-06 18:29   ` Nishanth Menon
  2 siblings, 0 replies; 14+ messages in thread
From: Kevin Hilman @ 2010-12-20 18:48 UTC (permalink / raw)
  To: Koen Kooi; +Cc: linux-omap, Koen Kooi, Koen Kooi

Koen Kooi <koen.kooi@gmail.com> writes:

> Signed-off-by: Koen Kooi <koen@beagleboard.org>

-ENO_DESCRIPTIVE_CHANGELOG

Also, please Cc linux-arm-kernel for patches intended for upstream.

Thanks,

Kevin

> ---
>
> Changes since v1:
> 	* Reenable the PMU stat LED
>
>  arch/arm/mach-omap2/board-omap3beagle.c |   26 ++++++++++++++++++++++++--
>  1 files changed, 24 insertions(+), 2 deletions(-)
>
> diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c
> index f1a8ede..4756ac7 100644
> --- a/arch/arm/mach-omap2/board-omap3beagle.c
> +++ b/arch/arm/mach-omap2/board-omap3beagle.c
> @@ -297,13 +297,35 @@ static int beagle_twl_gpio_setup(struct device *dev,
>  	gpio_request(gpio + 1, "EHCI_nOC");
>  	gpio_direction_input(gpio + 1);
>  
> -	/* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, active low) */
> +	/* TWL4030_GPIO_MAX + 0 == ledA, EHCI nEN_USB_PWR (out, XM active
> +	 * high / others active low) */
>  	gpio_request(gpio + TWL4030_GPIO_MAX, "nEN_USB_PWR");
> -	gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
> +		gpio_direction_output(gpio + TWL4030_GPIO_MAX, 1);
> +	else
> +		gpio_direction_output(gpio + TWL4030_GPIO_MAX, 0);
> +
> +	/* DVI reset GPIO is different between revisions */
> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM)
> +		beagle_dvi_device.reset_gpio = 129;
> +	else
> +		beagle_dvi_device.reset_gpio = 170;
> +
> +	 /* Power on DVI, Serial and PWR led */
> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
> +		gpio_request(gpio + 1, "nDVI_PWR_EN");
> +		gpio_direction_output(gpio + 1, 0);
> +	}
>  
>  	/* TWL4030_GPIO_MAX + 1 == ledB, PMU_STAT (out, active low LED) */
>  	gpio_leds[2].gpio = gpio + TWL4030_GPIO_MAX + 1;
>  
> +	/* Power on camera interface on P7/P8 or DVI on A2 and beyond */
> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
> +		gpio_request(gpio + 2, "CAM_EN");
> +		gpio_direction_output(gpio + 2, 1);
> +	}
> +
>  	return 0;
>  }

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

* Re: [PATCH v2] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM
  2010-12-19 14:42 ` [PATCH v2] " Koen Kooi
  2010-12-19 14:47   ` Nishanth Menon
  2010-12-20 18:48   ` Kevin Hilman
@ 2011-01-06 18:29   ` Nishanth Menon
  2011-01-06 18:33     ` Koen Kooi
  2 siblings, 1 reply; 14+ messages in thread
From: Nishanth Menon @ 2011-01-06 18:29 UTC (permalink / raw)
  To: Koen Kooi; +Cc: linux-omap, Koen Kooi, Koen Kooi

Koen,
Apologies on a late response.

Koen Kooi had written, on 12/19/2010 08:42 AM, the following:
[...]
> diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c
> index f1a8ede..4756ac7 100644
> --- a/arch/arm/mach-omap2/board-omap3beagle.c
> +++ b/arch/arm/mach-omap2/board-omap3beagle.c
> @@ -297,13 +297,35 @@ static int beagle_twl_gpio_setup(struct device *dev,
[..]
> +
> +	 /* Power on DVI, Serial and PWR led */
> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
> +		gpio_request(gpio + 1, "nDVI_PWR_EN");
> +		gpio_direction_output(gpio + 1, 0);
> +	}
earlier in this function, we do:
	gpio_request(gpio + 1, "EHCI_nOC");
   	gpio_direction_input(gpio + 1);
here we do
gpio_request(gpio + 1, "nDVI_PWR_EN");
gpio_direction_output(gpio + 1, 0);

I am confused. is gpio+1 input or output line? and what level should it 
be on?

-- 
Regards,
Nishanth Menon

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

* Re: [PATCH v2] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM
  2011-01-06 18:29   ` Nishanth Menon
@ 2011-01-06 18:33     ` Koen Kooi
  2011-01-06 19:53       ` Coley, Gerald
  0 siblings, 1 reply; 14+ messages in thread
From: Koen Kooi @ 2011-01-06 18:33 UTC (permalink / raw)
  To: Nishanth Menon; +Cc: Koen Kooi, l-o Mailing List, Gerald Coley


Op 6 jan 2011, om 19:29 heeft Nishanth Menon het volgende geschreven:

> Koen,
> Apologies on a late response.
> 
> Koen Kooi had written, on 12/19/2010 08:42 AM, the following:
> [...]
>> diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c
>> index f1a8ede..4756ac7 100644
>> --- a/arch/arm/mach-omap2/board-omap3beagle.c
>> +++ b/arch/arm/mach-omap2/board-omap3beagle.c
>> @@ -297,13 +297,35 @@ static int beagle_twl_gpio_setup(struct device *dev,
> [..]
>> +
>> +	 /* Power on DVI, Serial and PWR led */
>> +	if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
>> +		gpio_request(gpio + 1, "nDVI_PWR_EN");
>> +		gpio_direction_output(gpio + 1, 0);
>> +	}
> earlier in this function, we do:
> 	gpio_request(gpio + 1, "EHCI_nOC");
>  	gpio_direction_input(gpio + 1);
> here we do
> gpio_request(gpio + 1, "nDVI_PWR_EN");
> gpio_direction_output(gpio + 1, 0);
> 
> I am confused. is gpio+1 input or output line? and what level should it be on?

On early revB prototypes it was used to sense USB overcurrent, I'm not sure what the current status is for that pin on revB and revC, but on xM it controls the DVI, serial and led block.

Adding Gerald to CC: to see if he has some pearls of wisdom on this :)

regards,

Koen

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

* RE: [PATCH v2] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM
  2011-01-06 18:33     ` Koen Kooi
@ 2011-01-06 19:53       ` Coley, Gerald
  0 siblings, 0 replies; 14+ messages in thread
From: Coley, Gerald @ 2011-01-06 19:53 UTC (permalink / raw)
  To: Koen Kooi, Menon, Nishanth; +Cc: Koen Kooi, l-o Mailing List

You are correct. On the -xM over current is from the USB HUB driver as there are four ports. So that gets detected by the USB hub device and reported back.


Gerald


-----Original Message-----
From: Koen Kooi [mailto:koen@dominion.thruhere.net]
Sent: Thursday, January 06, 2011 12:33 PM
To: Menon, Nishanth
Cc: Koen Kooi; l-o Mailing List; Coley, Gerald
Subject: Re: [PATCH v2] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM


Op 6 jan 2011, om 19:29 heeft Nishanth Menon het volgende geschreven:

> Koen,
> Apologies on a late response.
>
> Koen Kooi had written, on 12/19/2010 08:42 AM, the following:
> [...]
>> diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c
>> index f1a8ede..4756ac7 100644
>> --- a/arch/arm/mach-omap2/board-omap3beagle.c
>> +++ b/arch/arm/mach-omap2/board-omap3beagle.c
>> @@ -297,13 +297,35 @@ static int beagle_twl_gpio_setup(struct device *dev,
> [..]
>> +
>> +     /* Power on DVI, Serial and PWR led */
>> +    if (omap3_beagle_get_rev() == OMAP3BEAGLE_BOARD_XM) {
>> +            gpio_request(gpio + 1, "nDVI_PWR_EN");
>> +            gpio_direction_output(gpio + 1, 0);
>> +    }
> earlier in this function, we do:
>       gpio_request(gpio + 1, "EHCI_nOC");
>       gpio_direction_input(gpio + 1);
> here we do
> gpio_request(gpio + 1, "nDVI_PWR_EN");
> gpio_direction_output(gpio + 1, 0);
>
> I am confused. is gpio+1 input or output line? and what level should it be on?

On early revB prototypes it was used to sense USB overcurrent, I'm not sure what the current status is for that pin on revB and revC, but on xM it controls the DVI, serial and led block.

Adding Gerald to CC: to see if he has some pearls of wisdom on this :)

regards,

Koen

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

end of thread, other threads:[~2011-01-06 19:53 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-12-07 12:40 [PATCH] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM Koen Kooi
2010-12-07 12:54 ` Koen Kooi
2010-12-14 14:11 ` Koen Kooi
2010-12-14 14:24   ` Anand Gadiyar
2010-12-18  2:07     ` Tony Lindgren
2010-12-18  8:22       ` Koen Kooi
2010-12-19 14:42 ` [PATCH v2] " Koen Kooi
2010-12-19 14:47   ` Nishanth Menon
2010-12-19 14:56     ` Koen Kooi
2010-12-19 15:22       ` Nishanth Menon
2010-12-20 18:48   ` Kevin Hilman
2011-01-06 18:29   ` Nishanth Menon
2011-01-06 18:33     ` Koen Kooi
2011-01-06 19:53       ` Coley, Gerald

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.