2.27.2. usb_host_class_mass_storage — Mass Storage

The USB mass storage device class (also known as USB MSC or UMS) is a set of computing communications protocols defined by the USB Implementers Forum that makes a USB device accessible to a host computing device and enables file transfers between the host and the USB device. To a host, the USB device acts as an external hard drive; the protocol set interfaces with a number of storage devices.

More information on Wikipedia.

Source code: src/drivers/usb/host/class/mass_storage.h, src/drivers/usb/host/class/mass_storage.c


int usb_host_class_mass_storage_init(struct usb_host_class_mass_storage_driver_t *self_p, struct usb_host_driver_t *usb_p, struct usb_host_class_mass_storage_device_t *devices_p, size_t length)
int usb_host_class_mass_storage_start(struct usb_host_class_mass_storage_driver_t *self_p)
int usb_host_class_mass_storage_stop(struct usb_host_class_mass_storage_driver_t *self_p)
ssize_t usb_host_class_mass_storage_device_read(struct usb_host_device_t *device_p, void *buf_p, size_t address, size_t size)
struct usb_host_class_mass_storage_device_t
#include <mass_storage.h>

Public Members

uint8_t buf[1]
struct usb_host_class_mass_storage_driver_t

Public Members

struct usb_host_driver_t *usb_p
struct usb_host_class_mass_storage_device_t *devices_p
size_t length
size_t size
struct usb_host_class_mass_storage_driver_t::@14 usb_host_class_mass_storage_driver_t::report
struct usb_host_device_driver_t device_driver