summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authormlelstv <mlelstv@NetBSD.org>2017-08-12 11:03:47 +0000
committermlelstv <mlelstv@NetBSD.org>2017-08-12 11:03:47 +0000
commitca717b6088f78084a84bb9f09ffcbc4b4eb6d5c2 (patch)
tree4e602e5543a95f7136ce252264194e837e5c431b /sys
parent0f005d20de927ef320a62cc1409d1edc920a8345 (diff)
tag arcmsr scsipi adapter and pci interrupt as MPSAFE. I/O is now done
without taking kernel lock.
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/pci/arcmsr.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/dev/pci/arcmsr.c b/sys/dev/pci/arcmsr.c
index 387efe46d2c..d4217d0770d 100644
--- a/sys/dev/pci/arcmsr.c
+++ b/sys/dev/pci/arcmsr.c
@@ -1,4 +1,4 @@
-/* $NetBSD: arcmsr.c,v 1.36 2016/06/19 21:12:44 dholland Exp $ */
+/* $NetBSD: arcmsr.c,v 1.37 2017/08/12 11:03:47 mlelstv Exp $ */
/* $OpenBSD: arc.c,v 1.68 2007/10/27 03:28:27 dlg Exp $ */
/*
@@ -21,7 +21,7 @@
#include "bio.h"
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: arcmsr.c,v 1.36 2016/06/19 21:12:44 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: arcmsr.c,v 1.37 2017/08/12 11:03:47 mlelstv Exp $");
#include <sys/param.h>
#include <sys/buf.h>
@@ -241,6 +241,7 @@ arc_attach(device_t parent, device_t self, void *aux)
adapt->adapt_max_periph = adapt->adapt_openings;
adapt->adapt_minphys = arc_minphys;
adapt->adapt_request = arc_scsi_cmd;
+ adapt->adapt_flags = SCSIPI_ADAPT_MPSAFE;
memset(chan, 0, sizeof(*chan));
chan->chan_adapter = adapt;
@@ -625,6 +626,8 @@ arc_map_pci_resources(device_t self, struct pci_attach_args *pa)
goto unmap;
}
+ pci_intr_setattr(pa->pa_pc, &ih, PCI_INTR_MPSAFE, true);
+
sc->sc_ih = pci_intr_establish(pa->pa_pc, ih, IPL_BIO,
arc_intr, sc);
if (sc->sc_ih == NULL) {