[U-Boot] [PATCH v2 1/2] usb: dfu: add fullspeed support for DFU

Lukasz Majewski l.majewski at samsung.com
Thu Sep 11 14:16:54 CEST 2014


Hi Heiko,

> DFU now can use also fullspeed.
> 
> Signed-off-by: Heiko Schocher <hs at denx.de>
> Cc: Tom Rini <trini at ti.com>
> Cc: Lukasz Majewski <l.majewski at samsung.com>
> Cc: Marek Vasut <marex at denx.de>
> Cc: Liu Bin <b-liu at ti.com>
> Cc: Lukas Stockmann <lukas.stockmann at siemens.com>
> 
> ---
> 
> - changes for v2:
>   - get rid of config option CONFIG_DFU_FULLSPEED as Bin Liu
>     suggested.
> ---
>  drivers/usb/gadget/f_dfu.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/drivers/usb/gadget/f_dfu.c b/drivers/usb/gadget/f_dfu.c
> index 1145aab..dfa9f3b 100644
> --- a/drivers/usb/gadget/f_dfu.c
> +++ b/drivers/usb/gadget/f_dfu.c
> @@ -238,6 +238,7 @@ static inline void to_dfu_mode(struct f_dfu
> *f_dfu) {
>  	f_dfu->usb_function.strings = dfu_strings;
>  	f_dfu->usb_function.hs_descriptors = f_dfu->function;
> +	f_dfu->usb_function.descriptors = f_dfu->function;
>  	f_dfu->dfu_state = DFU_STATE_dfuIDLE;
>  }
>  
> @@ -245,6 +246,7 @@ static inline void to_runtime_mode(struct f_dfu
> *f_dfu) {
>  	f_dfu->usb_function.strings = NULL;
>  	f_dfu->usb_function.hs_descriptors = dfu_runtime_descs;
> +	f_dfu->usb_function.descriptors = dfu_runtime_descs;
>  }
>  
>  static int handle_upload(struct usb_request *req, u16 len)
> @@ -809,6 +811,7 @@ static int dfu_bind_config(struct
> usb_configuration *c) return -ENOMEM;
>  	f_dfu->usb_function.name = "dfu";
>  	f_dfu->usb_function.hs_descriptors = dfu_runtime_descs;
> +	f_dfu->usb_function.descriptors = dfu_runtime_descs;
>  	f_dfu->usb_function.bind = dfu_bind;
>  	f_dfu->usb_function.unbind = dfu_unbind;
>  	f_dfu->usb_function.set_alt = dfu_set_alt;

Test HW: Exynos 4412 - Trats2

This patch seems to not introduce any regressions, so

Tested-by: Lukasz Majewski <l.majewski at samsung.com>

-- 
Best regards,

Lukasz Majewski

Samsung R&D Institute Poland (SRPOL) | Linux Platform Group


More information about the U-Boot mailing list