[U-Boot] [PATCH v2 2/4] fastboot: call board_usb_init() to enable usb

Tom Rini trini at konsulko.com
Wed Mar 4 19:29:48 CET 2015


On Wed, Mar 04, 2015 at 05:05:11PM +0000, Stegmaier, Angela wrote:
> Hi Dileep,
> 
> > -----Original Message-----
> > From: Dileep Katta [mailto:dileep.katta at linaro.org]
> > Sent: Tuesday, March 03, 2015 5:11 AM
> > To: u-boot at lists.denx.de; robherring2 at gmail.com; Rini, Tom;
> > rob.herring at linaro.org; srae at broadcom.com; l.majewski at samsung.com;
> > Stegmaier, Angela
> > Cc: Dileep Katta
> > Subject: [U-Boot][PATCH v2 2/4] fastboot: call board_usb_init() to enable
> > usb
> > 
> > g_dnl_gadget_register() fails for dra7xx dwc3 gadget when running
> > cmd_fastboot.
> > Calling board_usb_init() fixes this.
> > 
> > Signed-off-by: Angela Stegmaier <angelabaker at ti.com>
> > Signed-off-by: Dileep Katta <dileep.katta at linaro.org>
> > ---
> >  common/cmd_fastboot.c | 2 ++
> >  1 file changed, 2 insertions(+)
> > 
> > diff --git a/common/cmd_fastboot.c b/common/cmd_fastboot.c index
> > 346ab80..d7b8f6d 100644
> > --- a/common/cmd_fastboot.c
> > +++ b/common/cmd_fastboot.c
> > @@ -10,11 +10,13 @@
> >  #include <common.h>
> >  #include <command.h>
> >  #include <g_dnl.h>
> > +#include <usb.h>
> > 
> >  static int do_fastboot(cmd_tbl_t *cmdtp, int flag, int argc, char *const
> > argv[])  {
> >  	int ret;
> > 
> > +	board_usb_init(0, USB_INIT_DEVICE);
> 
> The controller index should be configurable. Also, should board_usb_cleanup be called at the end?

I _really_ _really_ want to see if we can modify things so that we don't
have to sprinkle ever gadget driver with a cleanup() and every gadget
too if we don't have to.  Thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20150304/78047300/attachment.sig>


More information about the U-Boot mailing list