Re: problems with e1000 and jumboframes

From: Chris Leech
Date: Fri Aug 04 2006 - 11:14:40 EST


On 8/3/06, Evgeniy Polyakov <johnpol@xxxxxxxxxxx> wrote:
> You're changing the size of the buffer without telling the hardware.
> In the interrupt context e1000 knows the size of what was DMAed into
> the skb, but that's after the fact. So e1000 could detect that memory
> was corrupted, but not prevent it if you don't give it power of 2
> buffers. Actually, the power of 2 thing doesn't hold true for all
> e1000 devices. Some have 1k granularity, but not Arnd's 82540.

I can not change it - code checks if requested mtu and additional size
is less than allocated aligned buffer it tricks allocator.
Or do you mean that even after 9k mtu was setup it is possible that card
can receive packets up to 16k?

Yes, that's exactly what I mean. For anything above the standard 1500
bytes the e1000 _hardware_ has no concept of MTU, only buffer length.
So even if the driver is set to an MTU of 9000, the NIC will still
receive 16k frames. Otherwise the driver would simply allocate MTU
sized buffers.

-Chris
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/