summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Pieuchot <mpi@cvs.openbsd.org>2015-11-02 14:53:11 +0000
committerMartin Pieuchot <mpi@cvs.openbsd.org>2015-11-02 14:53:11 +0000
commit80611f284849af2117598935c6576d43f8f6b16a (patch)
tree22f2d255fca12f8d35c449b097c352b77b5fcb6b
parent558f551e2568ad735b56d81059dd27c1c811e2df (diff)
Mark xhci_intr() as IPL_MPSAFE since it only schedules a soft-interrupt.
ok visa@
-rw-r--r--sys/dev/pci/xhci_pci.c4
-rw-r--r--sys/dev/usb/xhci.c6
2 files changed, 3 insertions, 7 deletions
diff --git a/sys/dev/pci/xhci_pci.c b/sys/dev/pci/xhci_pci.c
index fd1e21d5bad..d08ccbaa618 100644
--- a/sys/dev/pci/xhci_pci.c
+++ b/sys/dev/pci/xhci_pci.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: xhci_pci.c,v 1.6 2015/06/22 08:43:27 mpi Exp $ */
+/* $OpenBSD: xhci_pci.c,v 1.7 2015/11/02 14:53:10 mpi Exp $ */
/*
* Copyright (c) 2001, 2002 The NetBSD Foundation, Inc.
@@ -164,7 +164,7 @@ xhci_pci_attach(struct device *parent, struct device *self, void *aux)
}
intrstr = pci_intr_string(pa->pa_pc, ih);
- psc->sc_ih = pci_intr_establish(pa->pa_pc, ih, IPL_USB,
+ psc->sc_ih = pci_intr_establish(pa->pa_pc, ih, IPL_USB | IPL_MPSAFE,
xhci_intr, psc, psc->sc.sc_bus.bdev.dv_xname);
if (psc->sc_ih == NULL) {
printf(": couldn't establish interrupt");
diff --git a/sys/dev/usb/xhci.c b/sys/dev/usb/xhci.c
index a1e97951f28..a48d83140ae 100644
--- a/sys/dev/usb/xhci.c
+++ b/sys/dev/usb/xhci.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: xhci.c,v 1.63 2015/07/12 12:54:31 mpi Exp $ */
+/* $OpenBSD: xhci.c,v 1.64 2015/11/02 14:53:10 mpi Exp $ */
/*
* Copyright (c) 2014-2015 Martin Pieuchot
@@ -606,13 +606,11 @@ xhci_intr1(struct xhci_softc *sc)
if ((intrs & XHCI_STS_EINT) == 0)
return (0);
- sc->sc_bus.intr_context++;
sc->sc_bus.no_intrs++;
if (intrs & XHCI_STS_HSE) {
printf("%s: host system error\n", DEVNAME(sc));
sc->sc_bus.dying = 1;
- sc->sc_bus.intr_context--;
return (1);
}
@@ -623,8 +621,6 @@ xhci_intr1(struct xhci_softc *sc)
intrs = XRREAD4(sc, XHCI_IMAN(0));
XRWRITE4(sc, XHCI_IMAN(0), intrs | XHCI_IMAN_INTR_PEND);
- sc->sc_bus.intr_context--;
-
return (1);
}