diff options
author | Rafal Jaworowski <raj@FreeBSD.org> | 2009-02-17 15:47:13 +0000 |
---|---|---|
committer | Rafal Jaworowski <raj@FreeBSD.org> | 2009-02-17 15:47:13 +0000 |
commit | 0390701af8e50148141d5c908f0beacab3fa4a55 (patch) | |
tree | cb6b55ef036505af290c6c39aeae2c10beb71917 | |
parent | ab160495d3a13b0d45e1efe7cfc64a10c82b1665 (diff) | |
download | src-0390701af8e50148141d5c908f0beacab3fa4a55.tar.gz src-0390701af8e50148141d5c908f0beacab3fa4a55.zip |
tsec(4): do not clear interrupt events register before use.
Prior to this fix, IEVENT register was always cleared before calling
tsec_error_intr_locked(), which prevented error recovery actions from
happening with polling enabled (and could lead to serious problems, including
controller hang).
Submitted by: Marcin Ligenza marcinl ! pacomp dot com dot pl
Notes
Notes:
svn path=/head/; revision=188715
-rw-r--r-- | sys/dev/tsec/if_tsec.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/tsec/if_tsec.c b/sys/dev/tsec/if_tsec.c index d6d5eddc6c4b..f16a1d38565c 100644 --- a/sys/dev/tsec/if_tsec.c +++ b/sys/dev/tsec/if_tsec.c @@ -870,11 +870,11 @@ tsec_poll(struct ifnet *ifp, enum poll_cmd cmd, int count) } if (cmd == POLL_AND_CHECK_STATUS) { - ie = TSEC_READ(sc, TSEC_REG_IEVENT); + tsec_error_intr_locked(sc, count); /* Clear all events reported */ + ie = TSEC_READ(sc, TSEC_REG_IEVENT); TSEC_WRITE(sc, TSEC_REG_IEVENT, ie); - tsec_error_intr_locked(sc, count); } tsec_transmit_intr_locked(sc); |