summaryrefslogtreecommitdiffstats
path: root/sys/pci
diff options
context:
space:
mode:
authordg <dg@FreeBSD.org>2000-09-17 23:04:57 +0000
committerdg <dg@FreeBSD.org>2000-09-17 23:04:57 +0000
commit46ce32e1701eefe9ae98604ab04ce1163d582c48 (patch)
tree1a07412001c50fc55097e5caa60b5f3367cc42cd /sys/pci
parent683279a04abb06c11a171a02971933030c5a88fc (diff)
downloadFreeBSD-src-46ce32e1701eefe9ae98604ab04ce1163d582c48.zip
FreeBSD-src-46ce32e1701eefe9ae98604ab04ce1163d582c48.tar.gz
As a minor optimization, do suspended checking more like it was originally
in the PR - before the while loop.
Diffstat (limited to 'sys/pci')
-rw-r--r--sys/pci/if_fxp.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/sys/pci/if_fxp.c b/sys/pci/if_fxp.c
index 08dd15c..f10e58c 100644
--- a/sys/pci/if_fxp.c
+++ b/sys/pci/if_fxp.c
@@ -1218,7 +1218,12 @@ fxp_intr(arg)
FXP_LOCK(sc, s);
- while (!sc->suspended && (statack = CSR_READ_1(sc, FXP_CSR_SCB_STATACK)) != 0) {
+ if (sc->suspended) {
+ FXP_UNLOCK(sc, s);
+ return;
+ }
+
+ while ((statack = CSR_READ_1(sc, FXP_CSR_SCB_STATACK)) != 0) {
#if defined(__NetBSD__)
claimed = 1;
#endif
OpenPOWER on IntegriCloud