summaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
authormartin <martin@NetBSD.org>2020-03-01 12:47:10 +0000
committermartin <martin@NetBSD.org>2020-03-01 12:47:10 +0000
commiteb84de8e63d602f3a2f8d8a0e62804586bf6fa53 (patch)
treef938f2986ca266bb1a67b9ae866722682d28723b /sys/dev
parent319a3a9f8299cdee96a3126fe8ad5a8d61a56b30 (diff)
Pull up following revision(s) (requested by thorpej in ticket #747):
sys/dev/pci/if_mcx.c: revision 1.11 Use the 64-bit PCI DMA tag if available. Otherwise, we are needlessly allocating (and using) bounce buffers on sytems with >4GB of RAM. XXX pullup-9
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/pci/if_mcx.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/dev/pci/if_mcx.c b/sys/dev/pci/if_mcx.c
index 5b0b697bd00..9082b46d5a5 100644
--- a/sys/dev/pci/if_mcx.c
+++ b/sys/dev/pci/if_mcx.c
@@ -1,4 +1,4 @@
-/* $NetBSD: if_mcx.c,v 1.1.2.8 2020/01/31 11:14:50 martin Exp $ */
+/* $NetBSD: if_mcx.c,v 1.1.2.9 2020/03/01 12:47:10 martin Exp $ */
/* $OpenBSD: if_mcx.c,v 1.33 2019/09/12 04:23:59 jmatthew Exp $ */
/*
@@ -2215,7 +2215,10 @@ mcx_attach(device_t parent, device_t self, void *aux)
sc->sc_dev = self;
sc->sc_pc = pa->pa_pc;
sc->sc_tag = pa->pa_tag;
- sc->sc_dmat = pa->pa_dmat;
+ if (pci_dma64_available(pa))
+ sc->sc_dmat = pa->pa_dmat64;
+ else
+ sc->sc_dmat = pa->pa_dmat;
/* Map the PCI memory space */
memtype = pci_mapreg_type(sc->sc_pc, sc->sc_tag, MCX_HCA_BAR);