diff options
author | Damien Bergamini <damien@cvs.openbsd.org> | 2009-11-01 12:08:37 +0000 |
---|---|---|
committer | Damien Bergamini <damien@cvs.openbsd.org> | 2009-11-01 12:08:37 +0000 |
commit | bf6fe86349b93e744812bf7fb31f4c14ff60da70 (patch) | |
tree | 9ff1723591a2a32abb8f56bfa1e5bcad13b338ac /sys/dev/pci | |
parent | d8f56a6f5b70c6d42d97990776d14e63a40ac397 (diff) |
call powerhook_disestablish() and pci_intr_disestablish() earlier.
diff from deraadt@
Diffstat (limited to 'sys/dev/pci')
-rw-r--r-- | sys/dev/pci/if_ral_pci.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/sys/dev/pci/if_ral_pci.c b/sys/dev/pci/if_ral_pci.c index 561e924697f..bef3a3ab987 100644 --- a/sys/dev/pci/if_ral_pci.c +++ b/sys/dev/pci/if_ral_pci.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_ral_pci.c,v 1.17 2009/05/12 17:43:16 damien Exp $ */ +/* $OpenBSD: if_ral_pci.c,v 1.18 2009/11/01 12:08:36 damien Exp $ */ /*- * Copyright (c) 2005-2007 @@ -201,12 +201,11 @@ ral_pci_detach(struct device *self, int flags) int error; if (psc->sc_ih != NULL) { + pci_intr_disestablish(psc->sc_pc, psc->sc_ih); + error = (*psc->sc_opns->detach)(sc); if (error != 0) return error; - - pci_intr_disestablish(psc->sc_pc, psc->sc_ih); - psc->sc_ih = NULL; } if (psc->sc_mapsize > 0) |