mirror of
https://gitlab.com/qemu-project/qemu
synced 2024-11-05 20:35:44 +00:00
usb-storage: use scsi_req_enqueue return value
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
This commit is contained in:
parent
07d17e7720
commit
9db7c41419
1 changed files with 3 additions and 2 deletions
|
@ -400,6 +400,7 @@ static void usb_msd_handle_data(USBDevice *dev, USBPacket *p)
|
|||
struct usb_msd_cbw cbw;
|
||||
uint8_t devep = p->ep->nr;
|
||||
SCSIDevice *scsi_dev;
|
||||
uint32_t len;
|
||||
|
||||
switch (p->pid) {
|
||||
case USB_TOKEN_OUT:
|
||||
|
@ -441,8 +442,8 @@ static void usb_msd_handle_data(USBDevice *dev, USBPacket *p)
|
|||
#ifdef DEBUG_MSD
|
||||
scsi_req_print(s->req);
|
||||
#endif
|
||||
scsi_req_enqueue(s->req);
|
||||
if (s->req && s->req->cmd.xfer != SCSI_XFER_NONE) {
|
||||
len = scsi_req_enqueue(s->req);
|
||||
if (len) {
|
||||
scsi_req_continue(s->req);
|
||||
}
|
||||
break;
|
||||
|
|
Loading…
Reference in a new issue