Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/pci ehci(4): Mark PCI interrupt handler MP-safe.



details:   https://anonhg.NetBSD.org/src/rev/9680e7908678
branches:  trunk
changeset: 372147:9680e7908678
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Fri Oct 28 21:56:44 2022 +0000

description:
ehci(4): Mark PCI interrupt handler MP-safe.

ehci_intr has its own intr lock to coordinate with the MP-safe
softint it defers all its work to, other than reading and writing a
few registers to get and acknowledge the interrupt status.

diffstat:

 sys/dev/pci/ehci_pci.c |  5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diffs (26 lines):

diff -r f46ea0681704 -r 9680e7908678 sys/dev/pci/ehci_pci.c
--- a/sys/dev/pci/ehci_pci.c    Fri Oct 28 21:53:26 2022 +0000
+++ b/sys/dev/pci/ehci_pci.c    Fri Oct 28 21:56:44 2022 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ehci_pci.c,v 1.74 2022/03/13 11:29:21 riastradh Exp $  */
+/*     $NetBSD: ehci_pci.c,v 1.75 2022/10/28 21:56:44 riastradh Exp $  */
 
 /*
  * Copyright (c) 2001, 2002 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ehci_pci.c,v 1.74 2022/03/13 11:29:21 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ehci_pci.c,v 1.75 2022/10/28 21:56:44 riastradh Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -196,6 +196,7 @@
         * Allocate IRQ
         */
        intrstr = pci_intr_string(pc, sc->sc_pihp[0], intrbuf, sizeof(intrbuf));
+       pci_intr_setattr(pa->pa_pc, &sc->sc_pihp[0], PCI_INTR_MPSAFE, true);
        sc->sc_ih = pci_intr_establish_xname(pc, sc->sc_pihp[0], IPL_USB,
            ehci_intr, sc, device_xname(self));
        if (sc->sc_ih == NULL) {



Home | Main Index | Thread Index | Old Index