Page MenuHomeFreeBSD

iflib: Take iri_pad into account when processing small frames
ClosedPublic

Authored by kd on Apr 27 2021, 10:49 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Jun 14, 5:26 PM
Unknown Object (File)
May 7 2026, 12:17 PM
Unknown Object (File)
Apr 29 2026, 8:47 AM
Unknown Object (File)
Apr 29 2026, 5:54 AM
Unknown Object (File)
Apr 27 2026, 2:13 AM
Unknown Object (File)
Apr 21 2026, 8:41 PM
Unknown Object (File)
Apr 20 2026, 2:01 AM
Unknown Object (File)
Apr 19 2026, 9:06 AM
Subscribers

Details

Summary

Drivers can specify padding of received frames with iri_pad field.
This can be used to enforce ip alignment by hardware.
Iflib ignores that padding when processing small frames, which renders this feature inoperable.
I found it while writing a driver for a NIC that can ip align received packets.
Note that this doesn't change behavior of existing drivers as they all set iri_pad to 0.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable