mirror of
https://github.com/FEX-Emu/linux.git
synced 2024-12-28 20:37:27 +00:00
uas: Add some data in/out ready iu sanity checks
Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
This commit is contained in:
parent
876285cc9c
commit
8e453155d7
@ -379,9 +379,19 @@ static void uas_stat_cmplt(struct urb *urb)
|
||||
uas_try_complete(cmnd, __func__);
|
||||
break;
|
||||
case IU_ID_READ_READY:
|
||||
if (!cmdinfo->data_in_urb ||
|
||||
(cmdinfo->state & DATA_IN_URB_INFLIGHT)) {
|
||||
scmd_printk(KERN_ERR, cmnd, "unexpected read rdy\n");
|
||||
break;
|
||||
}
|
||||
uas_xfer_data(urb, cmnd, SUBMIT_DATA_IN_URB);
|
||||
break;
|
||||
case IU_ID_WRITE_READY:
|
||||
if (!cmdinfo->data_out_urb ||
|
||||
(cmdinfo->state & DATA_OUT_URB_INFLIGHT)) {
|
||||
scmd_printk(KERN_ERR, cmnd, "unexpected write rdy\n");
|
||||
break;
|
||||
}
|
||||
uas_xfer_data(urb, cmnd, SUBMIT_DATA_OUT_URB);
|
||||
break;
|
||||
default:
|
||||
|
Loading…
Reference in New Issue
Block a user