public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH 1/5] tbs2910: support for usb otg host mode
@ 2015-05-05 21:09 Soeren Moch
  2015-05-05 21:09 ` [U-Boot] [PATCH 2/5] tbs2910: only enable vga output for stdout/stderr when hdmi detected Soeren Moch
                   ` (4 more replies)
  0 siblings, 5 replies; 10+ messages in thread
From: Soeren Moch @ 2015-05-05 21:09 UTC (permalink / raw)
  To: u-boot

Add support for USB OTG host mode. Only high speed devices supported so far
(e.g. usb 2.0 hub required to connect a keyboard).

Signed-off-by: Soeren Moch <smoch@web.de>
---
Cc: Stefano Babic <sbabic@denx.de>
---
 board/tbs/tbs2910/tbs2910.c | 10 ++++++++++
 include/configs/tbs2910.h   |  1 +
 2 files changed, 11 insertions(+)

diff --git a/board/tbs/tbs2910/tbs2910.c b/board/tbs/tbs2910/tbs2910.c
index 42b166d..0b509b6 100644
--- a/board/tbs/tbs2910/tbs2910.c
+++ b/board/tbs/tbs2910/tbs2910.c
@@ -372,6 +372,12 @@ static const struct boot_mode board_boot_modes[] = {
 };
 #endif
 
+#ifdef CONFIG_USB_EHCI_MX6
+static iomux_v3_cfg_t const usb_otg_pads[] = {
+	MX6_PAD_ENET_RX_ER__USB_OTG_ID | MUX_PAD_CTRL(NO_PAD_CTRL),
+};
+#endif
+
 int board_init(void)
 {
 	/* address of boot parameters */
@@ -391,6 +397,10 @@ int board_init(void)
 #ifdef CONFIG_CMD_BMODE
 	add_board_boot_modes(board_boot_modes);
 #endif
+#ifdef CONFIG_USB_EHCI_MX6
+	imx_iomux_v3_setup_multiple_pads(
+		usb_otg_pads, ARRAY_SIZE(usb_otg_pads));
+#endif
 	return 0;
 }
 
diff --git a/include/configs/tbs2910.h b/include/configs/tbs2910.h
index 7089378..e5828e0 100644
--- a/include/configs/tbs2910.h
+++ b/include/configs/tbs2910.h
@@ -163,6 +163,7 @@
 #define CONFIG_USB_EHCI
 #define CONFIG_USB_EHCI_MX6
 #define CONFIG_USB_MAX_CONTROLLER_COUNT 2
+#define CONFIG_EHCI_HCD_INIT_AFTER_RESET
 #define CONFIG_MXC_USB_PORTSC		(PORT_PTS_UTMI | PORT_PTS_PTW)
 #define CONFIG_USB_STORAGE
 #define CONFIG_CMD_USB_MASS_STORAGE
-- 
1.9.1

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

* [U-Boot] [PATCH 2/5] tbs2910: only enable vga output for stdout/stderr when hdmi detected
  2015-05-05 21:09 [U-Boot] [PATCH 1/5] tbs2910: support for usb otg host mode Soeren Moch
@ 2015-05-05 21:09 ` Soeren Moch
  2015-05-15 13:06   ` Stefano Babic
  2015-05-05 21:09 ` [U-Boot] [PATCH 3/5] tbs2910: use default CONFIG_SYS_PBSIZE Soeren Moch
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 10+ messages in thread
From: Soeren Moch @ 2015-05-05 21:09 UTC (permalink / raw)
  To: u-boot

Only enable graphical output for stdout/stderr (and a usb keyboard for stdin)
when a hdmi device is detected.
Serial console is always enabled for stdin/stdout/stderr.

Signed-off-by: Soeren Moch <smoch@web.de>
---
Cc: Stefano Babic <sbabic@denx.de>
---
 include/configs/tbs2910.h | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/include/configs/tbs2910.h b/include/configs/tbs2910.h
index e5828e0..ea4666d 100644
--- a/include/configs/tbs2910.h
+++ b/include/configs/tbs2910.h
@@ -183,7 +183,13 @@
 #ifdef CONFIG_USB_KEYBOARD
 #define CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE
 #define CONFIG_SYS_STDIO_DEREGISTER
-#define CONFIG_PREBOOT "if hdmidet; then usb start; fi"
+#define CONFIG_PREBOOT \
+	"if hdmidet; then " \
+		"usb start; " \
+		"run set_con_usb_hdmi; " \
+	"else " \
+		"run set_con_serial; " \
+	"fi;"
 #endif /* CONFIG_USB_KEYBOARD */
 #endif /* CONFIG_CMD_USB      */
 
@@ -241,9 +247,12 @@
 			"bootm 0x10800000 0x10d00000\0" \
 	"console=ttymxc0\0" \
 	"fan=gpio set 92\0" \
-	"stdin=serial,usbkbd\0" \
-	"stdout=serial,vga\0" \
-	"stderr=serial,vga\0"
+	"set_con_serial=setenv stdin serial; " \
+			"setenv stdout serial; " \
+			"setenv stderr serial;\0" \
+	"set_con_usb_hdmi=setenv stdin serial,usbkbd; " \
+			"setenv stdout serial,vga; " \
+			"setenv stderr serial,vga;\0"
 
 #define CONFIG_BOOTCOMMAND \
 	"mmc rescan; " \
-- 
1.9.1

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

* [U-Boot] [PATCH 3/5] tbs2910: use default CONFIG_SYS_PBSIZE
  2015-05-05 21:09 [U-Boot] [PATCH 1/5] tbs2910: support for usb otg host mode Soeren Moch
  2015-05-05 21:09 ` [U-Boot] [PATCH 2/5] tbs2910: only enable vga output for stdout/stderr when hdmi detected Soeren Moch
@ 2015-05-05 21:09 ` Soeren Moch
  2015-05-15 13:06   ` Stefano Babic
  2015-05-05 21:09 ` [U-Boot] [PATCH 4/5] tbs2910: add CONFIG_SUPPORT_EMMC_BOOT Soeren Moch
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 10+ messages in thread
From: Soeren Moch @ 2015-05-05 21:09 UTC (permalink / raw)
  To: u-boot

Since there is a default CONFIG_SYS_PBSIZE definition in config_fallbacks.h,
this setting is no longer required in board configurations.

Signed-off-by: Soeren Moch <smoch@web.de>
---
Cc: Stefano Babic <sbabic@denx.de>
---
 include/configs/tbs2910.h | 2 --
 1 file changed, 2 deletions(-)

diff --git a/include/configs/tbs2910.h b/include/configs/tbs2910.h
index ea4666d..9efb8c2 100644
--- a/include/configs/tbs2910.h
+++ b/include/configs/tbs2910.h
@@ -39,8 +39,6 @@
 #define CONFIG_CMDLINE_EDITING
 #define CONFIG_SYS_MAXARGS		16
 #define CONFIG_SYS_CBSIZE		1024
-#define CONFIG_SYS_PBSIZE \
-	(CONFIG_SYS_CBSIZE + sizeof(CONFIG_SYS_PROMPT) + 16)
 #define CONFIG_SYS_HZ			1000
 
 /* Physical Memory Map */
-- 
1.9.1

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

* [U-Boot] [PATCH 4/5] tbs2910: add CONFIG_SUPPORT_EMMC_BOOT
  2015-05-05 21:09 [U-Boot] [PATCH 1/5] tbs2910: support for usb otg host mode Soeren Moch
  2015-05-05 21:09 ` [U-Boot] [PATCH 2/5] tbs2910: only enable vga output for stdout/stderr when hdmi detected Soeren Moch
  2015-05-05 21:09 ` [U-Boot] [PATCH 3/5] tbs2910: use default CONFIG_SYS_PBSIZE Soeren Moch
@ 2015-05-05 21:09 ` Soeren Moch
  2015-05-15 13:06   ` Stefano Babic
  2015-05-05 21:09 ` [U-Boot] [PATCH 5/5] tbs2910: add ext4 write support Soeren Moch
  2015-05-15 13:06 ` [U-Boot] [PATCH 1/5] tbs2910: support for usb otg host mode Stefano Babic
  4 siblings, 1 reply; 10+ messages in thread
From: Soeren Moch @ 2015-05-05 21:09 UTC (permalink / raw)
  To: u-boot

Add emmc boot partition commands to be able to select the boot partition.

Signed-off-by: Soeren Moch <smoch@web.de>
---
Cc: Stefano Babic <sbabic@denx.de>
---
 include/configs/tbs2910.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/include/configs/tbs2910.h b/include/configs/tbs2910.h
index 9efb8c2..1f3c3d8 100644
--- a/include/configs/tbs2910.h
+++ b/include/configs/tbs2910.h
@@ -102,6 +102,7 @@
 #define CONFIG_MMC
 #define CONFIG_CMD_MMC
 #define CONFIG_GENERIC_MMC
+#define CONFIG_SUPPORT_EMMC_BOOT
 #define CONFIG_BOUNCE_BUFFER
 
 /* Ethernet */
-- 
1.9.1

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

* [U-Boot] [PATCH 5/5] tbs2910: add ext4 write support
  2015-05-05 21:09 [U-Boot] [PATCH 1/5] tbs2910: support for usb otg host mode Soeren Moch
                   ` (2 preceding siblings ...)
  2015-05-05 21:09 ` [U-Boot] [PATCH 4/5] tbs2910: add CONFIG_SUPPORT_EMMC_BOOT Soeren Moch
@ 2015-05-05 21:09 ` Soeren Moch
  2015-05-11 18:12   ` Soeren Moch
  2015-05-15 13:06 ` [U-Boot] [PATCH 1/5] tbs2910: support for usb otg host mode Stefano Babic
  4 siblings, 1 reply; 10+ messages in thread
From: Soeren Moch @ 2015-05-05 21:09 UTC (permalink / raw)
  To: u-boot

Add CONFIG_CMD_EXT4_WRITE to enable ext4 write support.

Signed-off-by: Soeren Moch <smoch@web.de>
---
Cc: Stefano Babic <sbabic@denx.de>
---
 include/configs/tbs2910.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/include/configs/tbs2910.h b/include/configs/tbs2910.h
index 1f3c3d8..d0d6a30 100644
--- a/include/configs/tbs2910.h
+++ b/include/configs/tbs2910.h
@@ -83,6 +83,7 @@
 
 /* Filesystems / image support */
 #define CONFIG_CMD_EXT4
+#define CONFIG_CMD_EXT4_WRITE
 #define CONFIG_CMD_FAT
 #define CONFIG_DOS_PARTITION
 #define CONFIG_EFI_PARTITION
-- 
1.9.1

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

* [U-Boot] [PATCH 5/5] tbs2910: add ext4 write support
  2015-05-05 21:09 ` [U-Boot] [PATCH 5/5] tbs2910: add ext4 write support Soeren Moch
@ 2015-05-11 18:12   ` Soeren Moch
  0 siblings, 0 replies; 10+ messages in thread
From: Soeren Moch @ 2015-05-11 18:12 UTC (permalink / raw)
  To: u-boot

On 05/05/15 23:09, Soeren Moch wrote:
> Add CONFIG_CMD_EXT4_WRITE to enable ext4 write support.
>
> Signed-off-by: Soeren Moch <smoch@web.de>
> ---
> Cc: Stefano Babic <sbabic@denx.de>
> ---
>   include/configs/tbs2910.h | 1 +
>   1 file changed, 1 insertion(+)
>
> diff --git a/include/configs/tbs2910.h b/include/configs/tbs2910.h
> index 1f3c3d8..d0d6a30 100644
> --- a/include/configs/tbs2910.h
> +++ b/include/configs/tbs2910.h
> @@ -83,6 +83,7 @@
>   
>   /* Filesystems / image support */
>   #define CONFIG_CMD_EXT4
> +#define CONFIG_CMD_EXT4_WRITE
>   #define CONFIG_CMD_FAT
>   #define CONFIG_DOS_PARTITION
>   #define CONFIG_EFI_PARTITION

Stefano,

if the series
[PATCH 0/10 v2] i.MX6: move duplicated options to mx6_common to standardise mx6 config
<http://lists.denx.de/pipermail/u-boot/2015-May/213883.html>

will be applied (what I think would be a good idea), then please drop this patch.

Thanks,
Soeren

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

* [U-Boot] [PATCH 1/5] tbs2910: support for usb otg host mode
  2015-05-05 21:09 [U-Boot] [PATCH 1/5] tbs2910: support for usb otg host mode Soeren Moch
                   ` (3 preceding siblings ...)
  2015-05-05 21:09 ` [U-Boot] [PATCH 5/5] tbs2910: add ext4 write support Soeren Moch
@ 2015-05-15 13:06 ` Stefano Babic
  4 siblings, 0 replies; 10+ messages in thread
From: Stefano Babic @ 2015-05-15 13:06 UTC (permalink / raw)
  To: u-boot

On 05/05/2015 23:09, Soeren Moch wrote:
> Add support for USB OTG host mode. Only high speed devices supported so far
> (e.g. usb 2.0 hub required to connect a keyboard).
> 
> Signed-off-by: Soeren Moch <smoch@web.de>
> ---
> Cc: Stefano Babic <sbabic@denx.de>
> ---

Applied to u-boot-imx, thanks !

Best regards,
     Stefano Babic


-- 
=====================================================================
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de
=====================================================================

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

* [U-Boot] [PATCH 2/5] tbs2910: only enable vga output for stdout/stderr when hdmi detected
  2015-05-05 21:09 ` [U-Boot] [PATCH 2/5] tbs2910: only enable vga output for stdout/stderr when hdmi detected Soeren Moch
@ 2015-05-15 13:06   ` Stefano Babic
  0 siblings, 0 replies; 10+ messages in thread
From: Stefano Babic @ 2015-05-15 13:06 UTC (permalink / raw)
  To: u-boot

On 05/05/2015 23:09, Soeren Moch wrote:
> Only enable graphical output for stdout/stderr (and a usb keyboard for stdin)
> when a hdmi device is detected.
> Serial console is always enabled for stdin/stdout/stderr.
> 
> Signed-off-by: Soeren Moch <smoch@web.de>
> ---
> Cc: Stefano Babic <sbabic@denx.de>
> ---
>  include/configs/tbs2910.h | 17 +++++++++++++----
>  1 file changed, 13 insertions(+), 4 deletions(-)
> 
> diff --git a/include/configs/tbs2910.h b/include/configs/tbs2910.h
> index e5828e0..ea4666d 100644
> --- a/include/configs/tbs2910.h
> +++ b/include/configs/tbs2910.h
> @@ -183,7 +183,13 @@
>  #ifdef CONFIG_USB_KEYBOARD
>  #define CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE
>  #define CONFIG_SYS_STDIO_DEREGISTER
> -#define CONFIG_PREBOOT "if hdmidet; then usb start; fi"
> +#define CONFIG_PREBOOT \
> +	"if hdmidet; then " \
> +		"usb start; " \
> +		"run set_con_usb_hdmi; " \
> +	"else " \
> +		"run set_con_serial; " \
> +	"fi;"
>  #endif /* CONFIG_USB_KEYBOARD */
>  #endif /* CONFIG_CMD_USB      */
>  
> @@ -241,9 +247,12 @@
>  			"bootm 0x10800000 0x10d00000\0" \
>  	"console=ttymxc0\0" \
>  	"fan=gpio set 92\0" \
> -	"stdin=serial,usbkbd\0" \
> -	"stdout=serial,vga\0" \
> -	"stderr=serial,vga\0"
> +	"set_con_serial=setenv stdin serial; " \
> +			"setenv stdout serial; " \
> +			"setenv stderr serial;\0" \
> +	"set_con_usb_hdmi=setenv stdin serial,usbkbd; " \
> +			"setenv stdout serial,vga; " \
> +			"setenv stderr serial,vga;\0"
>  
>  #define CONFIG_BOOTCOMMAND \
>  	"mmc rescan; " \
> 

Applied to u-boot-imx, thanks !

Best regards,
     Stefano Babic


-- 
=====================================================================
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de
=====================================================================

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

* [U-Boot] [PATCH 3/5] tbs2910: use default CONFIG_SYS_PBSIZE
  2015-05-05 21:09 ` [U-Boot] [PATCH 3/5] tbs2910: use default CONFIG_SYS_PBSIZE Soeren Moch
@ 2015-05-15 13:06   ` Stefano Babic
  0 siblings, 0 replies; 10+ messages in thread
From: Stefano Babic @ 2015-05-15 13:06 UTC (permalink / raw)
  To: u-boot

On 05/05/2015 23:09, Soeren Moch wrote:
> Since there is a default CONFIG_SYS_PBSIZE definition in config_fallbacks.h,
> this setting is no longer required in board configurations.
> 
> Signed-off-by: Soeren Moch <smoch@web.de>
> ---
> Cc: Stefano Babic <sbabic@denx.de>
> ---
>  include/configs/tbs2910.h | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/include/configs/tbs2910.h b/include/configs/tbs2910.h
> index ea4666d..9efb8c2 100644
> --- a/include/configs/tbs2910.h
> +++ b/include/configs/tbs2910.h
> @@ -39,8 +39,6 @@
>  #define CONFIG_CMDLINE_EDITING
>  #define CONFIG_SYS_MAXARGS		16
>  #define CONFIG_SYS_CBSIZE		1024
> -#define CONFIG_SYS_PBSIZE \
> -	(CONFIG_SYS_CBSIZE + sizeof(CONFIG_SYS_PROMPT) + 16)
>  #define CONFIG_SYS_HZ			1000
>  
>  /* Physical Memory Map */
> 
Applied to u-boot-imx, thanks !

Best regards,
     Stefano Babic



-- 
=====================================================================
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de
=====================================================================

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

* [U-Boot] [PATCH 4/5] tbs2910: add CONFIG_SUPPORT_EMMC_BOOT
  2015-05-05 21:09 ` [U-Boot] [PATCH 4/5] tbs2910: add CONFIG_SUPPORT_EMMC_BOOT Soeren Moch
@ 2015-05-15 13:06   ` Stefano Babic
  0 siblings, 0 replies; 10+ messages in thread
From: Stefano Babic @ 2015-05-15 13:06 UTC (permalink / raw)
  To: u-boot

On 05/05/2015 23:09, Soeren Moch wrote:
> Add emmc boot partition commands to be able to select the boot partition.
> 
> Signed-off-by: Soeren Moch <smoch@web.de>
> ---
> Cc: Stefano Babic <sbabic@denx.de>
> ---
>  include/configs/tbs2910.h | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/include/configs/tbs2910.h b/include/configs/tbs2910.h
> index 9efb8c2..1f3c3d8 100644
> --- a/include/configs/tbs2910.h
> +++ b/include/configs/tbs2910.h
> @@ -102,6 +102,7 @@
>  #define CONFIG_MMC
>  #define CONFIG_CMD_MMC
>  #define CONFIG_GENERIC_MMC
> +#define CONFIG_SUPPORT_EMMC_BOOT
>  #define CONFIG_BOUNCE_BUFFER
>  
>  /* Ethernet */
> 
Applied to u-boot-imx, thanks !

Best regards,
     Stefano Babic



-- 
=====================================================================
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de
=====================================================================

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

end of thread, other threads:[~2015-05-15 13:06 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-05 21:09 [U-Boot] [PATCH 1/5] tbs2910: support for usb otg host mode Soeren Moch
2015-05-05 21:09 ` [U-Boot] [PATCH 2/5] tbs2910: only enable vga output for stdout/stderr when hdmi detected Soeren Moch
2015-05-15 13:06   ` Stefano Babic
2015-05-05 21:09 ` [U-Boot] [PATCH 3/5] tbs2910: use default CONFIG_SYS_PBSIZE Soeren Moch
2015-05-15 13:06   ` Stefano Babic
2015-05-05 21:09 ` [U-Boot] [PATCH 4/5] tbs2910: add CONFIG_SUPPORT_EMMC_BOOT Soeren Moch
2015-05-15 13:06   ` Stefano Babic
2015-05-05 21:09 ` [U-Boot] [PATCH 5/5] tbs2910: add ext4 write support Soeren Moch
2015-05-11 18:12   ` Soeren Moch
2015-05-15 13:06 ` [U-Boot] [PATCH 1/5] tbs2910: support for usb otg host mode Stefano Babic

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox