diff options
| author | cinap_lenrek <cinap_lenrek@felloff.net> | 2020-05-24 02:12:47 +0200 |
|---|---|---|
| committer | cinap_lenrek <cinap_lenrek@felloff.net> | 2020-05-24 02:12:47 +0200 |
| commit | 9b28790494ff317b438c7d32a3b0736ac73a1ec9 (patch) | |
| tree | adde077b5eaf970d50dbcdd21b73b112cfa25fb4 | |
| parent | e06f8e061a54a663f12e41b30271c157a92c159e (diff) | |
| parent | 3869d7a8437e2a9902529cd68915dddcb43e6782 (diff) | |
| download | plan9front-9b28790494ff317b438c7d32a3b0736ac73a1ec9.tar.xz | |
merge
| -rw-r--r-- | sys/src/9/port/usbehci.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/sys/src/9/port/usbehci.c b/sys/src/9/port/usbehci.c index 470e1f2a6..5ac7486cf 100644 --- a/sys/src/9/port/usbehci.c +++ b/sys/src/9/port/usbehci.c @@ -2278,12 +2278,15 @@ pollcheck(Hci *hp) if(poll->must != 0 && poll->does == 0){ lock(poll); - if(poll->must != 0 && poll->does == 0){ - poll->does++; - print("ehci %#p: polling\n", ctlr->capio); - kproc("ehcipoll", ehcipoll, hp); + if(poll->must == 0 || poll->does != 0) { + unlock(poll); + return; } + poll->does++; unlock(poll); + + print("ehci %#p: polling\n", ctlr->capio); + kproc("ehcipoll", ehcipoll, hp); } } |
