Physical Address
304 North Cardinal St.
Dorchester Center, MA 02124
Physical Address
304 North Cardinal St.
Dorchester Center, MA 02124
ISO/IEC 29341-8-12 specifies the QoS Packet Handling component of the UPnP QoS architecture, defining the low-level mechanisms by which network packets are processed, queued, scheduled, and transmitted according to QoS policies. While the QoS Traffic Classes standard defines what categories traffic belongs to, the Packet Handling standard defines how packets in each category are actually treated by network devices. This includes packet marking and remarking, queue selection and management, scheduling algorithms, congestion avoidance mechanisms, and traffic shaping and policing functions. The Packet Handling specification is the operational heart of the UPnP QoS framework.
The QoS Packet Handling specification defines several distinct mechanisms that operate in a coordinated pipeline. Packet classification and marking occurs first: packets entering the device are inspected against classification rules and marked with the appropriate DSCP (Layer 3) and 802.1p (Layer 2) values. Marked packets are then directed to the appropriate queue based on their traffic class. The queue management subsystem implements configurable queuing disciplines including strict priority (SP), weighted fair queuing (WFQ), class-based weighted fair queuing (CBWFQ), and low-latency queuing (LLQ). Each queue can be independently configured with depth limits, drop policies, and minimum/maximum bandwidth guarantees.
The specification introduces two congestion avoidance mechanisms: tail drop, the simplest method where packets are dropped when a queue reaches its maximum depth; and Random Early Detection (RED), which proactively drops packets before the queue becomes full to signal congestion to TCP senders. RED is particularly important for TCP traffic because it prevents global TCP synchronization — the phenomenon where all TCP flows simultaneously reduce their transmission rate when a queue overflows, causing throughput oscillations. The Packet Handling specification allows per-queue configuration of RED parameters including minimum threshold, maximum threshold, and drop probability.
| Handling Mechanism | Layer | Description | Configuration Parameters |
|---|---|---|---|
| DSCP Marking | L3 (IP) | Sets DiffServ Code Point in IP header | DSCP Value (0-63) |
| 802.1p Marking | L2 (Ethernet) | Sets Priority Code Point in VLAN tag | PCP Value (0-7) |
| Strict Priority | Queue | Highest priority queue transmits first | Queue ID, Priority Level |
| Weighted Fair Queuing | Queue | Weighted bandwidth distribution | Weight Value |
| Tail Drop | Drop | Drop packets when queue is full | Max Queue Depth |
| Random Early Detection | Drop | Probabilistic early drop to prevent TCP sync | Min/Max Threshold, Max Drop Probability |
| Traffic Shaping | Output | Smooths output traffic to a configured rate | CIR, CBS, EBS |
| Traffic Policing | Input | Drops or remarks packets exceeding rate limit | CIR, CBS, Excess Action |
Designing an effective packet handling configuration requires understanding the interaction between different mechanisms. A recommended engineering pattern is the hierarchical queuing structure: create a parent class for each traffic class group (real-time, streaming, data, background), assign bandwidth guarantees to each parent, and then configure per-flow queuing within each parent using WFQ. This approach ensures fairness across flows within the same class while maintaining class-level bandwidth guarantees. For real-time traffic (voice and video), use strict priority queuing with policed burst rates to prevent a single flow from monopolizing the priority queue.
An important design consideration is marking trust boundaries. The specification supports both trusted and untrusted port configurations. On trusted ports, incoming packet markings are accepted and preserved; on untrusted ports, markings are re-classified based on configured policies. This is critical at network edges where end-user devices connect — trusting all markings from client devices would allow malicious or misconfigured applications to claim inappropriate priority. The recommended practice is to configure access ports as untrusted and re-mark all traffic at the edge, then trust markings on infrastructure ports connecting switches, routers, and other managed devices.