/USBX-v6.2.1/common/usbx_device_classes/src/ |
D | ux_device_class_storage_tasks_run.c | 37 static inline UINT _ux_device_class_storage_task_usb(UX_SLAVE_CLASS_STORAGE *storage); 39 static inline UINT _ux_device_class_storage_reset_wait(UX_SLAVE_CLASS_STORAGE *storage); 40 static inline VOID _ux_device_class_storage_cbw_receive(UX_SLAVE_CLASS_STORAGE *storage); 41 static inline VOID _ux_device_class_storage_cbw_process(UX_SLAVE_CLASS_STORAGE *storage); 42 static inline VOID _ux_device_class_storage_cmd_process(UX_SLAVE_CLASS_STORAGE *storage, UCHAR *cbw… 43 static inline VOID _ux_device_class_storage_data_cases_check(UX_SLAVE_CLASS_STORAGE *storage); 44 static inline VOID _ux_device_class_storage_trans_start(UX_SLAVE_CLASS_STORAGE *storage); 45 static inline UINT _ux_device_class_storage_trans_wait(UX_SLAVE_CLASS_STORAGE *storage); 46 static inline VOID _ux_device_class_storage_trans_error(UX_SLAVE_CLASS_STORAGE *storage); 47 static inline UINT _ux_device_class_storage_data_next(UX_SLAVE_CLASS_STORAGE *storage); [all …]
|
D | ux_device_class_storage_activate.c | 85 UX_SLAVE_CLASS_STORAGE *storage; in _ux_device_class_storage_activate() local 95 storage = (UX_SLAVE_CLASS_STORAGE *)class_ptr -> ux_slave_class_instance; in _ux_device_class_storage_activate() 101 interface_ptr -> ux_slave_interface_class_instance = (VOID *)storage; in _ux_device_class_storage_activate() 104 storage -> ux_slave_class_storage_interface = interface_ptr; in _ux_device_class_storage_activate() 120 storage -> ux_device_class_storage_ep_out = endpoint; in _ux_device_class_storage_activate() 123 storage -> ux_device_class_storage_ep_in = endpoint -> ux_slave_endpoint_next_endpoint; in _ux_device_class_storage_activate() 129 storage -> ux_device_class_storage_ep_in = endpoint; in _ux_device_class_storage_activate() 132 storage -> ux_device_class_storage_ep_out = endpoint -> ux_slave_endpoint_next_endpoint; in _ux_device_class_storage_activate() 136 storage -> ux_device_class_storage_buffer[0] = storage -> ux_device_class_storage_ep_out -> in _ux_device_class_storage_activate() 138 storage -> ux_device_class_storage_buffer[1] = storage -> ux_device_class_storage_ep_in -> in _ux_device_class_storage_activate() [all …]
|
D | ux_device_class_storage_read.c | 89 UINT _ux_device_class_storage_read(UX_SLAVE_CLASS_STORAGE *storage, ULONG lun, in _ux_device_class_storage_read() argument 129 …total_length = total_number_blocks * storage -> ux_slave_class_storage_lun[lun].ux_slave_class_st… in _ux_device_class_storage_read() 132 storage -> ux_slave_class_storage_csw_status = UX_SLAVE_CLASS_STORAGE_CSW_FAILED; in _ux_device_class_storage_read() 137 …status = storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_media_status(storage, … in _ux_device_class_storage_read() 138 … storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_media_id, &media_status); in _ux_device_class_storage_read() 141 …storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_request_sense_status = media_sta… in _ux_device_class_storage_read() 144 storage -> ux_device_class_storage_transfer = transfer_request; in _ux_device_class_storage_read() 151 … storage -> ux_slave_class_storage_csw_residue = storage -> ux_slave_class_storage_host_length; in _ux_device_class_storage_read() 158 storage -> ux_device_class_storage_state = UX_DEVICE_CLASS_STORAGE_STATE_DISK_WAIT; in _ux_device_class_storage_read() 159 storage -> ux_device_class_storage_cmd_state = UX_DEVICE_CLASS_STORAGE_CMD_READ; in _ux_device_class_storage_read() [all …]
|
D | ux_device_class_storage_write.c | 91 UINT _ux_device_class_storage_write(UX_SLAVE_CLASS_STORAGE *storage, ULONG lun, in _ux_device_class_storage_write() argument 128 …UX_TRACE_IN_LINE_INSERT(UX_TRACE_DEVICE_CLASS_STORAGE_WRITE, storage, lun, lba, total_number_block… in _ux_device_class_storage_write() 134 … status = storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_media_status(storage, in _ux_device_class_storage_write() 135 … lun, storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_media_id, &media_status); in _ux_device_class_storage_write() 138 …storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_request_sense_status = media_sta… in _ux_device_class_storage_write() 141 storage -> ux_slave_class_storage_csw_status = UX_SLAVE_CLASS_STORAGE_CSW_FAILED; in _ux_device_class_storage_write() 158 …if (storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_media_read_only_flag == UX_T… in _ux_device_class_storage_write() 162 storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_request_sense_status = in _ux_device_class_storage_write() 177 …total_length = total_number_blocks * storage -> ux_slave_class_storage_lun[lun].ux_slave_class_st… in _ux_device_class_storage_write() 182 storage -> ux_device_class_storage_state = UX_DEVICE_CLASS_STORAGE_STATE_TRANS_START; in _ux_device_class_storage_write() [all …]
|
D | ux_device_class_storage_synchronize_cache.c | 86 UINT _ux_device_class_storage_synchronize_cache(UX_SLAVE_CLASS_STORAGE *storage, ULONG lun, in _ux_device_class_storage_synchronize_cache() argument 105 storage -> ux_slave_class_storage_csw_status = UX_SLAVE_CLASS_STORAGE_CSW_PASSED; in _ux_device_class_storage_synchronize_cache() 108 if (storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_media_flush == UX_NULL) in _ux_device_class_storage_synchronize_cache() 122 …UX_TRACE_IN_LINE_INSERT(UX_TRACE_DEVICE_CLASS_STORAGE_SYNCHRONIZE_CACHE, storage, lun, lba, number… in _ux_device_class_storage_synchronize_cache() 125 … status = storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_media_status(storage, in _ux_device_class_storage_synchronize_cache() 126 … lun, storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_media_id, &media_status); in _ux_device_class_storage_synchronize_cache() 129 …storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_request_sense_status = media_sta… in _ux_device_class_storage_synchronize_cache() 141 storage -> ux_device_class_storage_cmd_state = UX_DEVICE_CLASS_STORAGE_CMD_ERR; in _ux_device_class_storage_synchronize_cache() 144 storage -> ux_slave_class_storage_csw_status = UX_SLAVE_CLASS_STORAGE_CSW_FAILED; in _ux_device_class_storage_synchronize_cache() 155 storage -> ux_device_class_storage_state = UX_DEVICE_CLASS_STORAGE_STATE_DISK_WAIT; in _ux_device_class_storage_synchronize_cache() [all …]
|
D | ux_device_class_storage_inquiry.c | 96 UINT _ux_device_class_storage_inquiry(UX_SLAVE_CLASS_STORAGE *storage, ULONG lun, UX_SLAVE_ENDPOIN… in _ux_device_class_storage_inquiry() argument 109 …UX_TRACE_IN_LINE_INSERT(UX_TRACE_DEVICE_CLASS_STORAGE_INQUIRY, storage, lun, 0, 0, UX_TRACE_DEVICE… in _ux_device_class_storage_inquiry() 114 if (storage -> ux_slave_class_storage_host_length && in _ux_device_class_storage_inquiry() 115 (storage -> ux_slave_class_storage_cbw_flags & 0x80) == 0) in _ux_device_class_storage_inquiry() 118 storage -> ux_slave_class_storage_csw_status = UX_SLAVE_CLASS_STORAGE_CSW_PHASE_ERROR; in _ux_device_class_storage_inquiry() 127 inquiry_length = storage -> ux_slave_class_storage_host_length; in _ux_device_class_storage_inquiry() 143 storage -> ux_slave_class_storage_csw_status = UX_SLAVE_CLASS_STORAGE_CSW_PASSED; in _ux_device_class_storage_inquiry() 152 …inquiry_buffer[UX_SLAVE_CLASS_STORAGE_INQUIRY_RESPONSE_PERIPHERAL_TYPE] = (UCHAR)storage -> ux_sl… in _ux_device_class_storage_inquiry() 155 …inquiry_buffer[UX_SLAVE_CLASS_STORAGE_INQUIRY_RESPONSE_REMOVABLE_MEDIA] = (UCHAR)storage -> ux_sl… in _ux_device_class_storage_inquiry() 158 …if (storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_media_type == UX_SLAVE_CLASS… in _ux_device_class_storage_inquiry() [all …]
|
D | ux_device_class_storage_thread.c | 136 UX_SLAVE_CLASS_STORAGE *storage; in _ux_device_class_storage_thread() local 158 storage = (UX_SLAVE_CLASS_STORAGE *) class_ptr -> ux_slave_class_instance; in _ux_device_class_storage_thread() 168 interface_ptr = storage -> ux_slave_class_storage_interface; in _ux_device_class_storage_thread() 198 … (UCHAR)storage -> ux_slave_class_storage_csw_status != UX_SLAVE_CLASS_STORAGE_CSW_PHASE_ERROR) in _ux_device_class_storage_thread() 219 storage -> ux_slave_class_storage_cbw_lun = (UCHAR)lun; in _ux_device_class_storage_thread() 222 …storage -> ux_slave_class_storage_scsi_tag = _ux_utility_long_get(scsi_command + UX_SLAVE_CLASS_S… in _ux_device_class_storage_thread() 225 …storage -> ux_slave_class_storage_host_length = _ux_utility_long_get(scsi_command + UX_SLAVE_CLASS… in _ux_device_class_storage_thread() 228 … storage -> ux_slave_class_storage_cbw_flags = *(scsi_command + UX_SLAVE_CLASS_STORAGE_CBW_FLAGS); in _ux_device_class_storage_thread() 231 storage -> ux_slave_class_storage_csw_residue = 0; in _ux_device_class_storage_thread() 232 storage -> ux_slave_class_storage_csw_status = 0; in _ux_device_class_storage_thread() [all …]
|
D | ux_device_class_storage_csw_send.c | 94 UINT _ux_device_class_storage_csw_send(UX_SLAVE_CLASS_STORAGE *storage, ULONG lun, in _ux_device_class_storage_csw_send() argument 109 storage -> ux_device_class_storage_ep_out -> ux_slave_endpoint_transfer_request. in _ux_device_class_storage_csw_send() 110 ux_slave_transfer_request_data_pointer = storage -> ux_device_class_storage_buffer[0]; in _ux_device_class_storage_csw_send() 111 storage -> ux_device_class_storage_ep_in -> ux_slave_endpoint_transfer_request. in _ux_device_class_storage_csw_send() 112 ux_slave_transfer_request_data_pointer = storage -> ux_device_class_storage_buffer[1]; in _ux_device_class_storage_csw_send() 116 if (UX_DEVICE_CLASS_STORAGE_CSW_SKIP(&storage -> ux_slave_class_storage_csw_status)) in _ux_device_class_storage_csw_send() 132 …_ux_utility_long_put(&csw_buffer[UX_SLAVE_CLASS_STORAGE_CSW_TAG], storage -> ux_slave_class_storag… in _ux_device_class_storage_csw_send() 135 …_ux_utility_long_put(&csw_buffer[UX_SLAVE_CLASS_STORAGE_CSW_DATA_RESIDUE], storage -> ux_slave_cla… in _ux_device_class_storage_csw_send() 138 …csw_buffer[UX_SLAVE_CLASS_STORAGE_CSW_STATUS] = (UCHAR)storage -> ux_slave_class_storage_csw_statu… in _ux_device_class_storage_csw_send() 143 storage -> ux_device_class_storage_cmd_state = UX_DEVICE_CLASS_STORAGE_CMD_CSW; in _ux_device_class_storage_csw_send() [all …]
|
D | ux_device_class_storage_read_capacity.c | 90 UINT _ux_device_class_storage_read_capacity(UX_SLAVE_CLASS_STORAGE *storage, ULONG lun, in _ux_device_class_storage_read_capacity() argument 104 …UX_TRACE_IN_LINE_INSERT(UX_TRACE_DEVICE_CLASS_STORAGE_READ_CAPACITY, storage, lun, 0, 0, UX_TRACE_… in _ux_device_class_storage_read_capacity() 107 …status = storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_media_status(storage, … in _ux_device_class_storage_read_capacity() 108 … storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_media_id, &media_status); in _ux_device_class_storage_read_capacity() 111 …storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_request_sense_status = media_sta… in _ux_device_class_storage_read_capacity() 124 storage -> ux_slave_class_storage_csw_status = UX_SLAVE_CLASS_STORAGE_CSW_FAILED; in _ux_device_class_storage_read_capacity() 141 … storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_media_last_lba); in _ux_device_class_storage_read_capacity() 145 … storage -> ux_slave_class_storage_lun[lun].ux_slave_class_storage_media_block_length); in _ux_device_class_storage_read_capacity() 150 storage -> ux_device_class_storage_state = UX_DEVICE_CLASS_STORAGE_STATE_TRANS_START; in _ux_device_class_storage_read_capacity() 151 storage -> ux_device_class_storage_cmd_state = UX_DEVICE_CLASS_STORAGE_CMD_READ; in _ux_device_class_storage_read_capacity() [all …]
|
D | ux_device_class_storage_deactivate.c | 82 UX_SLAVE_CLASS_STORAGE *storage; in _ux_device_class_storage_deactivate() local 91 storage = (UX_SLAVE_CLASS_STORAGE *)class_ptr -> ux_slave_class_instance; in _ux_device_class_storage_deactivate() 95 endpoint_in = storage -> ux_device_class_storage_ep_in; in _ux_device_class_storage_deactivate() 96 endpoint_out = storage -> ux_device_class_storage_ep_out; in _ux_device_class_storage_deactivate() 100 storage -> ux_device_class_storage_buffer[0]; in _ux_device_class_storage_deactivate() 102 storage -> ux_device_class_storage_buffer[1]; in _ux_device_class_storage_deactivate() 106 endpoint_in = storage -> ux_slave_class_storage_interface -> ux_slave_interface_first_endpoint; in _ux_device_class_storage_deactivate() 131 if (storage -> ux_slave_class_storage_instance_deactivate != UX_NULL) in _ux_device_class_storage_deactivate() 135 storage -> ux_slave_class_storage_instance_deactivate(storage); in _ux_device_class_storage_deactivate() 139 …UX_TRACE_IN_LINE_INSERT(UX_TRACE_DEVICE_CLASS_STORAGE_DEACTIVATE, storage, 0, 0, 0, UX_TRACE_DEVIC… in _ux_device_class_storage_deactivate() [all …]
|
D | ux_device_class_storage_initialize.c | 91 UX_SLAVE_CLASS_STORAGE *storage; in _ux_device_class_storage_initialize() local 109 …storage = _ux_utility_memory_allocate(UX_NO_ALIGN, UX_REGULAR_MEMORY, sizeof(UX_SLAVE_CLASS_STORA… in _ux_device_class_storage_initialize() 112 if (storage == UX_NULL) in _ux_device_class_storage_initialize() 148 …storage -> ux_slave_class_storage_number_lun = storage_parameter -> ux_slave_class_storage_paramet… in _ux_device_class_storage_initialize() 151 for (lun_index = 0; lun_index < storage -> ux_slave_class_storage_number_lun; lun_index++) in _ux_device_class_storage_initialize() 163 …storage -> ux_slave_class_storage_lun[lun_index].ux_slave_class_storage_media_last_lba = sto… in _ux_device_class_storage_initialize() 164 …storage -> ux_slave_class_storage_lun[lun_index].ux_slave_class_storage_media_block_length = sto… in _ux_device_class_storage_initialize() 165 …storage -> ux_slave_class_storage_lun[lun_index].ux_slave_class_storage_media_type = sto… in _ux_device_class_storage_initialize() 166 …storage -> ux_slave_class_storage_lun[lun_index].ux_slave_class_storage_media_removable_flag = sto… in _ux_device_class_storage_initialize() 167 …storage -> ux_slave_class_storage_lun[lun_index].ux_slave_class_storage_media_read_only_flag = sto… in _ux_device_class_storage_initialize() [all …]
|
/USBX-v6.2.1/common/usbx_host_classes/src/ |
D | ux_host_class_storage_tasks_run.c | 36 static inline VOID _ux_host_class_storage_inst_tasks_run(UX_HOST_CLASS_STORAGE *storage); 38 static inline UINT _ux_host_class_storage_lun_is_removable(UX_HOST_CLASS_STORAGE *storage); 39 static inline UINT _ux_host_class_storage_lun_type_is_known(UX_HOST_CLASS_STORAGE *storage); 41 static inline VOID _ux_host_class_storage_max_lun_save(UX_HOST_CLASS_STORAGE *storage); 42 static inline UINT _ux_host_class_storage_inquiry_save(UX_HOST_CLASS_STORAGE *storage); 43 static inline VOID _ux_host_class_storage_format_cap_save(UX_HOST_CLASS_STORAGE *storage); 44 static inline VOID _ux_host_class_storage_capacity_save(UX_HOST_CLASS_STORAGE *storage); 45 static inline VOID _ux_host_class_storage_unit_ready_check(UX_HOST_CLASS_STORAGE *storage); 47 static inline VOID _ux_host_class_storage_lun_media_insert(UX_HOST_CLASS_STORAGE *storage); 49 static inline UINT _ux_host_class_storage_transport_sense_check(UX_HOST_CLASS_STORAGE *storage); [all …]
|
D | ux_host_class_storage_transport_run.c | 49 static inline VOID _ux_host_class_storage_transport_cbw(UX_HOST_CLASS_STORAGE *storage); 50 static inline VOID _ux_host_class_storage_transport_csw(UX_HOST_CLASS_STORAGE *storage); 51 static inline VOID _ux_host_class_storage_transport_trans_exit(UX_HOST_CLASS_STORAGE *storage); 52 static inline VOID _ux_host_class_storage_transport_trans_error(UX_HOST_CLASS_STORAGE *storage); 53 static inline VOID _ux_host_class_storage_transport_trans_next(UX_HOST_CLASS_STORAGE *storage); 54 static inline VOID _ux_host_class_storage_transport_trans_in_next(UX_HOST_CLASS_STORAGE *storage); 55 static inline VOID _ux_host_class_storage_transport_trans_out_next(UX_HOST_CLASS_STORAGE *storage); 56 static inline VOID _ux_host_class_storage_transport_status(UX_HOST_CLASS_STORAGE *storage); 57 static inline VOID _ux_host_class_storage_transport_ms_reset(UX_HOST_CLASS_STORAGE *storage); 58 static inline VOID _ux_host_class_storage_transport_ep_reset(UX_HOST_CLASS_STORAGE *storage); [all …]
|
D | ux_host_class_storage_activate.c | 90 UX_HOST_CLASS_STORAGE *storage; in _ux_host_class_storage_activate() local 100 …storage = _ux_utility_memory_allocate(UX_SAFE_ALIGN, UX_CACHE_SAFE_MEMORY, sizeof(UX_HOST_CLASS_S… in _ux_host_class_storage_activate() 101 if (storage == UX_NULL) in _ux_host_class_storage_activate() 105 storage -> ux_host_class_storage_class = command -> ux_host_class_command_class_ptr; in _ux_host_class_storage_activate() 108 storage -> ux_host_class_storage_interface = interface_ptr; in _ux_host_class_storage_activate() 111 …storage -> ux_host_class_storage_device = interface_ptr -> ux_interface_configuration -> ux_confi… in _ux_host_class_storage_activate() 114 …_ux_host_stack_class_instance_create(command -> ux_host_class_command_class_ptr, (VOID *) storage); in _ux_host_class_storage_activate() 117 interface_ptr -> ux_interface_class_instance = (VOID *) storage; in _ux_host_class_storage_activate() 122 status = _ux_host_class_storage_device_support_check(storage); in _ux_host_class_storage_activate() 125 _ux_utility_memory_free(storage); in _ux_host_class_storage_activate() [all …]
|
D | ux_host_class_storage_check_run.c | 87 UINT _ux_host_class_storage_check_run(UX_HOST_CLASS_STORAGE *storage) in _ux_host_class_storage_check_run() argument 96 if (storage -> ux_host_class_storage_state != UX_HOST_CLASS_INSTANCE_LIVE || in _ux_host_class_storage_check_run() 97 (storage -> ux_host_class_storage_flags & UX_HOST_CLASS_STORAGE_FLAG_LOCK) == 0 || in _ux_host_class_storage_check_run() 98 (storage -> ux_host_class_storage_op_state != UX_STATE_WAIT && in _ux_host_class_storage_check_run() 99 storage -> ux_host_class_storage_state_state != UX_STATE_IDLE)) in _ux_host_class_storage_check_run() 107 storage -> ux_host_class_storage_status = UX_TRANSFER_NOT_READY; in _ux_host_class_storage_check_run() 108 storage -> ux_host_class_storage_op_state = UX_STATE_RESET; in _ux_host_class_storage_check_run() 115 device = storage -> ux_host_class_storage_device; in _ux_host_class_storage_check_run() 117 switch(storage -> ux_host_class_storage_op_state) in _ux_host_class_storage_check_run() 124 storage -> ux_host_class_storage_flags |= in _ux_host_class_storage_check_run() [all …]
|
D | ux_host_class_storage_thread_entry.c | 108 UX_HOST_CLASS_STORAGE *storage; in _ux_host_class_storage_thread_entry() local 131 storage = (UX_HOST_CLASS_STORAGE *) class_inst -> ux_host_class_first_instance; in _ux_host_class_storage_thread_entry() 133 while (storage != UX_NULL) in _ux_host_class_storage_thread_entry() 137 if ((storage -> ux_host_class_storage_state == UX_HOST_CLASS_INSTANCE_LIVE)) in _ux_host_class_storage_thread_entry() 142 … status = _ux_host_semaphore_get(&storage -> ux_host_class_storage_semaphore, UX_WAIT_FOREVER); in _ux_host_class_storage_thread_entry() 147 … for (lun_index = 0; lun_index <= storage -> ux_host_class_storage_max_lun; lun_index++) in _ux_host_class_storage_thread_entry() 150 …if (storage -> ux_host_class_storage_lun_removable_media_flags[lun_index] != UX_HOST_CLASS_STORAGE… in _ux_host_class_storage_thread_entry() 154 …if ((storage -> ux_host_class_storage_lun_types[lun_index] == UX_HOST_CLASS_STORAGE_MEDIA_FAT_DISK… in _ux_host_class_storage_thread_entry() 155 …(storage -> ux_host_class_storage_lun_types[lun_index] == UX_HOST_CLASS_STORAGE_MEDIA_OPTICAL_DISK… in _ux_host_class_storage_thread_entry() 156 …(storage -> ux_host_class_storage_lun_types[lun_index] == UX_HOST_CLASS_STORAGE_MEDIA_IOMEGA_CLICK… in _ux_host_class_storage_thread_entry() [all …]
|
D | ux_host_class_storage_deactivate.c | 99 UX_HOST_CLASS_STORAGE *storage; in _ux_host_class_storage_deactivate() local 110 storage = (UX_HOST_CLASS_STORAGE *) command -> ux_host_class_command_instance; in _ux_host_class_storage_deactivate() 113 class_inst = storage -> ux_host_class_storage_class; in _ux_host_class_storage_deactivate() 119 storage -> ux_host_class_storage_state = UX_HOST_CLASS_INSTANCE_SHUTDOWN; in _ux_host_class_storage_deactivate() 129 if (storage -> ux_host_class_storage_bulk_out_endpoint != UX_NULL) in _ux_host_class_storage_deactivate() 130 _ux_host_stack_endpoint_transfer_abort(storage -> ux_host_class_storage_bulk_out_endpoint); in _ux_host_class_storage_deactivate() 133 if (storage -> ux_host_class_storage_bulk_in_endpoint != UX_NULL) in _ux_host_class_storage_deactivate() 134 _ux_host_stack_endpoint_transfer_abort(storage -> ux_host_class_storage_bulk_in_endpoint); in _ux_host_class_storage_deactivate() 138 …if (storage -> ux_host_class_storage_interface -> ux_interface_descriptor.bInterfaceProtocol == UX… in _ux_host_class_storage_deactivate() 142 if (storage -> ux_host_class_storage_interrupt_endpoint != UX_NULL) in _ux_host_class_storage_deactivate() [all …]
|
D | ux_host_class_storage_read_write_run.c | 34 extern VOID _ux_host_class_storage_read_initialize(UX_HOST_CLASS_STORAGE *storage, 37 extern VOID _ux_host_class_storage_write_initialize(UX_HOST_CLASS_STORAGE *storage, 101 UINT _ux_host_class_storage_read_write_run(UX_HOST_CLASS_STORAGE *storage, in _ux_host_class_storage_read_write_run() argument 113 if (storage -> ux_host_class_storage_state != UX_HOST_CLASS_INSTANCE_LIVE || in _ux_host_class_storage_read_write_run() 114 (storage -> ux_host_class_storage_flags & UX_HOST_CLASS_STORAGE_FLAG_LOCK) == 0 || in _ux_host_class_storage_read_write_run() 115 storage -> ux_host_class_storage_state_state != UX_STATE_IDLE) in _ux_host_class_storage_read_write_run() 123 storage -> ux_host_class_storage_status = UX_TRANSFER_NOT_READY; in _ux_host_class_storage_read_write_run() 124 storage -> ux_host_class_storage_op_state = UX_STATE_RESET; in _ux_host_class_storage_read_write_run() 131 …UX_TRACE_IN_LINE_INSERT(UX_TRACE_HOST_CLASS_STORAGE_MEDIA_READ, storage, sector_start, sector_coun… in _ux_host_class_storage_read_write_run() 134 device = storage -> ux_host_class_storage_device; in _ux_host_class_storage_read_write_run() [all …]
|
D | ux_host_class_storage_device_initialize.c | 95 UINT _ux_host_class_storage_device_initialize(UX_HOST_CLASS_STORAGE *storage) in _ux_host_class_storage_device_initialize() argument 108 status = _ux_host_class_storage_device_support_check(storage); in _ux_host_class_storage_device_initialize() 114 status = _ux_host_class_storage_max_lun_get(storage); in _ux_host_class_storage_device_initialize() 120 status = _ux_host_class_storage_endpoints_get(storage); in _ux_host_class_storage_device_initialize() 132 class_inst = storage -> ux_host_class_storage_class; in _ux_host_class_storage_device_initialize() 136 for (lun_index = 0; lun_index <= storage -> ux_host_class_storage_max_lun; lun_index++) in _ux_host_class_storage_device_initialize() 140 storage -> ux_host_class_storage_lun = lun_index; in _ux_host_class_storage_device_initialize() 143 status = _ux_host_class_storage_media_characteristics_get(storage); in _ux_host_class_storage_device_initialize() 152 …UX_TRACE_IN_LINE_INSERT(UX_TRACE_ERROR, UX_HOST_CLASS_MEDIA_NOT_SUPPORTED, storage, 0, 0, UX_TRACE… in _ux_host_class_storage_device_initialize() 160 status = _ux_host_class_storage_media_format_capacity_get(storage); in _ux_host_class_storage_device_initialize() [all …]
|
D | ux_host_class_storage_transport.c | 82 UINT _ux_host_class_storage_transport(UX_HOST_CLASS_STORAGE *storage, UCHAR *data_pointer) in _ux_host_class_storage_transport() argument 85 UX_PARAMETER_NOT_USED(storage); in _ux_host_class_storage_transport() 95 storage -> ux_host_class_storage_sense_code = UX_SUCCESS; in _ux_host_class_storage_transport() 98 status = storage -> ux_host_class_storage_transport(storage, data_pointer); in _ux_host_class_storage_transport() 103 …if (storage -> ux_host_class_storage_interface -> ux_interface_descriptor.bInterfaceProtocol != UX… in _ux_host_class_storage_transport() 114 csw_status = storage -> ux_host_class_storage_csw[UX_HOST_CLASS_STORAGE_CSW_STATUS]; in _ux_host_class_storage_transport() 120 status = _ux_host_class_storage_request_sense(storage); in _ux_host_class_storage_transport() 128 _ux_host_class_storage_device_reset(storage); in _ux_host_class_storage_transport() 149 _ux_host_stack_endpoint_reset(storage -> ux_host_class_storage_bulk_in_endpoint); in _ux_host_class_storage_transport() 152 _ux_host_stack_endpoint_reset(storage -> ux_host_class_storage_bulk_out_endpoint); in _ux_host_class_storage_transport() [all …]
|
D | ux_host_class_storage_request_sense.c | 83 UINT _ux_host_class_storage_request_sense(UX_HOST_CLASS_STORAGE *storage) in _ux_host_class_storage_request_sense() argument 95 …UX_TRACE_IN_LINE_INSERT(UX_TRACE_HOST_CLASS_STORAGE_REQUEST_SENSE, storage, 0, 0, 0, UX_TRACE_HOST… in _ux_host_class_storage_request_sense() 98 storage -> ux_host_class_storage_sense_code = 0; in _ux_host_class_storage_request_sense() 101 cbw = (UCHAR *) storage -> ux_host_class_storage_cbw; in _ux_host_class_storage_request_sense() 105 …if (storage -> ux_host_class_storage_interface -> ux_interface_descriptor.bInterfaceSubClass == UX… in _ux_host_class_storage_request_sense() 119 …_ux_utility_memory_copy(storage -> ux_host_class_storage_saved_cbw, storage -> ux_host_class_stora… in _ux_host_class_storage_request_sense() 122 …_ux_host_class_storage_cbw_initialize(storage, UX_HOST_CLASS_STORAGE_DATA_IN, UX_HOST_CLASS_STORAG… in _ux_host_class_storage_request_sense() 138 storage -> ux_host_class_storage_trans_data_bak = storage -> ux_host_class_storage_trans_data; in _ux_host_class_storage_request_sense() 139 storage -> ux_host_class_storage_trans_data = request_sense_response; in _ux_host_class_storage_request_sense() 142 storage -> ux_host_class_storage_trans_state = UX_HOST_CLASS_STORAGE_TRANS_CBW; in _ux_host_class_storage_request_sense() [all …]
|
D | ux_host_class_storage_media_characteristics_get.c | 81 UINT _ux_host_class_storage_media_characteristics_get(UX_HOST_CLASS_STORAGE *storage) in _ux_host_class_storage_media_characteristics_get() argument 90 cbw = (UCHAR *) storage -> ux_host_class_storage_cbw; in _ux_host_class_storage_media_characteristics_get() 94 …if (storage -> ux_host_class_storage_interface -> ux_interface_descriptor.bInterfaceSubClass == UX… in _ux_host_class_storage_media_characteristics_get() 103 …_ux_host_class_storage_cbw_initialize(storage, UX_HOST_CLASS_STORAGE_DATA_IN, UX_HOST_CLASS_STORAG… in _ux_host_class_storage_media_characteristics_get() 117 UX_HOST_CLASS_STORAGE_TRANS_STATE_RESET(storage); in _ux_host_class_storage_media_characteristics_get() 118 storage -> ux_host_class_storage_memory = inquiry_response; in _ux_host_class_storage_media_characteristics_get() 119 storage -> ux_host_class_storage_state_state = UX_HOST_CLASS_STORAGE_STATE_TRANSPORT; in _ux_host_class_storage_media_characteristics_get() 120 storage -> ux_host_class_storage_state_next = UX_HOST_CLASS_STORAGE_STATE_INQUIRY_SAVE; in _ux_host_class_storage_media_characteristics_get() 121 storage -> ux_host_class_storage_trans_data = inquiry_response; in _ux_host_class_storage_media_characteristics_get() 126 status = _ux_host_class_storage_transport(storage, inquiry_response); in _ux_host_class_storage_media_characteristics_get() [all …]
|
D | ux_host_class_storage_media_capacity_get.c | 84 UINT _ux_host_class_storage_media_capacity_get(UX_HOST_CLASS_STORAGE *storage) in _ux_host_class_storage_media_capacity_get() argument 96 …UX_TRACE_IN_LINE_INSERT(UX_TRACE_HOST_CLASS_STORAGE_MEDIA_CAPACITY_GET, storage, 0, 0, 0, UX_TRACE… in _ux_host_class_storage_media_capacity_get() 101 switch (storage -> ux_host_class_storage_media_type) in _ux_host_class_storage_media_capacity_get() 107 storage -> ux_host_class_storage_sector_size = UX_HOST_CLASS_STORAGE_SECTOR_SIZE_FAT; in _ux_host_class_storage_media_capacity_get() 113 storage -> ux_host_class_storage_sector_size = UX_HOST_CLASS_STORAGE_SECTOR_SIZE_OTHER; in _ux_host_class_storage_media_capacity_get() 128 status = _ux_host_class_storage_media_format_capacity_get(storage); in _ux_host_class_storage_media_capacity_get() 134 cbw = (UCHAR *) storage -> ux_host_class_storage_cbw; in _ux_host_class_storage_media_capacity_get() 138 …if (storage -> ux_host_class_storage_interface -> ux_interface_descriptor.bInterfaceSubClass == UX… in _ux_host_class_storage_media_capacity_get() 147 …_ux_host_class_storage_cbw_initialize(storage, UX_HOST_CLASS_STORAGE_DATA_IN, UX_HOST_CLASS_STORAG… in _ux_host_class_storage_media_capacity_get() 160 UX_HOST_CLASS_STORAGE_TRANS_STATE_RESET(storage); in _ux_host_class_storage_media_capacity_get() [all …]
|
D | ux_host_class_storage_driver_entry.c | 151 UX_HOST_CLASS_STORAGE *storage; in _ux_host_class_storage_driver_entry() local 158 storage = (UX_HOST_CLASS_STORAGE *) media -> fx_media_driver_info; in _ux_host_class_storage_driver_entry() 163 storage = storage_media -> ux_host_class_storage_media_storage; in _ux_host_class_storage_driver_entry() 168 if ((storage -> ux_host_class_storage_state != UX_HOST_CLASS_INSTANCE_LIVE) && in _ux_host_class_storage_driver_entry() 169 (storage -> ux_host_class_storage_state != UX_HOST_CLASS_INSTANCE_MOUNTING)) in _ux_host_class_storage_driver_entry() 180 if ((storage_media -> ux_host_class_storage_media_storage != storage) || in _ux_host_class_storage_driver_entry() 191 status = _ux_host_class_storage_lock(storage, UX_WAIT_FOREVER); in _ux_host_class_storage_driver_entry() 201 storage -> ux_host_class_storage_lun = storage_media -> ux_host_class_storage_media_lun; in _ux_host_class_storage_driver_entry() 204 storage -> ux_host_class_storage_sector_size = in _ux_host_class_storage_driver_entry() 210 storage -> ux_host_class_storage_last_sector_number = in _ux_host_class_storage_driver_entry() [all …]
|
D | ux_host_class_storage_max_lun_get.c | 78 UINT _ux_host_class_storage_max_lun_get(UX_HOST_CLASS_STORAGE *storage) in _ux_host_class_storage_max_lun_get() argument 89 storage -> ux_host_class_storage_max_lun = 0; in _ux_host_class_storage_max_lun_get() 93 …if (storage -> ux_host_class_storage_interface -> ux_interface_descriptor.bInterfaceProtocol == UX… in _ux_host_class_storage_max_lun_get() 98 control_endpoint = &storage -> ux_host_class_storage_device -> ux_device_control_endpoint; in _ux_host_class_storage_max_lun_get() 117 …transfer_request -> ux_transfer_request_index = storage -> ux_host_class_storage_inter… in _ux_host_class_storage_max_lun_get() 120 storage -> ux_host_class_storage_memory = storage_data_buffer; in _ux_host_class_storage_max_lun_get() 121 storage -> ux_host_class_storage_trans = transfer_request; in _ux_host_class_storage_max_lun_get() 122 storage -> ux_host_class_storage_state_state = UX_HOST_CLASS_STORAGE_STATE_TRANSFER; in _ux_host_class_storage_max_lun_get() 123 storage -> ux_host_class_storage_state_next = UX_HOST_CLASS_STORAGE_STATE_MAX_LUN_SAVE; in _ux_host_class_storage_max_lun_get() 135 storage -> ux_host_class_storage_max_lun = *storage_data_buffer; in _ux_host_class_storage_max_lun_get() [all …]
|