public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] mx6sabre_common: Add DFU support
@ 2015-09-23  3:52 Fabio Estevam
  2015-10-02  8:51 ` Stefano Babic
  0 siblings, 1 reply; 2+ messages in thread
From: Fabio Estevam @ 2015-09-23  3:52 UTC (permalink / raw)
  To: u-boot

From: Fabio Estevam <fabio.estevam@freescale.com>

Add DFU support.

Tested by flashing SPL and u-boot.img into SPI NOR flash with the
following commands:

=> setenv dfu_alt_info ${dfu_alt_info_spl}

=> run dfuspi

On the host PC:

$ sudo dfu-util -D SPL -a spl

On the target:

CTRL+C
=> setenv dfu_alt_info ${dfu_alt_info_img}

=> run dfuspi

On the host PC:

$ sudo dfu-util -D u-boot.img -a u-boot

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
---
 include/configs/mx6sabre_common.h | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/include/configs/mx6sabre_common.h b/include/configs/mx6sabre_common.h
index 98eb042..ba21659 100644
--- a/include/configs/mx6sabre_common.h
+++ b/include/configs/mx6sabre_common.h
@@ -80,6 +80,10 @@
 	"boot_fdt=try\0" \
 	"ip_dyn=yes\0" \
 	"console=" CONFIG_CONSOLE_DEV "\0" \
+	"dfuspi=dfu 0 sf 0:0:10000000:0\0" \
+	"dfu_alt_info_spl=spl raw 0x400\0" \
+	"dfu_alt_info_img=u-boot raw 0x10000\0" \
+	"dfu_alt_info=spl raw 0x400\0" \
 	"fdt_high=0xffffffff\0"	  \
 	"initrd_high=0xffffffff\0" \
 	"mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \
@@ -238,6 +242,13 @@
 #define CONFIG_G_DNL_VENDOR_NUM		0x0525
 #define CONFIG_G_DNL_PRODUCT_NUM	0xa4a5
 #define CONFIG_G_DNL_MANUFACTURER	"FSL"
+
+/* USB Device Firmware Update support */
+#define CONFIG_CMD_DFU
+#define CONFIG_USB_FUNCTION_DFU
+#define CONFIG_DFU_MMC
+#define CONFIG_DFU_SF
+
 #endif
 
 #endif                         /* __MX6QSABRE_COMMON_CONFIG_H */
-- 
1.9.1

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

* [U-Boot] [PATCH] mx6sabre_common: Add DFU support
  2015-09-23  3:52 [U-Boot] [PATCH] mx6sabre_common: Add DFU support Fabio Estevam
@ 2015-10-02  8:51 ` Stefano Babic
  0 siblings, 0 replies; 2+ messages in thread
From: Stefano Babic @ 2015-10-02  8:51 UTC (permalink / raw)
  To: u-boot

On 23/09/2015 05:52, Fabio Estevam wrote:
> From: Fabio Estevam <fabio.estevam@freescale.com>
> 
> Add DFU support.
> 
> Tested by flashing SPL and u-boot.img into SPI NOR flash with the
> following commands:
> 
> => setenv dfu_alt_info ${dfu_alt_info_spl}
> 
> => run dfuspi
> 
> On the host PC:
> 
> $ sudo dfu-util -D SPL -a spl
> 
> On the target:
> 
> CTRL+C
> => setenv dfu_alt_info ${dfu_alt_info_img}
> 
> => run dfuspi
> 
> On the host PC:
> 
> $ sudo dfu-util -D u-boot.img -a u-boot
> 
> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
> ---

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] 2+ messages in thread

end of thread, other threads:[~2015-10-02  8:51 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-09-23  3:52 [U-Boot] [PATCH] mx6sabre_common: Add DFU support Fabio Estevam
2015-10-02  8:51 ` Stefano Babic

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