summaryrefslogtreecommitdiffstats
path: root/sys/dev/sfxge/sfxge_tx.h
diff options
context:
space:
mode:
authorarybchik <arybchik@FreeBSD.org>2016-01-14 14:19:03 +0000
committerarybchik <arybchik@FreeBSD.org>2016-01-14 14:19:03 +0000
commitde3e51454b953e0c9a7d9f16eee80ea32bc27649 (patch)
tree44dbc260fec54614a0c0fc89852dc9b66f4fce1e /sys/dev/sfxge/sfxge_tx.h
parente76139f566ac2c0ce259cbcfc34d1f90db4d22a3 (diff)
downloadFreeBSD-src-de3e51454b953e0c9a7d9f16eee80ea32bc27649.zip
FreeBSD-src-de3e51454b953e0c9a7d9f16eee80ea32bc27649.tar.gz
MFC r291569
sfxge: avoid TSO packets collapses if packet header uses 2 segments It is really observed in the case of VLAN over sfxge interface. Also this change makes total value equal to 35 which is default assumed by the kernel for if_hw_tsomaxsegcount. Sponsored by: Solarflare Communications, Inc.
Diffstat (limited to 'sys/dev/sfxge/sfxge_tx.h')
-rw-r--r--sys/dev/sfxge/sfxge_tx.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/dev/sfxge/sfxge_tx.h b/sys/dev/sfxge/sfxge_tx.h
index d2f5b11..3872471 100644
--- a/sys/dev/sfxge/sfxge_tx.h
+++ b/sys/dev/sfxge/sfxge_tx.h
@@ -53,11 +53,13 @@
* TSO, the mbuf length may be just over 64K, divided into 2K mbuf
* clusters taking into account that the first may be not 2K cluster
* boundary aligned.
+ * Packet header may be split into two segments because of, for example,
+ * VLAN header insertion.
* The chain could be longer than this initially, but can be shortened
* with m_collapse().
*/
#define SFXGE_TX_MAPPING_MAX_SEG \
- (1 + howmany(SFXGE_TSO_MAX_SIZE, MCLBYTES) + 1)
+ (2 + howmany(SFXGE_TSO_MAX_SIZE, MCLBYTES) + 1)
/*
* Buffer mapping flags.
OpenPOWER on IntegriCloud