summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorStefan Fritsch <sf@cvs.openbsd.org>2014-12-06 10:09:11 +0000
committerStefan Fritsch <sf@cvs.openbsd.org>2014-12-06 10:09:11 +0000
commitd4149d2673ac03cd2400466fe3fb3fc52d708566 (patch)
tree66b7359b2320edba59d96481b3039f224cae545f /sys
parentadd0dfe7edbd309b87a694469390e4425cb0334c (diff)
Increase low rxr watermark to a value suitable for jumbo frames.
Patch provided by brad@
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/pci/if_vio.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/dev/pci/if_vio.c b/sys/dev/pci/if_vio.c
index 1bc448ce7f8..f48e7eedc7a 100644
--- a/sys/dev/pci/if_vio.c
+++ b/sys/dev/pci/if_vio.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_vio.c,v 1.19 2014/11/29 22:53:58 brad Exp $ */
+/* $OpenBSD: if_vio.c,v 1.20 2014/12/06 10:09:10 sf Exp $ */
/*
* Copyright (c) 2012 Stefan Fritsch, Alexander Fiveg.
@@ -667,7 +667,8 @@ vio_init(struct ifnet *ifp)
struct vio_softc *sc = ifp->if_softc;
vio_stop(ifp, 0);
- if_rxr_init(&sc->sc_rx_ring, 4, sc->sc_vq[VQRX].vq_num);
+ if_rxr_init(&sc->sc_rx_ring, 2 * ((ifp->if_hardmtu / MCLBYTES) + 1),
+ sc->sc_vq[VQRX].vq_num);
vio_populate_rx_mbufs(sc);
ifp->if_flags |= IFF_RUNNING;
ifp->if_flags &= ~IFF_OACTIVE;