xblc: Ensure input packets are always padded

This commit is contained in:
Matt Borgerson
2026-02-18 23:23:37 -07:00
committed by mborgerson
parent 371c51cd2c
commit 6ff8dc23e3
+4 -4
View File
@@ -260,10 +260,6 @@ static void usb_xblc_handle_data(USBDevice *dev, USBPacket *p)
remaining -= chunk_len;
}
if (p->iov.size > p->actual_length) {
usb_packet_skip(p, p->iov.size - p->actual_length);
}
break;
}
case USB_TOKEN_OUT:
@@ -286,6 +282,10 @@ static void usb_xblc_handle_data(USBDevice *dev, USBPacket *p)
assert(!"Iso cannot report STALL/HALT");
break;
}
if (p->pid == USB_TOKEN_IN && p->iov.size > p->actual_length) {
usb_packet_skip(p, p->iov.size - p->actual_length);
}
}
static void xblc_audio_channel_init(USBXBLCState *s, bool capture, Error **errp)