mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* usbgadget: fastboot: Allow to automatically export bbu handlers
@ 2017-09-27 12:08 Sascha Hauer
  2017-09-27 12:08 ` [PATCH 01/12] file_list: Add function to add an entry to the list Sascha Hauer
                   ` (11 more replies)
  0 siblings, 12 replies; 13+ messages in thread
From: Sascha Hauer @ 2017-09-27 12:08 UTC (permalink / raw)
  To: Barebox List

This series allows to automatically export the registered bbu handlers
to fastboot. This way barebox can be updated via fastboot without much
preparation. Setting the following variables will be enough:

nv usbgadget.fastboot_function=""
nv usbgadget.autostart=1
nv usbgadget.fastboot_bbu=1

The exported partitions are then named bbu-<bbuname>.

example:

# fastboot -i 0x1d6b getvar all
< waiting for any device >
(bootloader) version: 0.4
(bootloader) bootloader-version: barebox-2017.09.0-00121-g9fde4fe832-dir
(bootloader) partition-size:bbu-mmc: 000c0000
(bootloader) partition-type:bbu-mmc: basic
all: 
finished. total time: 0.001s

# fastboot -i 0x1d6b flash bbu-mmc build/images/barebox-nxp-imx6ull-evk.img
target didn't report max-download-size
sending 'bbu-mmc' (515 KB)...
(bootloader) Downloading 527984 bytes...
(bootloader) Downloading 527984 bytes finished
OKAY [  0.027s]
writing 'bbu-mmc'...
(bootloader) Copying file to bbu-mmc...
(bootloader) This is a barebox image...
OKAY [  0.124s]
finished. total time: 0.151s

----------------------------------------------------------------
Sascha Hauer (12):
      file_list: Add function to add an entry to the list
      file_list: Add function to get entry by its name
      file_list: Allow only unique names on list
      file_list: Fix memory leak in failure path
      file_list: Add GPL header to file
      file_list: Add error messages
      usbgadget: fastboot: Use function to find file_list entry by name
      bbu: Add function to iterate over registered handlers
      usbgadget command: catch errors when parsing the file list
      usbgadget: fastboot: Allow to automatically export the bbu handlers
      fastboot command: Add -b option to export bbu handlers
      usbgadget autostart: add usbgadget.fastboot_bbu to automatically export bbu handlers

 commands/usbgadget.c            | 20 ++++++++++--
 common/bbu.c                    | 15 +++++++++
 common/file-list.c              | 72 +++++++++++++++++++++++++++++++++--------
 drivers/usb/gadget/autostart.c  |  7 ++++
 drivers/usb/gadget/f_fastboot.c | 29 +++++++++++++----
 drivers/usb/gadget/multi.c      |  1 +
 include/bbu.h                   |  2 ++
 include/file-list.h             |  5 +++
 include/usb/fastboot.h          |  7 ++++
 9 files changed, 135 insertions(+), 23 deletions(-)

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

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

end of thread, other threads:[~2017-09-27 12:09 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-09-27 12:08 usbgadget: fastboot: Allow to automatically export bbu handlers Sascha Hauer
2017-09-27 12:08 ` [PATCH 01/12] file_list: Add function to add an entry to the list Sascha Hauer
2017-09-27 12:09 ` [PATCH 02/12] file_list: Add function to get entry by its name Sascha Hauer
2017-09-27 12:09 ` [PATCH 03/12] file_list: Allow only unique names on list Sascha Hauer
2017-09-27 12:09 ` [PATCH 04/12] file_list: Fix memory leak in failure path Sascha Hauer
2017-09-27 12:09 ` [PATCH 05/12] file_list: Add GPL header to file Sascha Hauer
2017-09-27 12:09 ` [PATCH 06/12] file_list: Add error messages Sascha Hauer
2017-09-27 12:09 ` [PATCH 07/12] usbgadget: fastboot: Use function to find file_list entry by name Sascha Hauer
2017-09-27 12:09 ` [PATCH 08/12] bbu: Add function to iterate over registered handlers Sascha Hauer
2017-09-27 12:09 ` [PATCH 09/12] usbgadget command: catch errors when parsing the file list Sascha Hauer
2017-09-27 12:09 ` [PATCH 10/12] usbgadget: fastboot: Allow to automatically export the bbu handlers Sascha Hauer
2017-09-27 12:09 ` [PATCH 11/12] fastboot command: Add -b option to export " Sascha Hauer
2017-09-27 12:09 ` [PATCH 12/12] usbgadget autostart: add usbgadget.fastboot_bbu to automatically " Sascha Hauer

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