All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tormod Volden <lists.tormod@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [RFC][DFU] Unification of dfu_alt_info alt settings description + command execution
Date: Wed, 17 Jul 2013 19:32:00 +0200	[thread overview]
Message-ID: <CAArsGab=LmzXMjM2HMeafLn6gNsPz9YBbq2DD4jyJznLZkMXUg@mail.gmail.com> (raw)
In-Reply-To: <20130717163440.6dbe1a18@amdc308.digital.local>

On Wed, Jul 17, 2013 at 4:34 PM, Lukasz Majewski wrote:
> _As a side note:_
>
> I'm now developing proof-of-concept idea of executing set of commands
> sent to u-boot by dfu-util [***].
>
> Rationale for this is the lack of ability to reset u-boot after sending
> data to u-boot via DFU. dfu-util has -R option, but this seems to reset
> usb interface, not the target device.

Actually, dfu-util -R  sends a DFU_DETACH request before performing
the USB reset. The reason for this was long unclear to me, until I
looked at the uboot dfu code (inherited from openmoko):

http://git.denx.de/?p=u-boot.git;a=blob;f=drivers/usb/gadget/f_dfu.c;h=d7ae0c0c6a9f6a95ca3a702d92636eb25e21253c;hb=HEAD#l314

"Proprietary extension: 'detach' from idle mode and get back to
runtime mode in case of USB Reset. As much as I dislike this, we just
can't use every USB bus reset to switch back to runtime mode, since at
least the Linux USB stack likes to send a number of resets in a row :(
"

The hack/abuse of sending a DFU_DETACH when in DFU mode is not part of
the DFU standard, but dfu-util supports it since openmoko was for long
the major target for dfu-util.

If you don't need to switch back from DFU mode to runtime mode, maybe
you can use this to reset u-boot?

Regards,
Tormod

  reply	other threads:[~2013-07-17 17:32 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-16 15:35 [U-Boot] [RFC][DFU] Unification of dfu_alt_info alt settings description + command execution Lukasz Majewski
2013-07-16 21:27 ` Tormod Volden
2013-07-16 21:46   ` Lukasz Majewski
2013-07-17 10:26 ` Heiko Schocher
2013-07-17 14:34   ` Lukasz Majewski
2013-07-17 17:32     ` Tormod Volden [this message]
2013-07-18  5:36     ` Heiko Schocher
2013-07-18  7:13       ` Lukasz Majewski
2013-07-18  4:17   ` Marek Vasut
2013-07-18  5:16     ` Heiko Schocher
2013-07-18  8:09       ` Wolfgang Denk
2013-07-18 15:10         ` Marek Vasut
2013-07-19  4:45           ` Heiko Schocher
2013-07-19 13:55             ` Marek Vasut
2013-07-18 16:39 ` Tom Rini
2013-07-18 17:30   ` Michael Cashwell
2013-07-18 20:17     ` Lukasz Majewski
2013-07-18 22:33       ` Tom Rini
2013-08-23 10:07     ` Lukasz Majewski
2013-10-31 17:25 ` Lukasz Majewski
2013-10-31 20:32   ` Wolfgang Denk
2013-10-31 21:20     ` Lukasz Majewski
2013-10-31 23:11       ` Wolfgang Denk
2013-11-04  6:52         ` Lukasz Majewski
2013-11-01  6:15   ` Heiko Schocher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAArsGab=LmzXMjM2HMeafLn6gNsPz9YBbq2DD4jyJznLZkMXUg@mail.gmail.com' \
    --to=lists.tormod@gmail.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.