diff options
author | Federico G. Schwindt <fgsch@cvs.openbsd.org> | 1999-08-23 21:54:41 +0000 |
---|---|---|
committer | Federico G. Schwindt <fgsch@cvs.openbsd.org> | 1999-08-23 21:54:41 +0000 |
commit | 2bdcb23c17abebb9539fb4890c8783933bdd3de2 (patch) | |
tree | 521800d7613abde76282256b491eb4dd438ee68f /sys | |
parent | c72d93062e3fb52c5dc983ea7077a473bbdf7d7a (diff) |
Disable interrupts early; from NetBSD.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/pci/ohci_pci.c | 6 | ||||
-rw-r--r-- | sys/dev/pci/uhci_pci.c | 5 |
2 files changed, 9 insertions, 2 deletions
diff --git a/sys/dev/pci/ohci_pci.c b/sys/dev/pci/ohci_pci.c index d339b1c8fc5..3efc32dc2b4 100644 --- a/sys/dev/pci/ohci_pci.c +++ b/sys/dev/pci/ohci_pci.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ohci_pci.c,v 1.3 1999/08/13 08:55:57 fgsch Exp $ */ +/* $OpenBSD: ohci_pci.c,v 1.4 1999/08/23 21:54:39 fgsch Exp $ */ /* $NetBSD: ohci_pci.c,v 1.9 1999/05/20 09:52:35 augustss Exp $ */ /* @@ -100,6 +100,10 @@ ohci_pci_attach(parent, self, aux) pcireg_t csr; usbd_status r; + /* Disable interrupts, so we don't can any spurious ones. */ + bus_space_write_4(sc->iot, sc->ioh, + OHCI_INTERRUPT_DISABLE, OHCI_ALL_INTRS); + /* Map I/O registers */ if (pci_mapreg_map(pa, PCI_CBMEM, PCI_MAPREG_TYPE_MEM, 0, &sc->iot, &sc->ioh, NULL, NULL)) { diff --git a/sys/dev/pci/uhci_pci.c b/sys/dev/pci/uhci_pci.c index a0a56788e76..3c69b8f5170 100644 --- a/sys/dev/pci/uhci_pci.c +++ b/sys/dev/pci/uhci_pci.c @@ -1,4 +1,4 @@ -/* $OpenBSD: uhci_pci.c,v 1.2 1999/08/13 08:09:26 fgsch Exp $ */ +/* $OpenBSD: uhci_pci.c,v 1.3 1999/08/23 21:54:40 fgsch Exp $ */ /* $NetBSD: uhci_pci.c,v 1.7 1999/05/20 09:52:35 augustss Exp $ */ /* @@ -94,6 +94,9 @@ uhci_pci_attach(parent, self, aux) char *typestr; usbd_status r; + /* Disable interrupts, so we don't can any spurious ones. */ + bus_space_write_2(sc->iot, sc->ioh, UHCI_INTR, 0); + /* Map I/O registers */ if (pci_mapreg_map(pa, PCI_CBIO, PCI_MAPREG_TYPE_IO, 0, &sc->iot, &sc->ioh, NULL, NULL)) { |