Download raw body.
ixl(4): Fix hardmtu
On Fri, Aug 21, 2026 at 06:53:53PM +0200, Jan Klemkow wrote:
> On Thu, Jul 30, 2026 at 06:16:40PM +0200, Jan Klemkow wrote:
> > Using ixl(4) with it's hardmtu is broken, because packets with hardmtu
> > were dropped cause they are bigger then rxmax is configured.
> >
> > The Intel Ethernet Controller X710/XXV710/XL710 Datasheet said:
> >
> > Table 1-3. Link layer Ethernet port features
> >
> > Maximum Transmit Unit Size (MTU) is 9728 - Ethernet header/CRC =
> > 9728 - 18 = 9710 bytes (jumbo frames)
> > MTU can be further reduced by additional header fields such as
> > Virtual Local Area Network (VLAN) tag(s), etc.
> >
> > Table 8-12. LAN Rx Queue Context in the Private Host Memory
> >
> > The "rxmax" parameter defines the whole packet size starting at
> > the L2 header up to including the Ethernet CRC.
> >
> > The following diff sending and receiving sizes in the ixl(4) code. The
> > result is a working hardmtu of 9706 and its also working with vlan(4).
Adjust the rxmax part as the spec said:
The RXMAX must not be set to a larger value than 5 x DBUFF
(since receive packet must never span on more than 5 buffers).
ok?
bye,
jan
Index: dev/pci/if_ixl.c
===================================================================
RCS file: /cvs/src/sys/dev/pci/if_ixl.c,v
diff -u -p -r1.117 if_ixl.c
--- dev/pci/if_ixl.c 23 Jun 2026 14:40:40 -0000 1.117
+++ dev/pci/if_ixl.c 22 Sep 2026 02:54:00 -0000
@@ -901,7 +901,8 @@ struct ixl_rx_wb_desc_32 {
#define IXL_TX_QUEUE_ALIGN 128
#define IXL_RX_QUEUE_ALIGN 128
-#define IXL_HARDMTU 9712 /* 9726 - ETHER_HDR_LEN */
+#define IXL_HARDMTU (9728 - ETHER_HDR_LEN - EVL_ENCAPLEN \
+ - ETHER_CRC_LEN)
#define IXL_TSO_SIZE ((255 * 1024) - 1)
#define IXL_MAX_DMA_SEG_SIZE ((16 * 1024) - 1)
@@ -3171,7 +3172,7 @@ ixl_rxr_config(struct ixl_softc *sc, str
rxq.crcstrip = 1;
rxq.l2tsel = IXL_HMC_RXQ_L2TSEL_1ST_TAG_TO_L2TAG1;
rxq.showiv = 0;
- rxq.rxmax = htole16(IXL_HARDMTU);
+ rxq.rxmax = htole16(MCLBYTES * 5);
rxq.tphrdesc_ena = 0;
rxq.tphwdesc_ena = 0;
rxq.tphdata_ena = 0;
ixl(4): Fix hardmtu