Socket option to configure Ethernet PCP / CoS per-flow

Scheffenegger, Richard Richard.Scheffenegger at
Fri Oct 9 12:17:21 UTC 2020

Hi Ryan,

D26409 was committed in r366569. The socket option is now "living" under the IP_PROTO or IPV6_PROTO (depending on the AF_FAMILY used by the socket), and stored with the INPCB for more efficient processing.

Would be grateful if anyone could look at D26627, which adds a "-C <pcp>" option to ping, to validate the functionality (host + network).

That patch for ping also shows a simple example as to how to use this new functionality (basically, perform a setsockopt between a bind/connect or bind/listen of the socket, similar to other such setsockopt calls). 

Best regards,

Richard Scheffenegger

-----Original Message-----
From: Ryan Stone <rysto32 at> 
Sent: Donnerstag, 24. September 2020 23:31
To: Scheffenegger, Richard <Richard.Scheffenegger at>
Cc: net at; transport at
Subject: Re: Socket option to configure Ethernet PCP / CoS per-flow

Hi Richard,

At $WORK we're running into situations where PFC support would be very useful, so I think that this would be a good thing to add.  I have a
question: does your work also communicate the priority value for an mbuf down to the Ethernet driver, so that it can put the packet in the proper queue?

More information about the freebsd-transport mailing list