mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH v4 00/19] Slices and fastboot over UDP
@ 2020-06-17  8:11 Sascha Hauer
  2020-06-17  8:11 ` [PATCH 01/19] Introduce slices Sascha Hauer
                   ` (18 more replies)
  0 siblings, 19 replies; 32+ messages in thread
From: Sascha Hauer @ 2020-06-17  8:11 UTC (permalink / raw)
  To: Barebox List; +Cc: Daniel Glöckner

This is a new round of the series adding fastboot over ethernet to
barebox. Compared to the last version this contains some conceptual
changes. First of all we no longer need executing pollers inside of
pollers. Hopefully this makes it easier to follow the execution flow.
Instead workqueues help to execute possibly longer living code with
dependencies to other devices. Workqueues are used to trigger work
from pollers. This is then executed when the command slice, previously
known as idle slice, is released. To make sure pollers don't do things
they are not allowed to we now have a assert_command_context() macro
which warns when it is called from a poller. This is added to most
filesystem operations as these definitely shouldn't be called from
pollers. Besides fastboot over UDP also fastboot over USB and RATP
are converted to use workqueues, so these also no longer call the
commands they execute from pollers.

To give an overview how barebox now handles pseudo parallel execution
I wrote some documentation, see the last patch.

Changes since last version:

- add workqueue interface
- convert fastboot USB and RATP to no longer call commands from pollers
- add Documentation


Daniel Glöckner (2):
  defconfigs: update renamed fastboot options
  fastboot: rename usbgadget.fastboot_* variables to fastboot.*

Edmund Henniges (1):
  fastboot net: implement fastboot over UDP

Sascha Hauer (16):
  Introduce slices
  Add workqueues
  ratp: Switch to workqueues
  net: Add a slice to struct eth_device
  net: mdiobus: Add slice
  usb: Add a slice to usb host controllers
  usbnet: Add slice
  net: Call net_poll() in a poller
  net: reply to ping requests
  usbnet: Be more friendly in the receive path
  globalvar: Add helper for deprecated variable names
  fastboot: remove double print
  usb: fastboot: execute commands in command context
  Add WARN_ONCE() macro
  fs: Warn when filesystem operations are called from a poller
  Documentation: Add document for parallel execution in barebox

 Documentation/devel/devel.rst              |  14 +
 Documentation/devel/parallel-execution.rst |  92 ++++
 Documentation/index.rst                    |   1 +
 Documentation/user/usb.rst                 |   4 +-
 arch/arm/configs/imx23_defconfig           |   2 +-
 arch/arm/configs/imx28_defconfig           |   2 +-
 arch/arm/configs/imx_v7_defconfig          |   2 +-
 arch/arm/configs/imx_v8_defconfig          |   2 +-
 arch/arm/configs/kindle-mx50_defconfig     |   2 +-
 arch/arm/configs/omap_defconfig            |   2 +-
 arch/arm/configs/zii_vf610_dev_defconfig   |   2 +-
 commands/Kconfig                           |   8 +
 commands/usbgadget.c                       |   2 +-
 common/Makefile                            |   2 +
 common/fastboot.c                          |  30 +-
 common/globalvar.c                         |  54 ++-
 common/hush.c                              |   6 +
 common/poller.c                            |   9 +-
 common/ratp/ratp.c                         |  57 ++-
 common/slice.c                             | 335 ++++++++++++++
 common/startup.c                           |   3 +
 common/usbgadget.c                         |  16 +-
 common/workqueue.c                         |  48 ++
 drivers/net/phy/mdio_bus.c                 |  43 ++
 drivers/net/usb/usbnet.c                   |  22 +-
 drivers/usb/core/usb.c                     |  12 +-
 drivers/usb/gadget/f_fastboot.c            |  49 +-
 fs/fs.c                                    |  35 ++
 fs/nfs.c                                   |   2 -
 fs/tftp.c                                  |   2 -
 include/asm-generic/bug.h                  |  13 +
 include/fastboot.h                         |   6 +
 include/fastboot_net.h                     |  12 +
 include/globalvar.h                        |   5 +
 include/linux/phy.h                        |  38 +-
 include/net.h                              |  11 +-
 include/ratp_bb.h                          |   1 -
 include/slice.h                            |  42 ++
 include/usb/usb.h                          |   8 +-
 include/usb/usbnet.h                       |   3 +
 include/work.h                             |  38 ++
 lib/readline.c                             |   6 +-
 net/Kconfig                                |  10 +
 net/Makefile                               |   1 +
 net/dhcp.c                                 |   1 -
 net/dns.c                                  |   1 -
 net/eth.c                                  |  84 +++-
 net/fastboot.c                             | 515 +++++++++++++++++++++
 net/net.c                                  |  60 ++-
 net/netconsole.c                           |   4 +-
 net/nfs.c                                  |   1 -
 net/ping.c                                 |   2 -
 net/sntp.c                                 |   2 -
 53 files changed, 1607 insertions(+), 117 deletions(-)
 create mode 100644 Documentation/devel/devel.rst
 create mode 100644 Documentation/devel/parallel-execution.rst
 create mode 100644 common/slice.c
 create mode 100644 common/workqueue.c
 create mode 100644 include/fastboot_net.h
 create mode 100644 include/slice.h
 create mode 100644 include/work.h
 create mode 100644 net/fastboot.c

-- 
2.27.0


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

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

end of thread, other threads:[~2020-06-19  7:39 UTC | newest]

Thread overview: 32+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-17  8:11 [PATCH v4 00/19] Slices and fastboot over UDP Sascha Hauer
2020-06-17  8:11 ` [PATCH 01/19] Introduce slices Sascha Hauer
2020-06-17  8:11 ` [PATCH 02/19] Add workqueues Sascha Hauer
2020-06-17 18:30   ` Daniel Glöckner
2020-06-17 19:56     ` Sascha Hauer
2020-06-17  8:11 ` [PATCH 03/19] ratp: Switch to workqueues Sascha Hauer
2020-06-17  8:11 ` [PATCH 04/19] net: Add a slice to struct eth_device Sascha Hauer
2020-06-17  8:11 ` [PATCH 05/19] net: mdiobus: Add slice Sascha Hauer
2020-06-17  8:11 ` [PATCH 06/19] usb: Add a slice to usb host controllers Sascha Hauer
2020-06-17  8:11 ` [PATCH 07/19] usbnet: Add slice Sascha Hauer
2020-06-17  8:11 ` [PATCH 08/19] net: Call net_poll() in a poller Sascha Hauer
2020-06-17  8:11 ` [PATCH 09/19] net: reply to ping requests Sascha Hauer
2020-06-17  8:11 ` [PATCH 10/19] usbnet: Be more friendly in the receive path Sascha Hauer
2020-06-17  8:11 ` [PATCH 11/19] defconfigs: update renamed fastboot options Sascha Hauer
2020-06-17  8:11 ` [PATCH 12/19] globalvar: Add helper for deprecated variable names Sascha Hauer
2020-06-17  8:11 ` [PATCH 13/19] fastboot: rename usbgadget.fastboot_* variables to fastboot.* Sascha Hauer
2020-06-17  8:11 ` [PATCH 14/19] fastboot: remove double print Sascha Hauer
2020-06-17 18:24   ` Daniel Glöckner
2020-06-17 19:54     ` Sascha Hauer
2020-06-18 19:08       ` Daniel Glöckner
2020-06-19  7:01         ` Sascha Hauer
2020-06-17  8:11 ` [PATCH 15/19] fastboot net: implement fastboot over UDP Sascha Hauer
2020-06-17 19:32   ` Daniel Glöckner
2020-06-18 11:59     ` Sascha Hauer
2020-06-18 18:33       ` Daniel Glöckner
2020-06-19  7:38         ` Sascha Hauer
2020-06-17  8:11 ` [PATCH 16/19] usb: fastboot: execute commands in command context Sascha Hauer
2020-06-17 19:40   ` Daniel Glöckner
2020-06-18  7:26     ` Sascha Hauer
2020-06-17  8:11 ` [PATCH 17/19] Add WARN_ONCE() macro Sascha Hauer
2020-06-17  8:11 ` [PATCH 18/19] fs: Warn when filesystem operations are called from a poller Sascha Hauer
2020-06-17  8:11 ` [PATCH 19/19] Documentation: Add document for parallel execution in barebox Sascha Hauer

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