Page MenuHomeFreeBSD

if_epair: do not transmit packets that exceed the interface MTU
ClosedPublic

Authored by kp on Jun 2 2023, 7:29 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Sep 24, 4:07 AM
Unknown Object (File)
Mon, Sep 23, 6:34 PM
Unknown Object (File)
Wed, Sep 18, 2:46 PM
Unknown Object (File)
Tue, Sep 17, 9:15 PM
Unknown Object (File)
Tue, Sep 17, 10:56 AM
Unknown Object (File)
Wed, Sep 11, 4:53 PM
Unknown Object (File)
Sat, Sep 7, 8:05 AM
Unknown Object (File)
Wed, Sep 4, 11:53 PM

Details

Summary

While if_epair has no issues doing this we should drop those packets
anyway, because it improves the fidelity of the automated tests.

Sponsored by: Rubicon Communications, LLC ("Netgate")

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 51868
Build 48759: arc lint + arc unit

Event Timeline

kp requested review of this revision.Jun 2 2023, 7:29 PM

What is the default MTU for epair these days?

sys/net/if_epair.c
339

Probably wants more vertical space for that comment /*\n...\n*/ ?

In D40397#919783, @bz wrote:

What is the default MTU for epair these days?

We ether_ifattach(), which defaults to ETHERMTU, 1500.

if_epair doesn't need to care, of course, but the lack of this validation actually prevents the test in D40396 (fix for that problem is D40395) from failing when it should.
SIOCSIFMTU still works, and and will let users set whatever.

  • reformat comment block
This revision was not accepted when it landed; it landed in state Needs Review.Jun 6 2023, 8:53 AM
This revision was automatically updated to reflect the committed changes.