ref: a1c6530959a71ead8cd26a15dfed1fd88514f610
parent: 419bd67364f93b5bba5eee0aaa7e30efdddf9146
author: cinap_lenrek <cinap_lenrek@felloff.net>
date: Wed Feb 7 13:13:22 EST 2018
usbxhci: fix mistake in completering() the td index "x" was incremented twice, once in for loop and in the body expression. so r->rp only got updated every second completion. this is wrong, but harmless.
--- a/sys/src/9/pc/usbxhci.c
+++ b/sys/src/9/pc/usbxhci.c
@@ -800,7 +800,7 @@
pa = (*(u64int*)er) & ~15ULL;
ilock(r);
- for(x = r->rp; (int)(r->wp - x) > 0; x++){+ for(x = r->rp; (int)(r->wp - x) > 0;){td = &r->base[4*(x++ & r->mask)];
if((u64int)PADDR(td) == pa){r->rp = x;
--
⑨