//设备错误代码：
typedef enum dev_err {
    DEV_ERR_NONE = 0,
    DEV_ERR_NOT_MOUNT,
    DEV_ERR_OVER_CAPACITY,

    DEV_ERR_UNKNOW_CLASS,

    DEV_ERR_NOT_READY,//设备已经在线，但是没初始化完成
    DEV_ERR_LUN,

    DEV_ERR_TIMEOUT,
    DEV_ERR_CMD_TIMEOUT,
    DEV_ERR_READ_TIMEOUT,//0x08
    DEV_ERR_WRITE_TIMEOUT,

    DEV_ERR_OFFLINE,//0x0a

    DEV_ERR_CRC,
    DEV_ERR_CMD_CRC,
    DEV_ERR_READ_CRC,
    DEV_ERR_WRITE_CRC,

    DEV_ERR_CONTROL_STALL,
    DEV_ERR_RXSTALL,//0x10
    DEV_ERR_TXSTALL,
    DEV_ERR_CONTROL,

    DEV_ERR_NOT_STORAGE,
    DEV_ERR_INVALID_PATH,
    DEV_ERR_INVALID_DATA,
    DEV_ERR_OUTOFMEMORY,
    DEV_ERR_HANDLE_FREE,
    DEV_ERR_INVALID_HANDLE,//24
    DEV_ERR_INVALID_BUF,
    DEV_ERR_INUSE,
    DEV_ERR_NO_READ,
    DEV_ERR_NO_WRITE,
    DEV_ERR_NO_IOCTL,
    DEV_ERR_NO_POWER,
    DEV_ERR_NOT_EXIST,
    DEV_ERR_UNKNOW,
} DEV_ERR;

