SyterKit 0.4.0.x
SyterKit is a bare-metal framework
Loading...
Searching...
No Matches
Classes | Macros | Typedefs | Functions | Variables
usb_mass.c File Reference
#include <io.h>
#include <stdarg.h>
#include <stdbool.h>
#include <stddef.h>
#include <stdint.h>
#include <types.h>
#include <common.h>
#include <log.h>
#include <sys-sdcard.h>
#include "usb.h"
#include "usb_defs.h"
Include dependency graph for usb_mass.c:

Classes

struct  mass_trans_set
 
struct  umass_bbb_cbw_t
 
struct  umass_bbb_csw_t
 

Macros

#define SUNXI_USB_STRING_LANGIDS   (0)
 
#define SUNXI_USB_STRING_IMANUFACTURER   (1)
 
#define SUNXI_USB_STRING_IPRODUCT   (2)
 
#define SUNXI_USB_STRING_ISERIALNUMBER   (3)
 
#define SUNXI_USB_MASS_DEV_MAX   (4)
 
#define SUNXI_USB_MASS_IDLE   (0)
 
#define SUNXI_USB_MASS_SETUP   (1)
 
#define SUNXI_USB_MASS_SEND_DATA   (2)
 
#define SUNXI_USB_MASS_RECEIVE_DATA   (3)
 
#define SUNXI_USB_MASS_STATUS   (4)
 
#define CBWCDBLENGTH   16
 
#define SUNXI_MASS_RECV_MEM_SIZE   (512 * 1024)
 
#define SUNXI_MASS_SEND_MEM_SIZE   (512 * 1024)
 
#define SCSI_CHANGE_DEF   0x40 /* Change Definition (Optional) */
 
#define SCSI_COMPARE   0x39 /* Compare (O) */
 Commands Unique to Direct Access Devices %%%.
 
#define SCSI_COPY   0x18 /* Copy (O) */
 
#define SCSI_COP_VERIFY   0x3A /* Copy and Verify (O) */
 
#define SCSI_INQUIRY   0x12 /* Inquiry (MANDATORY) */
 
#define SCSI_LOG_SELECT   0x4C /* Log Select (O) */
 
#define SCSI_LOG_SENSE   0x4D /* Log Sense (O) */
 
#define SCSI_MODE_SEL6   0x15 /* Mode Select 6-byte (Device Specific) */
 
#define SCSI_MODE_SEL10   0x55 /* Mode Select 10-byte (Device Specific) */
 
#define SCSI_MODE_SEN6   0x1A /* Mode Sense 6-byte (Device Specific) */
 
#define SCSI_MODE_SEN10   0x5A /* Mode Sense 10-byte (Device Specific) */
 
#define SCSI_READ_BUFF   0x3C /* Read Buffer (O) */
 
#define SCSI_REQ_SENSE   0x03 /* Request Sense (MANDATORY) */
 
#define SCSI_SEND_DIAG   0x1D /* Send Diagnostic (O) */
 
#define SCSI_TST_U_RDY   0x00 /* Test Unit Ready (MANDATORY) */
 
#define SCSI_WRITE_BUFF   0x3B /* Write Buffer (O) */
 
#define SCSI_COMPARE   0x39 /* Compare (O) */
 Commands Unique to Direct Access Devices %%%.
 
#define SCSI_FORMAT   0x04 /* Format Unit (MANDATORY) */
 
#define SCSI_LCK_UN_CAC   0x36 /* Lock Unlock Cache (O) */
 
#define SCSI_PREFETCH   0x34 /* Prefetch (O) */
 
#define SCSI_MED_REMOVL   0x1E /* Prevent/Allow medium Removal (O) */
 
#define SCSI_READ6   0x08 /* Read 6-byte (MANDATORY) */
 
#define SCSI_READ10   0x28 /* Read 10-byte (MANDATORY) */
 
#define SCSI_RD_CAPAC   0x25 /* Read Capacity (MANDATORY) */
 
#define SCSI_RD_DEFECT   0x37 /* Read Defect Data (O) */
 
#define SCSI_READ_LONG   0x3E /* Read Long (O) */
 
#define SCSI_REASS_BLK   0x07 /* Reassign Blocks (O) */
 
#define SCSI_RCV_DIAG   0x1C /* Receive Diagnostic Results (O) */
 
#define SCSI_RELEASE   0x17 /* Release Unit (MANDATORY) */
 
#define SCSI_REZERO   0x01 /* Rezero Unit (O) */
 
#define SCSI_SRCH_DAT_E   0x31 /* Search Data Equal (O) */
 
#define SCSI_SRCH_DAT_H   0x30 /* Search Data High (O) */
 
#define SCSI_SRCH_DAT_L   0x32 /* Search Data Low (O) */
 
#define SCSI_SEEK6   0x0B /* Seek 6-Byte (O) */
 
#define SCSI_SEEK10   0x2B /* Seek 10-Byte (O) */
 
#define SCSI_SEND_DIAG   0x1D /* Send Diagnostics (MANDATORY) */
 
#define SCSI_SET_LIMIT   0x33 /* Set Limits (O) */
 
#define SCSI_START_STP   0x1B /* Start/Stop Unit (O) */
 
#define SCSI_SYNC_CACHE   0x35 /* Synchronize Cache (O) */
 
#define SCSI_VERIFY   0x2F /* Verify (O) */
 
#define SCSI_WRITE6   0x0A /* Write 6-Byte (MANDATORY) */
 
#define SCSI_WRITE10   0x2A /* Write 10-Byte (MANDATORY) */
 
#define SCSI_WRT_VERIFY   0x2E /* Write and Verify (O) */
 
#define SCSI_WRITE_LONG   0x3F /* Write Long (O) */
 
#define SCSI_WRITE_SAME   0x41 /* Write Same (O) */
 
#define SCSI_RD_FMT_CAPAC   0x23 /* Read format caacity */
 

Typedefs

typedef struct mass_trans_set mass_trans_set_t
 

Functions

struct umass_bbb_cbw_t __attribute__ ((packed))
 
static int usb_mass_usb_set_interface (struct usb_device_request *req)
 USB MASS: Set interface.
 
static int usb_mass_usb_set_address (struct usb_device_request *req)
 USB MASS: Set address.
 
static int usb_mass_usb_set_configuration (struct usb_device_request *req)
 USB MASS: Set configuration.
 
static int usb_mass_usb_get_descriptor (struct usb_device_request *req, uint8_t *buffer)
 usb_mass_usb_get_descriptor - Get USB descriptors
 
static int usb_mass_usb_get_status (struct usb_device_request *req, uint8_t *buffer)
 usb_mass_usb_get_status - Handle a USB request to retrieve the status of the device
 
static int sunxi_usb_mass_init (void)
 sunxi_usb_mass_init - Initialize the USB Mass Storage driver
 
static int sunxi_mass_exit (void)
 sunxi_mass_exit - Exit the USB Mass Storage driver
 
static void sunxi_mass_reset (void)
 sunxi_mass_reset - Reset the USB Mass Storage driver
 
static void sunxi_mass_usb_rx_dma_isr (void *p_arg)
 sunxi_mass_usb_rx_dma_isr - Handle the USB Mass Storage RX DMA interrupt
 
static void sunxi_mass_usb_tx_dma_isr (void *p_arg)
 sunxi_mass_usb_tx_dma_isr - Handle the USB Mass Storage TX DMA interrupt
 
static int sunxi_mass_standard_req_op (uint32_t cmd, struct usb_device_request *req, uint8_t *buffer)
 sunxi_mass_standard_req_op - Handle standard USB Mass Storage requests
 
static int sunxi_mass_nonstandard_req_op (uint32_t cmd, struct usb_device_request *req, uint8_t *buffer, uint32_t data_status)
 sunxi_mass_nonstandard_req_op - Handle non-standard USB Mass Storage requests
 
static int sunxi_mass_state_loop (void *buffer)
 sunxi_mass_state_loop - State machine for USB Mass Storage operation
 
 sunxi_usb_module_init (SUNXI_USB_DEVICE_MASS, sunxi_usb_mass_init, sunxi_mass_exit, sunxi_mass_reset, sunxi_mass_standard_req_op, sunxi_mass_nonstandard_req_op, sunxi_mass_state_loop, sunxi_mass_usb_rx_dma_isr, sunxi_mass_usb_tx_dma_isr)
 

Variables

const uint8_t normal_lang_id [8] = {0x04, 0x03, 0x09, 0x04, '\0'}
 
const uint8_t sunxi_usb_mass_serial_num0 [32] = "20240127003501"
 
const uint8_t sunxi_usb_mass_manufacturer [32] = "Yuzuki HD"
 
const uint8_t sunxi_usb_mass_product [32] = "USB Mass Storage"
 
uint8_tsunxi_usb_mass_dev [SUNXI_USB_MASS_DEV_MAX]
 
const uint8_t inquiry_data [40]
 
const uint8_t request_sense [20]
 
uint32_t dCBWSignature
 
uint32_t dCBWTag
 
uint32_t dCBWDataTransferLength
 
uint8_t bCBWFlags
 
uint8_t bCBWLUN
 
uint8_t bCDBLength
 
uint8_t CBWCDB [CBWCDBLENGTH]
 
uint32_t dCSWSignature
 
uint32_t dCSWTag
 
uint32_t dCSWDataResidue
 
uint8_t bCSWStatus
 
static int sunxi_usb_mass_write_enable = 0
 
static int sunxi_usb_mass_status = SUNXI_USB_MASS_IDLE
 
static mass_trans_set_t trans_data
 

Macro Definition Documentation

◆ CBWCDBLENGTH

#define CBWCDBLENGTH   16

◆ SCSI_CHANGE_DEF

#define SCSI_CHANGE_DEF   0x40 /* Change Definition (Optional) */

◆ SCSI_COMPARE [1/2]

#define SCSI_COMPARE   0x39 /* Compare (O) */

Commands Unique to Direct Access Devices %%%.

◆ SCSI_COMPARE [2/2]

#define SCSI_COMPARE   0x39 /* Compare (O) */

Commands Unique to Direct Access Devices %%%.

◆ SCSI_COP_VERIFY

#define SCSI_COP_VERIFY   0x3A /* Copy and Verify (O) */

◆ SCSI_COPY

#define SCSI_COPY   0x18 /* Copy (O) */

◆ SCSI_FORMAT

#define SCSI_FORMAT   0x04 /* Format Unit (MANDATORY) */

◆ SCSI_INQUIRY

#define SCSI_INQUIRY   0x12 /* Inquiry (MANDATORY) */

◆ SCSI_LCK_UN_CAC

#define SCSI_LCK_UN_CAC   0x36 /* Lock Unlock Cache (O) */

◆ SCSI_LOG_SELECT

#define SCSI_LOG_SELECT   0x4C /* Log Select (O) */

◆ SCSI_LOG_SENSE

#define SCSI_LOG_SENSE   0x4D /* Log Sense (O) */

◆ SCSI_MED_REMOVL

#define SCSI_MED_REMOVL   0x1E /* Prevent/Allow medium Removal (O) */

◆ SCSI_MODE_SEL10

#define SCSI_MODE_SEL10   0x55 /* Mode Select 10-byte (Device Specific) */

◆ SCSI_MODE_SEL6

#define SCSI_MODE_SEL6   0x15 /* Mode Select 6-byte (Device Specific) */

◆ SCSI_MODE_SEN10

#define SCSI_MODE_SEN10   0x5A /* Mode Sense 10-byte (Device Specific) */

◆ SCSI_MODE_SEN6

#define SCSI_MODE_SEN6   0x1A /* Mode Sense 6-byte (Device Specific) */

◆ SCSI_PREFETCH

#define SCSI_PREFETCH   0x34 /* Prefetch (O) */

◆ SCSI_RCV_DIAG

#define SCSI_RCV_DIAG   0x1C /* Receive Diagnostic Results (O) */

◆ SCSI_RD_CAPAC

#define SCSI_RD_CAPAC   0x25 /* Read Capacity (MANDATORY) */

◆ SCSI_RD_DEFECT

#define SCSI_RD_DEFECT   0x37 /* Read Defect Data (O) */

◆ SCSI_RD_FMT_CAPAC

#define SCSI_RD_FMT_CAPAC   0x23 /* Read format caacity */

◆ SCSI_READ10

#define SCSI_READ10   0x28 /* Read 10-byte (MANDATORY) */

◆ SCSI_READ6

#define SCSI_READ6   0x08 /* Read 6-byte (MANDATORY) */

◆ SCSI_READ_BUFF

#define SCSI_READ_BUFF   0x3C /* Read Buffer (O) */

◆ SCSI_READ_LONG

#define SCSI_READ_LONG   0x3E /* Read Long (O) */

◆ SCSI_REASS_BLK

#define SCSI_REASS_BLK   0x07 /* Reassign Blocks (O) */

◆ SCSI_RELEASE

#define SCSI_RELEASE   0x17 /* Release Unit (MANDATORY) */

◆ SCSI_REQ_SENSE

#define SCSI_REQ_SENSE   0x03 /* Request Sense (MANDATORY) */

◆ SCSI_REZERO

#define SCSI_REZERO   0x01 /* Rezero Unit (O) */

◆ SCSI_SEEK10

#define SCSI_SEEK10   0x2B /* Seek 10-Byte (O) */

◆ SCSI_SEEK6

#define SCSI_SEEK6   0x0B /* Seek 6-Byte (O) */

◆ SCSI_SEND_DIAG [1/2]

#define SCSI_SEND_DIAG   0x1D /* Send Diagnostic (O) */

◆ SCSI_SEND_DIAG [2/2]

#define SCSI_SEND_DIAG   0x1D /* Send Diagnostics (MANDATORY) */

◆ SCSI_SET_LIMIT

#define SCSI_SET_LIMIT   0x33 /* Set Limits (O) */

◆ SCSI_SRCH_DAT_E

#define SCSI_SRCH_DAT_E   0x31 /* Search Data Equal (O) */

◆ SCSI_SRCH_DAT_H

#define SCSI_SRCH_DAT_H   0x30 /* Search Data High (O) */

◆ SCSI_SRCH_DAT_L

#define SCSI_SRCH_DAT_L   0x32 /* Search Data Low (O) */

◆ SCSI_START_STP

#define SCSI_START_STP   0x1B /* Start/Stop Unit (O) */

◆ SCSI_SYNC_CACHE

#define SCSI_SYNC_CACHE   0x35 /* Synchronize Cache (O) */

◆ SCSI_TST_U_RDY

#define SCSI_TST_U_RDY   0x00 /* Test Unit Ready (MANDATORY) */

◆ SCSI_VERIFY

#define SCSI_VERIFY   0x2F /* Verify (O) */

◆ SCSI_WRITE10

#define SCSI_WRITE10   0x2A /* Write 10-Byte (MANDATORY) */

◆ SCSI_WRITE6

#define SCSI_WRITE6   0x0A /* Write 6-Byte (MANDATORY) */

◆ SCSI_WRITE_BUFF

#define SCSI_WRITE_BUFF   0x3B /* Write Buffer (O) */

◆ SCSI_WRITE_LONG

#define SCSI_WRITE_LONG   0x3F /* Write Long (O) */

◆ SCSI_WRITE_SAME

#define SCSI_WRITE_SAME   0x41 /* Write Same (O) */

◆ SCSI_WRT_VERIFY

#define SCSI_WRT_VERIFY   0x2E /* Write and Verify (O) */

◆ SUNXI_MASS_RECV_MEM_SIZE

#define SUNXI_MASS_RECV_MEM_SIZE   (512 * 1024)

◆ SUNXI_MASS_SEND_MEM_SIZE

#define SUNXI_MASS_SEND_MEM_SIZE   (512 * 1024)

◆ SUNXI_USB_MASS_DEV_MAX

#define SUNXI_USB_MASS_DEV_MAX   (4)

◆ SUNXI_USB_MASS_IDLE

#define SUNXI_USB_MASS_IDLE   (0)

◆ SUNXI_USB_MASS_RECEIVE_DATA

#define SUNXI_USB_MASS_RECEIVE_DATA   (3)

◆ SUNXI_USB_MASS_SEND_DATA

#define SUNXI_USB_MASS_SEND_DATA   (2)

◆ SUNXI_USB_MASS_SETUP

#define SUNXI_USB_MASS_SETUP   (1)

◆ SUNXI_USB_MASS_STATUS

#define SUNXI_USB_MASS_STATUS   (4)

◆ SUNXI_USB_STRING_IMANUFACTURER

#define SUNXI_USB_STRING_IMANUFACTURER   (1)

◆ SUNXI_USB_STRING_IPRODUCT

#define SUNXI_USB_STRING_IPRODUCT   (2)

◆ SUNXI_USB_STRING_ISERIALNUMBER

#define SUNXI_USB_STRING_ISERIALNUMBER   (3)

◆ SUNXI_USB_STRING_LANGIDS

#define SUNXI_USB_STRING_LANGIDS   (0)

Typedef Documentation

◆ mass_trans_set_t

Function Documentation

◆ __attribute__()

struct umass_bbb_cbw_t __attribute__ ( (packed)  )

◆ sunxi_mass_exit()

static int sunxi_mass_exit ( void  )
static

sunxi_mass_exit - Exit the USB Mass Storage driver

This function frees the memory allocated for data transmission and exits the USB Mass Storage driver.

Returns
: 0 if exit is successful, otherwise an error code

◆ sunxi_mass_nonstandard_req_op()

static int sunxi_mass_nonstandard_req_op ( uint32_t  cmd,
struct usb_device_request req,
uint8_t buffer,
uint32_t  data_status 
)
static

sunxi_mass_nonstandard_req_op - Handle non-standard USB Mass Storage requests

This function handles non-standard USB Mass Storage requests by calling the corresponding functions based on the request type and request code.

Parameters
cmdThe command code for the request
reqPointer to the USB device request structure
bufferPointer to the data buffer
data_statusThe status of the data transfer
Returns
: The result of the operation (error code or success)

◆ sunxi_mass_reset()

static void sunxi_mass_reset ( void  )
static

sunxi_mass_reset - Reset the USB Mass Storage driver

This function resets the USB Mass Storage driver by setting initial values.

◆ sunxi_mass_standard_req_op()

static int sunxi_mass_standard_req_op ( uint32_t  cmd,
struct usb_device_request req,
uint8_t buffer 
)
static

sunxi_mass_standard_req_op - Handle standard USB Mass Storage requests

This function handles standard USB Mass Storage requests by calling the corresponding functions based on the command.

Parameters
cmdThe command code for the request
reqPointer to the USB device request structure
bufferPointer to the data buffer
Returns
: The result of the operation (error code or success)

◆ sunxi_mass_state_loop()

static int sunxi_mass_state_loop ( void *  buffer)
static

sunxi_mass_state_loop - State machine for USB Mass Storage operation

This function implements a state machine for USB Mass Storage operation. It handles the different stages of the operation, such as sending/receiving data, checking status, and handling errors.

Parameters
bufferPointer to the data buffer
Returns
: The result of the operation (error code or success)

◆ sunxi_mass_usb_rx_dma_isr()

static void sunxi_mass_usb_rx_dma_isr ( void *  p_arg)
static

sunxi_mass_usb_rx_dma_isr - Handle the USB Mass Storage RX DMA interrupt

This function is called when a USB Mass Storage RX DMA interrupt occurs. It sets a flag to indicate that the USB host is ready to write data.

Parameters
p_argPointer to a void argument (not used)

◆ sunxi_mass_usb_tx_dma_isr()

static void sunxi_mass_usb_tx_dma_isr ( void *  p_arg)
static

sunxi_mass_usb_tx_dma_isr - Handle the USB Mass Storage TX DMA interrupt

This function is called when a USB Mass Storage TX DMA interrupt occurs. It currently does not perform any action.

Parameters
p_argPointer to a void argument (not used)

◆ sunxi_usb_mass_init()

static int sunxi_usb_mass_init ( void  )
static

sunxi_usb_mass_init - Initialize the USB Mass Storage driver

This function initializes the USB Mass Storage driver by allocating memory for data transmission and setting up initial values.

Returns
: 0 if initialization is successful, otherwise -1

◆ sunxi_usb_module_init()

◆ usb_mass_usb_get_descriptor()

static int usb_mass_usb_get_descriptor ( struct usb_device_request req,
uint8_t buffer 
)
static

usb_mass_usb_get_descriptor - Get USB descriptors

This function retrieves USB descriptors based on the provided request.

Parameters
reqPointer to the USB device request structure
bufferPointer to the buffer to hold the descriptor data
Returns
: Error code indicating the result of the function

◆ usb_mass_usb_get_status()

static int usb_mass_usb_get_status ( struct usb_device_request req,
uint8_t buffer 
)
static

usb_mass_usb_get_status - Handle a USB request to retrieve the status of the device

This function handles a USB request to retrieve the status of the USB device. The status is returned in a buffer provided by the caller.

Parameters
reqPointer to the USB device request structure
bufferPointer to the buffer to hold the status data
Returns
: Error code indicating the result of the function SUNXI_USB_REQ_SUCCESSED if the request is successful SUNXI_USB_REQ_OP_ERR if there is an operational error

◆ usb_mass_usb_set_address()

static int usb_mass_usb_set_address ( struct usb_device_request req)
static

USB MASS: Set address.

This function handles the set address request for the USB Mass Storage device. It extracts the new address from the request and calls sunxi_usb_set_address() to set the new address.

Parameters
reqThe USB device request
Returns
SUNXI_USB_REQ_SUCCESSED on success

◆ usb_mass_usb_set_configuration()

static int usb_mass_usb_set_configuration ( struct usb_device_request req)
static

USB MASS: Set configuration.

This function handles the set configuration request for the USB Mass Storage device. It checks if the requested configuration is valid. If it is, it calls sunxi_usb_ep_reset() to reset the USB endpoints. Otherwise, it prints an error message and returns SUNXI_USB_REQ_OP_ERR.

Parameters
reqThe USB device request
Returns
SUNXI_USB_REQ_SUCCESSED on success, SUNXI_USB_REQ_OP_ERR on error

◆ usb_mass_usb_set_interface()

static int usb_mass_usb_set_interface ( struct usb_device_request req)
static

USB MASS: Set interface.

This function handles the set interface request for the USB Mass Storage device. It checks if the requested interface and alternate setting are valid. If they are, it calls sunxi_usb_ep_reset() to reset the USB endpoints. Otherwise, it prints an error message and returns SUNXI_USB_REQ_OP_ERR.

Parameters
reqThe USB device request
Returns
SUNXI_USB_REQ_SUCCESSED on success, SUNXI_USB_REQ_OP_ERR on error

Variable Documentation

◆ bCBWFlags

uint8_t bCBWFlags

◆ bCBWLUN

uint8_t bCBWLUN

◆ bCDBLength

uint8_t bCDBLength

◆ bCSWStatus

uint8_t bCSWStatus

◆ CBWCDB

◆ dCBWDataTransferLength

uint32_t dCBWDataTransferLength

◆ dCBWSignature

uint32_t dCBWSignature

◆ dCBWTag

uint32_t dCBWTag

◆ dCSWDataResidue

uint32_t dCSWDataResidue

◆ dCSWSignature

uint32_t dCSWSignature

◆ dCSWTag

uint32_t dCSWTag

◆ inquiry_data

const uint8_t inquiry_data[40]
Initial value:
= {
0x00, 0x80, 0x02, 0x02, 0x1f,
0x00, 0x00, 0x00,
'U', 'S', 'B', '2', '.', '0', 0x00, 0x00,
'U', 'S', 'B', ' ', 'S', 't', 'o', 'r', 'a', 'g', 'e',
0x00, 0x00, 0x00, 0x00, 0x00,
'0', '1', '0', '0', '\0'
}

◆ normal_lang_id

const uint8_t normal_lang_id[8] = {0x04, 0x03, 0x09, 0x04, '\0'}

◆ request_sense

const uint8_t request_sense[20]
Initial value:
= {
0x07, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00,
0x00, 0x00, 0x00, 0x3a, 0x00, 0x00, 0x00, 0x00, 0x00
}

◆ sunxi_usb_mass_dev

uint8_t* sunxi_usb_mass_dev[SUNXI_USB_MASS_DEV_MAX]
Initial value:
= {
}
const uint8_t normal_lang_id[8]
Definition usb_mass.c:18
const uint8_t sunxi_usb_mass_manufacturer[32]
Definition usb_mass.c:20
const uint8_t sunxi_usb_mass_serial_num0[32]
Definition usb_mass.c:19
const uint8_t sunxi_usb_mass_product[32]
Definition usb_mass.c:21

◆ sunxi_usb_mass_manufacturer

const uint8_t sunxi_usb_mass_manufacturer[32] = "Yuzuki HD"

◆ sunxi_usb_mass_product

const uint8_t sunxi_usb_mass_product[32] = "USB Mass Storage"

◆ sunxi_usb_mass_serial_num0

const uint8_t sunxi_usb_mass_serial_num0[32] = "20240127003501"

◆ sunxi_usb_mass_status

int sunxi_usb_mass_status = SUNXI_USB_MASS_IDLE
static

◆ sunxi_usb_mass_write_enable

int sunxi_usb_mass_write_enable = 0
static

◆ trans_data

mass_trans_set_t trans_data
static