Page MenuHomeFreeBSD

if_vlan: add the ALTQ support to if_vlan.
ClosedPublic

Authored by kp on Aug 23 2021, 3:52 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Dec 28, 1:36 AM
Unknown Object (File)
Fri, Dec 27, 11:06 AM
Unknown Object (File)
Mon, Dec 9, 3:00 AM
Unknown Object (File)
Dec 2 2024, 12:56 PM
Unknown Object (File)
Nov 29 2024, 3:13 PM
Unknown Object (File)
Nov 28 2024, 10:02 PM
Unknown Object (File)
Nov 22 2024, 5:54 PM
Unknown Object (File)
Oct 29 2024, 2:06 AM

Details

Summary

Inspired by the iflib implementation, allow ALTQ to be used with if_vlan
interfaces.

Obtained from: pfsense
MFC after: 1 week
Sponsored by: Rubicon Communications, LLC ("Netgate")

Diff Detail

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

Event Timeline

kp requested review of this revision.Aug 23 2021, 3:52 PM
donner added inline comments.
sys/net/if_vlan.c
1290

May I ask for an one line description for each of the functions?

1322

Is this the same functionality as vlan_altq_start()?

sys/net/if_vlan.c
1290

These are the standard 'if_start()' functions, common to a lot of network drivers. To the extent that it's documented in the ifnet(9) man page.

In essence there are two ways of telling a driver to transmit a packet, if_start(), where the packet is taken from the driver's ifq and the newer if_transmit() where the packet is handed directly to the function.

ALTQ uses the driver's ifq during packet scheduling, so it only works when drivers implement if_start().

1322

I'm assuming this was meant to point at vlan_altq_transmit().

In that case: "Yes, sort of.". I believe this is an optimisation. In case ALTQ is not enabled we fall back to vlan_transmit(), and don't queue up the packet at all.

This revision is now accepted and ready to land.Aug 24 2021, 8:22 AM
This revision was automatically updated to reflect the committed changes.