提交 b5f7a0ec 编写于 作者: M Misha Zhilin 提交者: Greg Kroah-Hartman

USB: ehci: handle large bulk URBs correctly (again)

USB: ehci: Fixes completion for multi-qtd URB the short read case

When use of urb->status in the EHCI driver was reworked last August
(commit 14c04c0f), a bug was inserted
in the handling of early completion for bulk transactions that need
more than one qTD (e.g. more than 20KB in one URB).

This patch resolves that problem by ensuring that the early completion
status is preserved until the URB is handed back to its submitter,
instead of resetting it after each qTD.
Signed-off-by: NMisha Zhilin <misha@epiphan.com>
Signed-off-by: NDavid Brownell <dbrownell@users.sourceforge.net>
Acked-by: NAlan Stern <stern@rowland.harvard.edu>
Cc: stable@kernel.org
Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
上级 14f3546f
......@@ -319,10 +319,10 @@ qh_completions (struct ehci_hcd *ehci, struct ehci_qh *qh)
if (likely (last->urb != urb)) {
ehci_urb_done(ehci, last->urb, last_status);
count++;
last_status = -EINPROGRESS;
}
ehci_qtd_free (ehci, last);
last = NULL;
last_status = -EINPROGRESS;
}
/* ignore urbs submitted during completions we reported */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册