Skip to main content

IEEE 802.1Qci PSFP: per-stream filtering and policing at ingress

· 5 min read
PhD candidate, LyRIDS (ECE) × CEDRIC (Cnam)

Every bound in this series assumes that each talker respects its arrival curve. Per-Stream Filtering and Policing (PSFP) is the TSN mechanism that makes that assumption hold. It checks each stream where it enters a bridge and stops a faulty or malicious talker before it can harm the streams that behave.

The IEEE 802.1Q bridge: architecture and data-plane actionsIEEE 802.1Q bridge ↗Control planeSRP (Qat), TSN configuration (Qcc), path control (Qca)frame inframe outIngressPSFP (Qci)FRER (CB)Relayforwardingexplicit treesQueuingCBS (Qav)ATS (Qcr)Tx selectiongates (Qbv)CQF (Qch)MAC / PHYpreemption(Qbu, 802.3br)Common time: gPTP (802.1AS)
Figure 1. Where PSFP acts: at the ingress port, before the relay and the queues. A frame that violates its stream's contract is dropped before it consumes any shared resource.Source: own drawing, after the bridge architecture, data-plane actions and QoS function chain in J. Farkas, TSN Basic Concepts, DetNet–TSN workshop, 11 November 2018, slides 7, 8 and 10.
Abbreviations used in this post (16)
AbbreviationStands forMeaning
ATSAsynchronous Traffic ShapingIEEE 802.1Qcr: per-stream token-bucket shaping at every hop using local clocks only.
CBSCredit-Based ShaperThe IEEE 802.1Qav shaper that limits a traffic class to its reserved rate (idleSlope) with a per-queue credit. In MEF bandwidth profiles, CBS instead means Committed Burst Size.
CIRCommitted Information RateThe guaranteed long-term rate of a MEF bandwidth profile, used by PSFP flow meters.
DEIDrop Eligible IndicatorThe 1-bit field of the 802.1Q tag marking frames that may be dropped first under congestion.
EBSExcess Burst SizeThe burst allowance that goes with the excess information rate in a MEF bandwidth profile.
EIRExcess Information RateThe additional rate of a MEF bandwidth profile that is carried only when resources allow.
IEEEInstitute of Electrical and Electronics EngineersThe professional association whose Standards Association publishes the IEEE 802 LAN/MAN standards.
IPInternet ProtocolThe network-layer protocol of the Internet (IPv4, RFC 791; IPv6, RFC 8200).
IPVInternal Priority ValueA priority assigned inside a bridge (for example by a PSFP stream gate) that selects the traffic class, independently of the frame’s PCP.
MACMedium Access ControlThe lower sublayer of the data link layer, which frames data and controls access to the medium. A MAC address identifies a network interface.
MEFMetro Ethernet Forum (now MEF Forum)An industry forum that defines carrier Ethernet services and their bandwidth profiles, such as MEF 10.3.
PCPPriority Code PointThe 3-bit priority field of the 802.1Q tag (priorities 0 to 7).
PSFPPer-Stream Filtering and PolicingIEEE 802.1Qci: stream filters, stream gates and flow meters that enforce each stream’s contract at ingress.
TSNTime-Sensitive NetworkingThe set of IEEE 802.1 standards that give Ethernet bounded latency, time synchronisation and high reliability.
VIDVLAN IdentifierThe 12-bit field of the 802.1Q tag that names a frame’s VLAN.
VLANVirtual LANA logical LAN within a bridged network, identified by a 12-bit VLAN ID in the 802.1Q tag.

1. Definition​

Per-Stream Filtering and Policing, IEEE 802.1Qci (now part of IEEE 802.1Q), applies decisions per stream at the ingress. Its purpose is protection against bandwidth violation, malfunction and attack [3]. A frame passes three elements in order, after the stream it belongs to has been identified [3][4]:

  1. a stream filter;
  2. a stream gate;
  3. a flow meter.

2. Identifying the stream​

An Ethernet frame before and after the insertion of the four-byte 802.1Q header holding the TPID and the PCP, DEI and VID fields
Figure 2. An Ethernet frame before and after insertion of the 802.1Q header. The header carries the priority code point (PCP), the drop eligible indicator (DEI) and the VLAN ID (VID). Together with the MAC addresses, these are the fields from which a bridge recognises a stream.Source: Ethernet 802.1Q Insert.svg by Bill Stafford, from the Wikipedia article “IEEE 802.1Q”, Wikimedia Commons, CC BY-SA 3.0.

Ethernet has no stream-ID field. A bridge recognises a stream by matching header fields that were agreed when the stream was set up. The stream identification functions defined with 802.1CB include [2]:

  • destination MAC address and VLAN ID;
  • source MAC address and VLAN ID;
  • IP addresses, protocol and ports, for streams carried over IP.

The match yields a stream handle, an internal number that the following tables use. The reservation protocols identify a stream by a talker MAC address plus a 16-bit number. In the data plane, the frames are matched on destination MAC, VLAN ID and priority [5].

3. Filter, gate and meter​

PSFP chain: filter, time gate with internal priority, meter, then queuing
Figure 3. PSFP on the original slide: an incoming frame passes the filter, the time gate (which also sets the internal priority) and the meter before queuing.Source: J. Farkas, “TSN Basic Concepts,” DetNet–TSN workshop, IEEE 802.1, 11 November 2018, slide 13; cropped, with neighbouring slide text, logos or navigation icons blanked.
ElementSelected byDecides
Stream filterStream handle and priority (either may be a wildcard)Which gate and meter apply. Also enforces a maximum frame size: an oversized frame is dropped and can block the stream.
Stream gateThe filterWhether the frame may pass now. The gate opens and closes on a gate control list, like the transmission gates of 802.1Qbv, and can set the frame's internal priority value (IPV).
Flow meterThe filterWhether the stream is within its bandwidth profile. The meter uses the two-rate, two-bucket profile of MEF 10.3: committed rate and burst (CIR, CBS) and excess rate and burst (EIR, EBS). Frames are marked green, yellow or red; red frames are dropped, and yellow frames can be dropped or demoted.

4. What PSFP does for the analysis​

It enforces the arrival curve. The committed rate and burst of the meter form a token bucket, so traffic leaving the meter conforms to the arrival curve γr,b(t)=b+rt\gamma_{r,b}(t) = b + r t of the arrival curves post. Without policing, that curve is a promise. With policing, it is a property of the network.

It contains faults. A "babbling idiot" talker that floods the network loses its excess frames at the first bridge. Streams that share later queues with it keep their bounds.

It is a building block. The stream gate's ability to set the internal priority on a timetable is exactly what Cyclic Queuing and Forwarding uses to alternate between two queues. The stream filter and gate are also reused in front of the ATS shaper, which delays frames instead of metering them.

5. Summary​

PropertyPer-Stream Filtering and Policing
StandardIEEE 802.1Qci, now in IEEE 802.1Q
Acts onThe ingress port, per stream
ElementsStream filter, stream gate, flow meter
Needs time synchronisationOnly for time-based stream gates
Metering modelMEF 10.3 bandwidth profile (CIR, CBS, EIR, EBS)
Role in the analysisMakes the declared arrival curve an enforced one

References​

  1. IEEE 802.1, Time-Sensitive Networking (TSN) Task Group. Web page
  2. Wikipedia, "Time-Sensitive Networking," sections on stream identification and per-stream filtering and policing; "IEEE 802.1Q." TSN, 802.1Q
  3. J. Farkas, "TSN Basic Concepts," DetNet–TSN workshop, 11 November 2018, slide 13. Slides
  4. J. Farkas, "Introduction to IEEE 802.1: Focus on the Time-Sensitive Networking Task Group," 15 May 2017. Slides
  5. A. Grigorjew, S. Geissler, J. Schmitt, T. Hossfeld, "Decentralized Latency Models and Information Flow for TSN Shapers – A Tutorial," arXiv:2610.11999, 2026, Sections V-B and VI-C. arXiv