summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbrad <brad@openbsd.org>2006-08-18 06:02:45 +0000
committerbrad <brad@openbsd.org>2006-08-18 06:02:45 +0000
commita5cb6543617509667e50546a12afa3366e3005f9 (patch)
tree6fd4ea67532d4ce9a8c583b63f904c02551de67d
parentregen (diff)
downloadwireguard-openbsd-a5cb6543617509667e50546a12afa3366e3005f9.tar.xz
wireguard-openbsd-a5cb6543617509667e50546a12afa3366e3005f9.zip
check hw.max_frame_size when deciding when to use m_adj().
-rw-r--r--sys/dev/pci/if_ixgb.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/pci/if_ixgb.c b/sys/dev/pci/if_ixgb.c
index b6666e97e75..914354633ad 100644
--- a/sys/dev/pci/if_ixgb.c
+++ b/sys/dev/pci/if_ixgb.c
@@ -31,7 +31,7 @@ POSSIBILITY OF SUCH DAMAGE.
***************************************************************************/
-/* $OpenBSD: if_ixgb.c,v 1.28 2006/08/14 02:22:13 brad Exp $ */
+/* $OpenBSD: if_ixgb.c,v 1.29 2006/08/18 06:02:45 brad Exp $ */
#include <dev/pci/if_ixgb.h>
@@ -1438,9 +1438,9 @@ ixgb_get_buf(int i, struct ixgb_softc *sc,
mp->m_next = NULL;
}
- if (ifp->if_mtu <= ETHERMTU) {
+ if (sc->hw.max_frame_size <= (MCLBYTES - ETHER_ALIGN))
m_adj(mp, ETHER_ALIGN);
- }
+
rx_buffer = &sc->rx_buffer_area[i];
/*