[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[cdi-devel] [PATCH 0/8] USB support



From: Max Reitz <max@xxxxxxxxxx>

This series adds some long-missing USB drivers to the CDI repository
(and defines the required interfaces).

For now, it only supports control and bulk transfers (which are enough
for mass storage devices), no hotplugging, no suspend/resume, neither a
lot of other things.

The drivers added by this series are an EHCI driver, a USB 2.0 bus
driver (including a hub driver), and a bulk-only mass storage driver
(with a SCSI interface; should be the right thing to drive your average
thumb drive (and maybe even HDDs), but will not work for e.g. USB floppy
drives).

I tested these drivers using µxoµcota in qemu and on a real machine
(which only has EHCIs and xHCIs; every EHCI has a high speed hub to
communicate with low and full speed devices, so there is no need for
companion controllers).


Max Reitz (8):
  cdi/misc: Add CDI_UPCAST and endianness functions
  cdi/scsi, cdi.h: Remove týndur-specific fields
  cdi/scsi: Add LUN count to cdi_scsi_device
  cdi.h: Add cdi_handle_bus_device()
  cdi/usb: Add headers
  ehci: Add EHCI driver
  usb: Add USB 2.0 bus driver
  usb-storage: Add USB mass storage driver

 ehci/ehci.c                  | 572 ++++++++++++++++++++++++++++
 ehci/ehci.h                  | 172 +++++++++
 ehci/main.c                  |  68 ++++
 include/cdi.h                |  27 +-
 include/cdi/misc.h           |  58 +++
 include/cdi/scsi.h           |   8 +-
 include/cdi/usb-structures.h | 118 ++++++
 include/cdi/usb.h            | 217 +++++++++++
 include/cdi/usb_hcd.h        | 159 ++++++++
 usb-storage/main.c           |  76 ++++
 usb-storage/usb-storage.c    | 216 +++++++++++
 usb-storage/usb-storage.h    |  34 ++
 usb/main.c                   |  61 +++
 usb/usb-hubs.h               |  78 ++++
 usb/usb.c                    | 864 +++++++++++++++++++++++++++++++++++++++++++
 usb/usb.h                    |  86 +++++
 16 files changed, 2805 insertions(+), 9 deletions(-)
 create mode 100644 ehci/ehci.c
 create mode 100644 ehci/ehci.h
 create mode 100644 ehci/main.c
 create mode 100644 include/cdi/usb-structures.h
 create mode 100644 include/cdi/usb.h
 create mode 100644 include/cdi/usb_hcd.h
 create mode 100644 usb-storage/main.c
 create mode 100644 usb-storage/usb-storage.c
 create mode 100644 usb-storage/usb-storage.h
 create mode 100644 usb/main.c
 create mode 100644 usb/usb-hubs.h
 create mode 100644 usb/usb.c
 create mode 100644 usb/usb.h

-- 
2.3.4