Home
last modified time | relevance | path

Searched refs:io_hdr (Results 1 – 7 of 7) sorted by relevance

/openbmc/qemu/scsi/
H A Dpr-manager-helper.c152 int fd, struct sg_io_hdr *io_hdr) in pr_manager_helper_run() argument
163 if (!io_hdr->cmd_len || io_hdr->cmd_len > PR_HELPER_CDB_SIZE) { in pr_manager_helper_run()
167 memcpy(cdb, io_hdr->cmdp, io_hdr->cmd_len); in pr_manager_helper_run()
171 if (io_hdr->dxfer_direction != expected_dir) { in pr_manager_helper_run()
176 if (io_hdr->dxfer_len < len || len > PR_HELPER_DATA_SIZE) { in pr_manager_helper_run()
208 io_hdr->resid = io_hdr->dxfer_len - len; in pr_manager_helper_run()
209 ret = pr_manager_helper_write(pr_mgr, -1, io_hdr->dxferp, len, NULL); in pr_manager_helper_run()
221 if (io_hdr->dxfer_direction == SG_DXFER_FROM_DEV) { in pr_manager_helper_run()
222 assert(resp.sz <= io_hdr->dxfer_len); in pr_manager_helper_run()
223 ret = pr_manager_helper_read(pr_mgr, io_hdr->dxferp, resp.sz, NULL); in pr_manager_helper_run()
[all …]
H A Dqemu-pr-helper.c137 struct sg_io_hdr io_hdr; in do_sgio_worker() local
143 memset(&io_hdr, 0, sizeof(io_hdr)); in do_sgio_worker()
144 io_hdr.interface_id = 'S'; in do_sgio_worker()
145 io_hdr.cmd_len = PR_HELPER_CDB_SIZE; in do_sgio_worker()
146 io_hdr.cmdp = (uint8_t *)data->cdb; in do_sgio_worker()
147 io_hdr.sbp = data->sense; in do_sgio_worker()
148 io_hdr.mx_sb_len = PR_HELPER_SENSE_SIZE; in do_sgio_worker()
149 io_hdr.timeout = 1; in do_sgio_worker()
150 io_hdr.dxfer_direction = data->dir; in do_sgio_worker()
151 io_hdr.dxferp = (char *)data->buf; in do_sgio_worker()
[all …]
/openbmc/openbmc/meta-openembedded/meta-oe/recipes-support/eject/eject/
H A Deject-timeout.patch10 io_hdr.dxfer_len = 0;
11 io_hdr.dxferp = inqBuff;
12 io_hdr.sbp = sense_buffer;
13 - io_hdr.timeout = 2000;
14 + io_hdr.timeout = 10000;
16 io_hdr.cmdp = allowRmBlk;
17 status = ioctl(fd, SG_IO, (void *)&io_hdr);
/openbmc/ipmitool/src/plugins/usb/
H A Dusb.c178 sg_io_hdr_t io_hdr; in sendscsicmd_SGIO() local
181 memset(&io_hdr, 0, sizeof(sg_io_hdr_t)); in sendscsicmd_SGIO()
182 io_hdr.interface_id = 'S'; in sendscsicmd_SGIO()
183 io_hdr.cmd_len = cdb_len; in sendscsicmd_SGIO()
186 io_hdr.dxfer_direction = direction; in sendscsicmd_SGIO()
187 io_hdr.dxfer_len = *data_len; in sendscsicmd_SGIO()
189 io_hdr.dxferp = data_buf; in sendscsicmd_SGIO()
191 io_hdr.cmdp = cdb_buf; in sendscsicmd_SGIO()
193 io_hdr.sbp = (unsigned char *)sense_buf; in sendscsicmd_SGIO()
194 io_hdr.mx_sb_len = slen; in sendscsicmd_SGIO()
[all …]
/openbmc/qemu/hw/scsi/
H A Dscsi-generic.c78 sg_io_hdr_t *io_hdr = &r->io_header; in scsi_command_complete_noio() local
91 } else if (io_hdr->host_status != SCSI_HOST_OK) { in scsi_command_complete_noio()
92 scsi_req_complete_failed(&r->req, io_hdr->host_status); in scsi_command_complete_noio()
94 } else if (io_hdr->driver_status & SG_ERR_DRIVER_TIMEOUT) { in scsi_command_complete_noio()
97 status = io_hdr->status; in scsi_command_complete_noio()
98 if (io_hdr->driver_status & SG_ERR_DRIVER_SENSE) { in scsi_command_complete_noio()
99 r->req.sense_len = io_hdr->sb_len_wr; in scsi_command_complete_noio()
H A Dscsi-disk.c2854 sg_io_hdr_t *io_hdr = &req->io_header; in scsi_block_sgio_complete() local
2858 if (io_hdr->host_status != SCSI_HOST_OK) { in scsi_block_sgio_complete()
2859 scsi_req_complete_failed(&r->req, io_hdr->host_status); in scsi_block_sgio_complete()
2864 if (io_hdr->driver_status & SG_ERR_DRIVER_TIMEOUT) { in scsi_block_sgio_complete()
2867 ret = io_hdr->status; in scsi_block_sgio_complete()
/openbmc/qemu/block/
H A Dfile-posix.c4198 struct sg_io_hdr *io_hdr = buf; in hdev_co_ioctl() local
4199 if (io_hdr->cmdp[0] == PERSISTENT_RESERVE_OUT || in hdev_co_ioctl()
4200 io_hdr->cmdp[0] == PERSISTENT_RESERVE_IN) { in hdev_co_ioctl()
4202 s->fd, io_hdr); in hdev_co_ioctl()