From 24582ab39b8353f4acae89f2a377f3f8eca60977 Mon Sep 17 00:00:00 2001 From: Vladimir 'phcoder' Serbinenko Date: Fri, 20 Aug 2010 16:56:03 +0200 Subject: [PATCH] Correct *actual counting in OHCI --- bus/usb/ohci.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/bus/usb/ohci.c b/bus/usb/ohci.c index aa96ed5e6..39e47ffee 100644 --- a/bus/usb/ohci.c +++ b/bus/usb/ohci.c @@ -989,6 +989,7 @@ grub_ohci_transfer (grub_usb_controller_t dev, transfer->last_trans = tderr_virt->tr_index; else transfer->last_trans = -1; + *actual = transfer->size; } else if (err_halt) /* error, ED is halted by OHCI, i.e. can be modified */ @@ -1178,8 +1179,6 @@ grub_ohci_transfer (grub_usb_controller_t dev, else transfer->last_trans = -1; } - else - *actual = transfer->size; /* Set empty ED - set HEAD = TAIL = last (not processed) TD */ ed_virt->td_head = grub_cpu_to_le32 (grub_le_to_cpu32 (ed_virt->td_tail) & ~0xf);