[U-Boot] [PATCH v5 0/3] mx23/mxs pending patches

This patchset includes the pending patches we have in our tree. It fixes issues for mx23evk and mx23_olinuxino boards. This depends on Marek's patchset which has included most of the previous patches in this patchset.
Changes in v5: - Adapt code to newer multiport support - Adapt code to newer multiport support
Changes in v2: - Add changes for allow use of the USB hub - Remove extra newline
Otavio Salvador (3): mx23evk: Enable USB support mx23_olinuxino: Enable USB support mx23_olinuxino: Add ethernet support
board/olimex/mx23_olinuxino/mx23_olinuxino.c | 5 +++ board/olimex/mx23_olinuxino/spl_boot.c | 4 +++ include/configs/mx23_olinuxino.h | 50 ++++++++++++++++++++++++++-- include/configs/mx23evk.h | 11 ++++++ 4 files changed, 67 insertions(+), 3 deletions(-)

This enabled USB support for the mx23evk board.
Signed-off-by: Otavio Salvador otavio@ossystems.com.br --- Changes in v5: - Adapt code to newer multiport support
Changes in v2: None
include/configs/mx23evk.h | 11 +++++++++++ 1 file changed, 11 insertions(+)
diff --git a/include/configs/mx23evk.h b/include/configs/mx23evk.h index d206c95..e5a15a4 100644 --- a/include/configs/mx23evk.h +++ b/include/configs/mx23evk.h @@ -58,6 +58,7 @@ #define CONFIG_CMD_FAT #define CONFIG_CMD_GPIO #define CONFIG_CMD_MMC +#define CONFIG_CMD_USB #define CONFIG_CMD_BOOTZ
/* Memory configurations */ @@ -122,6 +123,16 @@ #define CONFIG_MXS_MMC #endif
+/* USB */ +#ifdef CONFIG_CMD_USB +#define CONFIG_USB_EHCI +#define CONFIG_USB_EHCI_MXS +#define CONFIG_EHCI_MXS_PORT0 +#define CONFIG_USB_MAX_CONTROLLER_COUNT 1 +#define CONFIG_EHCI_IS_TDI +#define CONFIG_USB_STORAGE +#endif + /* Boot Linux */ #define CONFIG_CMDLINE_TAG #define CONFIG_SETUP_MEMORY_TAGS

On 02/03/2013 16:17, Otavio Salvador wrote:
This enabled USB support for the mx23evk board.
Signed-off-by: Otavio Salvador otavio@ossystems.com.br
Applied to u-boot-imx, thanks.
Best regards, Stefano Babic

This enabled USB support for the mx23_olinuxino board.
Signed-off-by: Otavio Salvador otavio@ossystems.com.br --- Changes in v5: - Adapt code to newer multiport support
Changes in v2: - Add changes for allow use of the USB hub
board/olimex/mx23_olinuxino/mx23_olinuxino.c | 5 +++++ board/olimex/mx23_olinuxino/spl_boot.c | 4 ++++ include/configs/mx23_olinuxino.h | 11 +++++++++++ 3 files changed, 20 insertions(+)
diff --git a/board/olimex/mx23_olinuxino/mx23_olinuxino.c b/board/olimex/mx23_olinuxino/mx23_olinuxino.c index 2501417..9252717 100644 --- a/board/olimex/mx23_olinuxino/mx23_olinuxino.c +++ b/board/olimex/mx23_olinuxino/mx23_olinuxino.c @@ -45,6 +45,11 @@ int board_early_init_f(void) /* SSP0 clock at 96MHz */ mxs_set_sspclk(MXC_SSPCLK0, 96000, 0);
+#ifdef CONFIG_CMD_USB + /* Enable LAN9512 */ + gpio_direction_output(MX23_PAD_GPMI_ALE__GPIO_0_17, 1); +#endif + return 0; }
diff --git a/board/olimex/mx23_olinuxino/spl_boot.c b/board/olimex/mx23_olinuxino/spl_boot.c index 3bbf5ad..a96c293 100644 --- a/board/olimex/mx23_olinuxino/spl_boot.c +++ b/board/olimex/mx23_olinuxino/spl_boot.c @@ -95,6 +95,10 @@ const iomux_cfg_t iomux_setup[] = { MX23_PAD_SSP1_DATA2__SSP1_DATA2 | MUX_CONFIG_SSP, MX23_PAD_SSP1_DATA3__SSP1_DATA3 | MUX_CONFIG_SSP, MX23_PAD_SSP1_SCK__SSP1_SCK | MUX_CONFIG_SSP, + + /* Ethernet */ + MX23_PAD_GPMI_ALE__GPIO_0_17 | + (MXS_PAD_3V3 | MXS_PAD_12MA | MXS_PAD_NOPULL), };
void board_init_ll(void) diff --git a/include/configs/mx23_olinuxino.h b/include/configs/mx23_olinuxino.h index d019944..90dda01 100644 --- a/include/configs/mx23_olinuxino.h +++ b/include/configs/mx23_olinuxino.h @@ -60,6 +60,7 @@ #define CONFIG_CMD_GPIO #define CONFIG_CMD_LED #define CONFIG_CMD_MMC +#define CONFIG_CMD_USB
/* * Memory configurations @@ -140,6 +141,16 @@ */ #define CONFIG_APBH_DMA
+/* USB */ +#ifdef CONFIG_CMD_USB +#define CONFIG_USB_EHCI +#define CONFIG_USB_EHCI_MXS +#define CONFIG_EHCI_MXS_PORT0 +#define CONFIG_USB_MAX_CONTROLLER_COUNT 1 +#define CONFIG_EHCI_IS_TDI +#define CONFIG_USB_STORAGE +#endif + /* * Boot Linux */

On 02/03/2013 16:17, Otavio Salvador wrote:
This enabled USB support for the mx23_olinuxino board.
Signed-off-by: Otavio Salvador otavio@ossystems.com.br
Applied to u-boot-imx, but...
/* SSP0 clock at 96MHz */ mxs_set_sspclk(MXC_SSPCLK0, 96000, 0);
+#ifdef CONFIG_CMD_USB
- /* Enable LAN9512 */
- gpio_direction_output(MX23_PAD_GPMI_ALE__GPIO_0_17, 1);
+#endif
...the header for gpio is missing. Please send the patch to fix the warning.
mx23_olinuxino.c: In function 'board_early_init_f': mx23_olinuxino.c:50:2: warning: implicit declaration of function 'gpio_direction_output' [-Wimplicit-function-declaration]
Thanks, Stefano

This adds support to the LAN9512 chip included in the board and extend the environment to easy netboot use.
Signed-off-by: Otavio Salvador otavio@ossystems.com.br --- Changes in v5: None Changes in v2: - Remove extra newline
include/configs/mx23_olinuxino.h | 39 ++++++++++++++++++++++++++++++++++++--- 1 file changed, 36 insertions(+), 3 deletions(-)
diff --git a/include/configs/mx23_olinuxino.h b/include/configs/mx23_olinuxino.h index 90dda01..03893d7 100644 --- a/include/configs/mx23_olinuxino.h +++ b/include/configs/mx23_olinuxino.h @@ -55,11 +55,13 @@ #define CONFIG_DOS_PARTITION
#define CONFIG_CMD_CACHE +#define CONFIG_CMD_DHCP #define CONFIG_CMD_EXT2 #define CONFIG_CMD_FAT #define CONFIG_CMD_GPIO #define CONFIG_CMD_LED #define CONFIG_CMD_MMC +#define CONFIG_CMD_NET #define CONFIG_CMD_USB
/* @@ -151,6 +153,12 @@ #define CONFIG_USB_STORAGE #endif
+/* Ethernet */ +#ifdef CONFIG_CMD_NET +#define CONFIG_USB_HOST_ETHER +#define CONFIG_USB_ETHER_SMSC95XX +#endif + /* * Boot Linux */ @@ -192,6 +200,7 @@ "fdt_file=imx23-olinuxino.dtb\0" \ "fdt_addr=0x41000000\0" \ "boot_fdt=try\0" \ + "ip_dyn=yes\0" \ "mmcdev=0\0" \ "mmcpart=2\0" \ "mmcroot=/dev/mmcblk0p3 rw rootwait\0" \ @@ -217,6 +226,31 @@ "fi; " \ "else " \ "bootm; " \ + "fi;\0" \ + "netargs=setenv bootargs console=${console_mainline},${baudrate} " \ + "root=/dev/nfs " \ + "ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp\0" \ + "netboot=echo Booting from net ...; " \ + "usb start; " \ + "run netargs; " \ + "if test ${ip_dyn} = yes; then " \ + "setenv get_cmd dhcp; " \ + "else " \ + "setenv get_cmd tftp; " \ + "fi; " \ + "${get_cmd} ${uimage}; " \ + "if test ${boot_fdt} = yes; then " \ + "if ${get_cmd} ${fdt_addr} ${fdt_file}; then " \ + "bootm ${loadaddr} - ${fdt_addr}; " \ + "else " \ + "if test ${boot_fdt} = try; then " \ + "bootm; " \ + "else " \ + "echo WARN: Cannot load the DT; " \ + "fi;" \ + "fi; " \ + "else " \ + "bootm; " \ "fi;\0"
#define CONFIG_BOOTCOMMAND \ @@ -226,10 +260,9 @@ "else " \ "if run loaduimage; then " \ "run mmcboot; " \ - "else " \ - "echo ERR: Fail to boot from MMC; " \ + "else run netboot; " \ "fi; " \ "fi; " \ - "else exit; fi" + "else run netboot; fi"
#endif /* __MX23_OLINUXINO_CONFIG_H__ */

On 02/03/2013 16:17, Otavio Salvador wrote:
This adds support to the LAN9512 chip included in the board and extend the environment to easy netboot use.
Signed-off-by: Otavio Salvador otavio@ossystems.com.br
Applied to u-boot-imx, thanks.
Best regards, Stefano Babic

On Sat, Mar 2, 2013 at 12:17 PM, Otavio Salvador otavio@ossystems.com.br wrote:
This patchset includes the pending patches we have in our tree. It fixes issues for mx23evk and mx23_olinuxino boards. This depends on
What issues does this patch series fix? I see that it adds USB support, but I don't see any bug fix.

Dear Otavio Salvador,
This patchset includes the pending patches we have in our tree. It fixes issues for mx23evk and mx23_olinuxino boards. This depends on Marek's patchset which has included most of the previous patches in this patchset.
Changes in v5:
- Adapt code to newer multiport support
- Adapt code to newer multiport support
Changes in v2:
- Add changes for allow use of the USB hub
- Remove extra newline
Otavio Salvador (3): mx23evk: Enable USB support mx23_olinuxino: Enable USB support mx23_olinuxino: Add ethernet support
I fail to understand what happened with that flurry of patches that was in V4. But maybe this is V5 for other series? I'm confused.
Best regards, Marek Vasut

On Sat, Mar 2, 2013 at 5:41 PM, Marek Vasut marex@denx.de wrote:
Dear Otavio Salvador,
This patchset includes the pending patches we have in our tree. It fixes issues for mx23evk and mx23_olinuxino boards. This depends on Marek's patchset which has included most of the previous patches in this patchset.
Changes in v5:
- Adapt code to newer multiport support
- Adapt code to newer multiport support
Changes in v2:
- Add changes for allow use of the USB hub
- Remove extra newline
Otavio Salvador (3): mx23evk: Enable USB support mx23_olinuxino: Enable USB support mx23_olinuxino: Add ethernet support
I fail to understand what happened with that flurry of patches that was in V4. But maybe this is V5 for other series? I'm confused.
The other patches of this serie you picked in your last pull request so I did not resend them to avoid making it more confusing for Stefano.
So these are the 3 other ones.

On 02/03/2013 21:58, Otavio Salvador wrote:
On Sat, Mar 2, 2013 at 5:41 PM, Marek Vasut marex@denx.de wrote:
Dear Otavio Salvador,
This patchset includes the pending patches we have in our tree. It fixes issues for mx23evk and mx23_olinuxino boards. This depends on Marek's patchset which has included most of the previous patches in this patchset.
Changes in v5:
- Adapt code to newer multiport support
- Adapt code to newer multiport support
Changes in v2:
- Add changes for allow use of the USB hub
- Remove extra newline
Otavio Salvador (3): mx23evk: Enable USB support mx23_olinuxino: Enable USB support mx23_olinuxino: Add ethernet support
I fail to understand what happened with that flurry of patches that was in V4. But maybe this is V5 for other series? I'm confused.
The other patches of this serie you picked in your last pull request so I did not resend them to avoid making it more confusing for Stefano.
Oh, I am stil lquite confused ;-)
I admit I cannot follow the ML in the lastr two weeks due to a urgent project, and I get a flood in my mailbox. Anyway, I have no problems with this series, and no comments are open. I apply it now.
Regards, Stefano
So these are the 3 other ones.

Dear Stefano Babic,
On 02/03/2013 21:58, Otavio Salvador wrote:
On Sat, Mar 2, 2013 at 5:41 PM, Marek Vasut marex@denx.de wrote:
Dear Otavio Salvador,
This patchset includes the pending patches we have in our tree. It fixes issues for mx23evk and mx23_olinuxino boards. This depends on Marek's patchset which has included most of the previous patches in this patchset.
Changes in v5:
- Adapt code to newer multiport support
- Adapt code to newer multiport support
Changes in v2:
- Add changes for allow use of the USB hub
- Remove extra newline
Otavio Salvador (3): mx23evk: Enable USB support mx23_olinuxino: Enable USB support mx23_olinuxino: Add ethernet support
I fail to understand what happened with that flurry of patches that was in V4. But maybe this is V5 for other series? I'm confused.
The other patches of this serie you picked in your last pull request so I did not resend them to avoid making it more confusing for Stefano.
Oh, I am stil lquite confused ;-)
I admit I cannot follow the ML in the lastr two weeks due to a urgent project, and I get a flood in my mailbox.
No kidding, same here.
Anyway, I have no problems with this series, and no comments are open. I apply it now.
Check u-boot-testing :: mx233 if it helps, I picked all patches that shall be applied in there.
Regards, Stefano
So these are the 3 other ones.
Best regards, Marek Vasut

On Thu, Mar 7, 2013 at 1:20 PM, Marek Vasut marex@denx.de wrote:
Dear Stefano Babic,
On 02/03/2013 21:58, Otavio Salvador wrote:
On Sat, Mar 2, 2013 at 5:41 PM, Marek Vasut marex@denx.de wrote:
Dear Otavio Salvador,
This patchset includes the pending patches we have in our tree. It fixes issues for mx23evk and mx23_olinuxino boards. This depends on Marek's patchset which has included most of the previous patches in this patchset.
Changes in v5:
- Adapt code to newer multiport support
- Adapt code to newer multiport support
Changes in v2:
- Add changes for allow use of the USB hub
- Remove extra newline
Otavio Salvador (3): mx23evk: Enable USB support mx23_olinuxino: Enable USB support mx23_olinuxino: Add ethernet support
I fail to understand what happened with that flurry of patches that was in V4. But maybe this is V5 for other series? I'm confused.
The other patches of this serie you picked in your last pull request so I did not resend them to avoid making it more confusing for Stefano.
Oh, I am stil lquite confused ;-)
I admit I cannot follow the ML in the lastr two weeks due to a urgent project, and I get a flood in my mailbox.
No kidding, same here.
Anyway, I have no problems with this series, and no comments are open. I apply it now.
Check u-boot-testing :: mx233 if it helps, I picked all patches that shall be applied in there.
There're patches which where not send for review there (as Makefile change)

On 07/03/2013 17:23, Otavio Salvador wrote:
Check u-boot-testing :: mx233 if it helps, I picked all patches that shall be applied in there.
There're patches which where not send for review there (as Makefile change)
Of course, such patches (I have find only what you mention) cannot be picked up at all if not reviewed here.
Regards, Stefano

Dear Stefano Babic,
On 07/03/2013 17:23, Otavio Salvador wrote:
Check u-boot-testing :: mx233 if it helps, I picked all patches that shall be applied in there.
There're patches which where not send for review there (as Makefile change)
Of course, such patches (I have find only what you mention) cannot be picked up at all if not reviewed here.
Sorry about that, that one convenience patch slipped in. I see you managed to pick the rest of those, thanks!
Best regards, Marek Vasut
participants (4)
-
Fabio Estevam
-
Marek Vasut
-
Otavio Salvador
-
Stefano Babic