/haiku/src/add-ons/kernel/bus_managers/scsi/ |
H A D | ccb.cpp | 11 As allocation of ccb can be on the paging path we must use a 19 // ccb are relatively large, so don't make it too small to not waste memory 30 scsi_ccb *ccb; local 34 ccb = (scsi_ccb *)locked_pool->alloc(device->bus->ccb_pool); 35 ccb->state = SCSI_STATE_FINISHED; 36 ccb->device = device; 37 ccb->target_id = device->target_id; 38 ccb->target_lun = device->target_lun; 42 ccb->sg_list = NULL; 43 ccb 53 scsi_free_ccb(scsi_ccb *ccb) argument 69 scsi_ccb *ccb = (scsi_ccb *)block; local 87 scsi_ccb *ccb = (scsi_ccb *)block; local [all...] |
H A D | scatter_gather.cpp | 26 fill_temp_sg(scsi_ccb *ccb) argument 29 scsi_bus_info *bus = ccb->bus; 35 ccb->data, 36 ccb->data_length 40 physical_entry *temp_sg = (physical_entry *)ccb->sg_list; 42 res = get_iovec_memory_map(&vec, 1, 0, ccb->data_length, temp_sg, max_sg_blocks, 50 if (mapped_len != ccb->data_length) 53 if (dma_boundary != ~(uint32)0 || ccb->data_length > max_sg_block_size) { 89 ccb->sg_count = num_entries; 104 create_temp_sg(scsi_ccb *ccb) argument 151 cleanup_tmp_sg(scsi_ccb *ccb) argument [all...] |
H A D | scsi_internal.h | 112 locked_pool_cookie ccb_pool; // ccb pool (one per bus) 210 // state of ccb 236 // ccb.c 238 void scsi_free_ccb(scsi_ccb *ccb); 274 void scsi_done_io(scsi_ccb *ccb); 282 bool create_temp_sg(scsi_ccb *ccb); 283 void cleanup_tmp_sg(scsi_ccb *ccb);
|
/haiku/src/add-ons/kernel/generic/scsi_periph/ |
H A D | scsi_periph.cpp | 27 scsi_ccb* ccb = device->scsi->alloc_ccb(device->scsi_device); local 28 if (ccb == NULL) 31 ccb->flags = ccb_flags; 33 memcpy(ccb->cdb, cdb, cdbLength); 34 ccb->cdb_length = cdbLength; 36 ccb->sort = -1; 37 ccb->timeout = device->std_timeout; 39 ccb->data = (uint8*)data; 40 ccb->sg_list = NULL; 41 ccb [all...] |
H A D | scsi_periph_int.h | 70 void periph_media_changed(scsi_periph_device_info *device, scsi_ccb *ccb); 92 status_t periph_check_capacity(scsi_periph_device_info *device, scsi_ccb *ccb);
|
H A D | io.cpp | 49 vpd_page_inquiry(scsi_periph_device_info* device, scsi_ccb* ccb, argument 54 scsi_cmd_inquiry* cmd = (scsi_cmd_inquiry*)ccb->cdb; 57 cmd->lun = ccb->target_lun; 66 ccb->flags = SCSI_DIR_IN; 67 ccb->cdb_length = sizeof(scsi_cmd_inquiry); 68 ccb->sort = -1; 69 ccb->timeout = device->std_timeout; 71 ccb->data = (uint8*)data; 72 ccb->data_length = length; 73 ccb [all...] |
/haiku/src/add-ons/kernel/busses/scsi/virtio/ |
H A D | VirtioSCSIRequest.cpp | 76 VirtioSCSIRequest::Start(scsi_ccb *ccb) argument 82 fCCB = ccb; 88 TRACE("VirtioSCSIRequest::Start() opcode %x tid %x lun %x\n", ccb->cdb[0], 89 ccb->target_id, ccb->target_lun); 129 scsi_ccb *ccb = fCCB; local 133 gSCSI->resubmit(ccb); 135 gSCSI->finished(ccb, 1); 146 scsi_ccb *ccb = fCCB; local 149 ccb [all...] |
H A D | VirtioSCSIHelper.cpp | 16 /*! Copy data between ccb data and buffer 17 ccb - ccb to copy data from/to 18 offset - offset of data in ccb 19 allocation_length- limit of ccb's data buffer according to CDB 22 to_buffer - true: copy from ccb to buffer 23 false: copy from buffer to ccb 24 return: true, if data of ccb was large enough 27 copy_sg_data(scsi_ccb *ccb, uint offset, uint allocationLength, argument 30 const physical_entry *sgList = ccb [all...] |
H A D | VirtioSCSIController.cpp | 183 VirtioSCSIController::ExecuteRequest(scsi_ccb *ccb) argument 185 status_t result = fRequest->Start(ccb); 189 if (ccb->cdb[0] == SCSI_OP_REQUEST_SENSE && fRequest->HasSense()) { 196 if (ccb->target_id > fConfig.max_target) { 203 if (ccb->target_lun > fConfig.max_lun) { 210 if (ccb->cdb_length > VIRTIO_SCSI_CDB_SIZE) { 216 bool isOut = (ccb->flags & SCSI_DIR_MASK) == SCSI_DIR_OUT; 217 bool isIn = (ccb->flags & SCSI_DIR_MASK) == SCSI_DIR_IN; 221 fRequest->SetTimeout(ccb->timeout > 0 ? ccb [all...] |
H A D | VirtioSCSIPrivate.h | 30 bool copy_sg_data(scsi_ccb *ccb, uint offset, uint allocationLength, 130 status_t Start(scsi_ccb *ccb);
|
/haiku/src/add-ons/kernel/bus_managers/ata/ |
H A D | ATAHelper.cpp | 15 /*! Copy data between ccb data and buffer 16 ccb - ccb to copy data from/to 17 offset - offset of data in ccb 18 allocation_length- limit of ccb's data buffer according to CDB 21 to_buffer - true: copy from ccb to buffer 22 false: copy from buffer to ccb 23 return: true, if data of ccb was large enough 26 copy_sg_data(scsi_ccb *ccb, uint offset, uint allocationLength, argument 29 const physical_entry *sgList = ccb [all...] |
H A D | ATADevice.cpp | 110 scsi_ccb *ccb = request->CCB(); local 111 scsi_cmd_inquiry *command = (scsi_cmd_inquiry *)ccb->cdb; 160 copy_sg_data(ccb, 0, allocationLength, &data, sizeof(data), false); 161 ccb->data_resid = ccb->data_length - MIN(MIN(sizeof(data), 162 allocationLength), ccb->data_length); 172 scsi_ccb *ccb = request->CCB(); local 173 scsi_cmd_read_capacity *command = (scsi_cmd_read_capacity *)ccb->cdb; 192 copy_sg_data(ccb, 0, ccb 203 scsi_ccb *ccb = request->CCB(); local 236 scsi_ccb *ccb = request->CCB(); local [all...] |
H A D | ATAPIDevice.cpp | 190 scsi_ccb *ccb = request->CCB(); local 191 if (ccb->target_lun != 0) { 192 TRACE_ERROR("invalid target lun %d\n", ccb->target_lun); 200 memcpy(fPacket, ccb->cdb, ccb->cdb_length); 203 request->SetIsWrite((ccb->flags & SCSI_DIR_MASK) == SCSI_DIR_OUT); 233 scsi_ccb *ccb = request->CCB(); local 237 fTaskFile.packet.byte_count_0_7 = ccb->data_length & 0xff; 238 fTaskFile.packet.byte_count_8_15 = ccb->data_length >> 8;
|
H A D | ATAModule.cpp | 65 ata_sim_scsi_io(scsi_sim_cookie cookie, scsi_ccb *ccb) argument 69 ccb->subsys_status = SCSI_NO_HBA; 70 gSCSIModule->finished(ccb, 1); 74 if (channel->ExecuteIO(ccb) == B_BUSY) 75 gSCSIModule->requeue(ccb, true); 80 ata_sim_abort(scsi_sim_cookie cookie, scsi_ccb *ccb) argument 104 ata_sim_term_io(scsi_sim_cookie cookie, scsi_ccb *ccb) argument
|
H A D | ATARequest.cpp | 92 ATARequest::Start(scsi_ccb *ccb) argument 97 fCCB = ccb;
|
H A D | ATAChannel.cpp | 294 ATAChannel::ExecuteIO(scsi_ccb *ccb) argument 296 TRACE_FUNCTION("%p\n", ccb); 297 status_t result = fRequest->Start(ccb); 301 if (ccb->cdb[0] == SCSI_OP_REQUEST_SENSE && fRequest->HasSense()) { 311 if (ccb->target_id >= fDeviceCount) { 318 ATADevice *device = fDevices[ccb->target_id]; 326 fRequest->SetTimeout(ccb->timeout > 0 ? ccb->timeout * 1000 * 1000 735 scsi_ccb *ccb = request->CCB(); local 736 return fController->prepare_dma(fCookie, ccb [all...] |
H A D | ATAPrivate.h | 58 bool copy_sg_data(scsi_ccb *ccb, uint offset, uint allocationLength, 79 status_t ExecuteIO(scsi_ccb *ccb); 297 status_t Start(scsi_ccb *ccb);
|
/haiku/src/add-ons/kernel/busses/scsi/buslogic/ |
H A D | buslogic.c | 385 CCB_SCSIIO *ccb; local 396 ccb = (CCB_SCSIIO *) ccbh; 403 cdb_len = ccb->cam_cdb_len; 405 ccb->cam_ch.cam_status = CAM_REQ_INVALID; 422 get_memory_map((void *)ccb->cam_sim_priv, 4096, entries, 2); 425 priv = (BL_PRIV *) ccb->cam_sim_priv; 428 if(ccb->cam_ch.cam_flags & CAM_CDB_POINTER) { 429 memcpy(bl_ccb->cdb, ccb->cam_cdb_io.cam_cdb_ptr, cdb_len); 431 memcpy(bl_ccb->cdb, ccb->cam_cdb_io.cam_cdb_bytes, cdb_len); 434 /* fill out the ccb heade 631 CCB_PATHINQ *ccb; local 657 CCB_EXTENDED_PATHINQ *ccb; local [all...] |
/haiku/src/add-ons/kernel/busses/scsi/53c8xx/ |
H A D | 53c8xx.c | 840 CCB_SCSIIO *ccb = (CCB_SCSIIO *) ccbh; local 846 targ = s->targ + ccb->cam_ch.cam_target_id; 853 if(ccb->cam_ch.cam_flags & CAM_CDB_POINTER) { 854 cdb = ccb->cam_cdb_io.cam_cdb_ptr; 856 cdb = ccb->cam_cdb_io.cam_cdb_bytes; 859 get_memory_map((void*) (ccb->cam_sim_priv), 1536, pe, 2); 862 msg[0] = 0xC0 | (ccb->cam_ch.cam_target_lun & 0x07); 865 prep_io((SymPriv *) ccb->cam_sim_priv, (uint32) pe[0].address); 870 targ->priv = (SymPriv *) ccb->cam_sim_priv;; 873 targ->inbound = (ccb 947 CCB_PATHINQ *ccb; local 971 CCB_EXTENDED_PATHINQ *ccb; local [all...] |
/haiku/headers/os/drivers/bus/ |
H A D | SCSI.h | 306 void (*free_ccb)(scsi_ccb *ccb); 309 // when it's finished, the semaphore of the ccb is released 311 void (*async_io)(scsi_ccb *ccb); 314 void (*sync_io)(scsi_ccb *ccb); 372 void (*requeue)(scsi_ccb *ccb, bool bus_overflow); 375 void (*resubmit)(scsi_ccb *ccb); 382 void (*finished)(scsi_ccb *ccb, uint num_requests); 432 void (*scsi_io)(scsi_sim_cookie cookie, scsi_ccb *ccb);
|
/haiku/src/add-ons/kernel/drivers/disk/scsi/scsi_cd/ |
H A D | scsi_cd.cpp | 77 scsi_ccb *ccb = info->scsi->alloc_ccb(info->scsi_device); local 78 if (ccb == NULL) 82 info->scsi_periph_device, ccb); 84 info->scsi->free_ccb(ccb); 235 scsi_ccb *ccb; local 243 ccb = info->scsi->alloc_ccb(info->scsi_device); 244 if (ccb == NULL) 248 ccb->flags = SCSI_DIR_IN; 250 cmd = (scsi_cmd_read_toc *)ccb->cdb; 259 ccb 300 scsi_ccb *ccb = info->scsi->alloc_ccb(info->scsi_device); local 606 scsi_ccb *ccb; local [all...] |
/haiku/src/add-ons/kernel/drivers/disk/scsi/scsi_disk/ |
H A D | scsi_disk.cpp | 79 scsi_ccb *ccb = device->scsi->alloc_ccb(device->scsi_device); local 80 if (ccb == NULL) 84 device->scsi_periph_device, ccb); 86 device->scsi->free_ccb(ccb); 131 scsi_ccb *ccb = device->scsi->alloc_ccb(device->scsi_device); local 132 if (ccb == NULL) 136 device->scsi_periph_device, ccb, load, true); 138 device->scsi->free_ccb(ccb); 149 scsi_ccb *ccb = device->scsi->alloc_ccb(device->scsi_device); local 150 if (ccb [all...] |
/haiku/src/add-ons/kernel/busses/scsi/usb/ |
H A D | tracing.h | 29 void usb_scsi_trace_CCB_HEADER(const CCB_HEADER *ccb);
|
/haiku/src/add-ons/kernel/busses/scsi/ahci/ |
H A D | sata_request.h | 16 sata_request(scsi_ccb* ccb);
|
H A D | sata_request.cpp | 28 sata_request::sata_request(scsi_ccb* ccb) argument 30 fCcb(ccb),
|