Ran Bi has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/36678 )
Change subject: libpayload: usbmsc: update return value of CSW transfer ......................................................................
libpayload: usbmsc: update return value of CSW transfer
When the first CSW transfer failed, get_csw function will retry CSW transfer again, but the return value is not updated.
Change-Id: I289916baa08d0a189d659164a0002347f6f435db Signed-off-by: Changqi Hu changqi.hu@mediatek.com --- M payloads/libpayload/drivers/usb/usbmsc.c 1 file changed, 2 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/78/36678/1
diff --git a/payloads/libpayload/drivers/usb/usbmsc.c b/payloads/libpayload/drivers/usb/usbmsc.c old mode 100644 new mode 100755 index 2412e99..d8b7bce --- a/payloads/libpayload/drivers/usb/usbmsc.c +++ b/payloads/libpayload/drivers/usb/usbmsc.c @@ -232,9 +232,9 @@
if (ret < 0) { clear_stall (ep); - if (ctrlr->bulk (ep, sizeof (csw_t), (u8 *) csw, 1) < 0) { + ret = ctrlr->bulk (ep, sizeof (csw_t), (u8 *) csw, 1); + if (ret < 0) return reset_transport (ep->dev); - } } if (ret != sizeof(csw_t) || csw->dCSWTag != tag || csw->dCSWSignature != csw_signature) {