diff options
author | adrian <adrian@FreeBSD.org> | 2011-10-18 03:24:17 +0000 |
---|---|---|
committer | adrian <adrian@FreeBSD.org> | 2011-10-18 03:24:17 +0000 |
commit | e6dc2dfa1d7d11868787f5f0c8b98189ade9123c (patch) | |
tree | 89e9f27c1559ba71c0d1c7363dc8601cc3473128 /sys/dev/ath | |
parent | 09fc5efa9dc63787685cebd3e6e7dfd9dafa7ac1 (diff) | |
download | FreeBSD-src-e6dc2dfa1d7d11868787f5f0c8b98189ade9123c.zip FreeBSD-src-e6dc2dfa1d7d11868787f5f0c8b98189ade9123c.tar.gz |
Add a WAR from the reference code - clear the PCI error status
upon detach.
Obtained from: Atheros
Diffstat (limited to 'sys/dev/ath')
-rw-r--r-- | sys/dev/ath/if_ath_pci.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/dev/ath/if_ath_pci.c b/sys/dev/ath/if_ath_pci.c index fa3cf3b..531c79a 100644 --- a/sys/dev/ath/if_ath_pci.c +++ b/sys/dev/ath/if_ath_pci.c @@ -199,6 +199,11 @@ ath_pci_detach(device_t dev) /* check if device was removed */ sc->sc_invalid = !bus_child_present(dev); + /* + * Do a config read to clear pre-existing pci error status. + */ + (void) pci_read_config(dev, PCIR_COMMAND, 4); + ath_detach(sc); bus_generic_detach(dev); |