Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 01 May 2015 22:22:03 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-net@FreeBSD.org
Subject:   [Bug 199174] em tx and rx hang
Message-ID:  <bug-199174-2472-551Tf5O5j8@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-199174-2472@https.bugs.freebsd.org/bugzilla/>
References:  <bug-199174-2472@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=199174

--- Comment #10 from david.keller@litchis.fr ---
Intel device Errata 17
(http://www.intel.fr/content/dam/www/public/us/en/documents/specification-updates/82574-gbe-controller-spec-update.pdf)
says:

> When using TSO, a situation can occur where a PCIe MRd request is repeated with 
> the same address, resulting in data corruption. At the end of the TCP packet, 
> the Tx DMA hangs because the length doesn't match. This can only occur when 
> the following are true:
> * The first buffer of the packet is larger than [3 * (max_read_request - 4)].
> * There is a 4 KB boundary within 64 bytes following the end of the header bytes in
>   the buffer

On my device, PCIe max_read_request is 512. Hence first buffer has to be <=
1524.
Interface mtu is 9000.

Hence it seems to me that the first buffer can be greater than the 1524 if the 
FreeBSD stack doesn't split header into a dedicated mbuf

The dma alignement requirement is not met on bus_dma_tag_create() where
alignement 
argument is 1.
(https://svnweb.freebsd.org/base/head/sys/dev/e1000/if_em.c?view=markup#l3260).

Maybe bus_dma_tag_create() should use an alignement of 128 bytes as explained
in 
errata:

> The alignment of the buffer containing the headers should be such that there is no 
> 4 KB boundary within 64 bytes following the end of the header bytes. Assuming 
> standard > Ethernet/IP/TCP headers of 54 bytes, this means that the buffer should 
> not start 54-118 bytes before a 4 KB boundary. For example, 128-byte alignment 
> for this buffer could be used to fulfill this condition

-- 
You are receiving this mail because:
You are the assignee for the bug.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-199174-2472-551Tf5O5j8>