You are on page 1of 40

Technical Note

ONU Data Path Config.


Confidential

Table of Contents

1
2
3
4

Table of Contents................................................................................................................................... 1
Overview ............................................................................................................................................... 2
Basic Hardware Architecture................................................................................................................. 2
ONU Queue Configuration.................................................................................................................... 3
4.1
Set ONU Queue Configuration Host Interface Message ............................................................. 4
4.2
Example: Default ONU Configuration........................................................................................ 6
5
Downstream Broadcast Traffic .............................................................................................................. 6
6
Traffic Filtering and Classification........................................................................................................ 8
6.1
Rules Defined .............................................................................................................................. 9
6.2
The Rule Search Process ........................................................................................................... 10
6.3
Use of Precedence to Create Unambiguous Rule Sets .............................................................. 11
6.4
System Rules and Precedence ................................................................................................... 12
6.5
Viewing Default Rules via the ONU CLI.................................................................................. 13
6.6
Rule Tables................................................................................................................................ 14
6.7
Lookup Engine Field Definition................................................................................................ 15
6.7.1
Layer Select Values .............................................................................................................. 16
6.7.2
Preamble/Layer 2 Header ..................................................................................................... 16
6.7.3
Layer 2 Type field ................................................................................................................ 18
6.7.4
Layer 2 VLAN tag............................................................................................................. 20
6.7.5
Layer 3 IPv4 ...................................................................................................................... 20
6.7.6
Layer 4 XXX/IPv4............................................................................................................. 21
6.7.7
Layer 3 IPv6 ...................................................................................................................... 21
7
Field Code Examples........................................................................................................................... 21
7.1
Viewing and Editing Field Code Values via the ONU CLI....................................................... 23
8
Tips for Designing Rules ..................................................................................................................... 24
8.1
Default Rules............................................................................................................................. 24
8.2
Conditions Involving Logical OR ............................................................................................. 25
8.3
Special Considerations when Working with TK3711 Rules ..................................................... 26
8.3.1
Example 1: Logical AND ..................................................................................................... 26
8.3.2
Example 2: Logical OR ........................................................................................................ 27
8.4
Identical Downstream Flows..................................................................................................... 27
8.5
One FIFO Fed by Multiple UNI Ports....................................................................................... 27
8.6
Two downstream FIFOs receiving frames from the same link.................................................. 28
9
Teknovus FIFO Labeling Convention Review .................................................................................... 28
9.1
Upstream ................................................................................................................................... 28
9.2
Downstream .............................................................................................................................. 29
10 Example Configurations ...................................................................................................................... 29
10.1
Teknovus Default ...................................................................................................................... 29
10.1.1 Sample Classification Scheme.............................................................................................. 30
10.2
One UNI, Two Links................................................................................................................. 30
10.2.1 Sample Classification Scheme.............................................................................................. 31
10.3
One UNI, One Link, Four FIFOs .............................................................................................. 32
10.3.1 Sample Classification Scheme.............................................................................................. 32
10.4
Two FIFOs per UNI .................................................................................................................. 33
10.4.1 Sample Classification Scheme.............................................................................................. 33
10.5
One UNI, Two Links, Two FIFOs per Link.............................................................................. 34
10.5.1 Sample Classification Scheme.............................................................................................. 34
10.6
Asymmetrical Configuration ..................................................................................................... 35
10.6.1 Sample Classification Scheme.............................................................................................. 35
11 IGMP Snooping Parameters ................................................................................................................ 36
1

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

11.1
L3-to-L2 Binding used by Snooping Function (as per RFC 1112) ........................................... 36
11.2
IP Multicast Addresses Always Forwarded............................................................................... 37
12 Q and A................................................................................................................................................ 38

Overview

The Teknovus EPON System allows for host interface configuration of ONU traffic filtering, traffic
classification, and queue configuration. These commands allow the host interface to configure an ONU for
new services in the field. Both TK3701 and TK3711 provide similar functionality with different resources
available. This technical note describes the resources available to control the user data flow and the
method for configuring different system solutions.
Classification is the process of deciding which frames are forwarded to particular queues and passed
through the ONU. Filtering is the process of deciding which frames should be dropped, and not passed
through the ONU. An ONU has a queue configuration, which describes the number and sizes of queues in
use, as well as their connectivity to user ports and EPON logical links. An ONU also has a classification
scheme, which is a set of rules describing how traffic is forwarded to priority queues in either direction, and
possibly a set of filtering rules to control access to the PON.

Basic Hardware Architecture

Each link is served by an


INDEPENDENT, STRICT
priority scheduler. When a
grant is received by the ONU,
ONLY those FIFOs
associated with the granted
link may transmit. FIFOs
within a link operate in
STRICT priority. All EPON
FIFOs operate at the LINE
RATE of the PON.

Two FIFOs are used by the


processor for IGMP
snooping. If snooping is
disabled these FIFOs may be
allocated by the Host
software for user data.

Port 1
CPU

Port 2

System
User 0

EPON 0

UNI 1

User 1
Link 0

Hi

Link 1

System
User 0

UNI 2

User 1
Each link is scheduled
independently by the OLT.

A Host provisioned
classification scheme is used
to differentiate services
based on one or more fields
in the frame.

TK3711

Low

Each logical link is assigned


a system FIFO for control
frames such as OAM. In
contrast to the TK3701,
which has only a single
shared system FIFO
upstream.

Figure 1: TK3711 Upstream Data Path


The TK3701 and TK3711 contain multiple EPON MACs to support multiple logical links identifiers
(LLIDs) within the same device. Multiple logical links allow for different services to have independent
control from the OLTs Dynamic Bandwidth Allocation (DBA) engine. For example, a link can be
configured for low latency and low data rate to support voice services, while a second link can be
configured for high efficiency and high data rate to support standard data traffic. The TK3701 and TK3711
ONUs can be configured to support 1 or more links depending on the services required by the carrier. The
TK3701 supports up to 3 links while the TK3711 supports up to 6 links. (Future firmware releases will
allow the TK3711 to support 7 EPON MACs/LLIDs in a single device.)

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

One FIFO allows frames to


be classified into the CPU
data path. Access is
controlled by system rules
provisioned by the TK3711.

Unicast links are assigned


based on the host
provisioned queue
configuration.

EPON 0

Hi
EPON 0
Link 0

Multicast/Unicast 0
Unicast 1

Link 1
New multicast links are
assigned dynamically by the
OLT when a link is
provisioned in a Shared
VLAN.

UNI 1

Unicast 2

Multicast 0

Low

Multicast 1
Multicast/Unicast 0
Unicast 1

Multiple FIFOs may be


allocated to a single port.
Classification rules allow the
FIFO.

Each UNI port is served by a


STRICT priority scheduler.
Lower numbers are higher
priority.

CPU

UNI 2

Unicast 2

TK3711

The Host provisioned queue


configuration determines the
egress FIFO-Port mapping.
Queues are allocated from a
fixed pool of memory.
Upstream and downstream
pools are independent. The
number of queues and the
available memory is returned
by the Get ONU Info host
interface comand.

Figure 2: TK3711 Downstream Data Path


The EPON MAC in the TK3701 and TK3711 can be configured for different strict priority queuing
structures to support traffic prioritization. Each link can be fed by a different number of queues with
different sizes. Upstream and downstream queue configurations are also independent. For example, a
single link may have 4 queues for upstream traffic, but only a single queue for downstream traffic.
Teknovus provides a few simple configurations as an example. Customization of the configuration on
ONUs in the field allow for a quick and cost effective network service upgrade.
The TK3701 and TK3711 provide two data ports to the user network. Any or all of the queues can connect
to a single port, or the queues may be divided among the two ports. The drawing below shows the basic
queue configuration configured in personality flash with the evaluation kit. There is a link for each
Ethernet port. Each link has to a single queue in the upstream and the downstream. The 2 EPON MAC
links are completely independent. There is no performance difference between this configuration and two
separate ONUs on the same EPON.
EXCEPTION: The TK3711 has two Ethernet ports: a 10/100/1000 Mbps UNI port, and a 10/100 Mbps
UNI port. This allows for a maximum upstream burst of 1 Gbps when using the 10/100/1000 Mbps UNI
port (port 1). Although port 1 can accommodate 1 Gbps, some of the logical links are not designed for such
high data rates. The logical links use a Report RAM to store upstream frame lengths passed from the FIFO
for the respected logical links. Logical links 1,2, and 3 use a larger Report RAM that is suitable for gigabit
data rates, while logical links 4, 5, and 6 use a smaller Report RAM that is suitable for 100Mbps
200Mbps. Exceeding this specification for the 4th-6th logical links will cause packet drops.
Link classification and queue configuration of the ONU will be stored in the NVS section of the ONU flash
memory. Customized default configurations are also possible by programming the personality flash.

ONU Queue Configuration

The Set Onu Queue Configuration host interface command configures the ONUs queue sizes, logical link
count, and connectivity of the queues. A single host interface command defines the queue configurations
for the entire physical ONU. The Get Onu Queue Configuration command can be used to query the active
configuration.
3

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

These commands allow for the configuration of user queues only. ONU firmware requires some resources
for system operation. The table below lists the resources available for configuration on the Teknovus ONU
chips:
Queue Space Allocation and Limits
Attribute
Virtual EPON MACs (LLIDs)
Upstream Queues
Total Upstream Buffer Space
System Upstream Buffer Space
User Data Upstream Buffer Space
Queue Size Units
Total Queues
Reserved Queues
User Data Queues
Downstream Queues
Total Downstream Buffer Space
System Downstream Buffer Space
User Data Downstream Buffer Space
Queue Size Units
Flooding Queue Space
Total Queues
Reserved Queues
User Data Queues

TK3701
3

TK3711
6

64K Bytes
4K Bytes
60K Bytes
1K Bytes
8
1***
7

1024K Bytes**
16K Bytes
960K Bytes
4K Bytes
16
8
8

64K Bytes
4K Bytes
60K Bytes
1K Bytes
Unused Space
Must be >= 2
8
2***
6

128K Bytes
6K Bytes
122K Bytes
1K Bytes
Unused Space
Must be >= 4
16
4
12

** Assuming 256Kx32 external SRAM; 512K byte with 128Kx32 external SRAM.
*** Enabling some firmware features may consume additional resources. For example, IGMP Snooping
requires one queue per port upstream, and one queue downstream if either or both UNI ports are enabled.
A TK3701 with IGMP Snooping enabled on both ports would have 5 queues remaining for the user in each
direction. The ONU Get Information message reports the resources available for user data configuration.

4.1 Set ONU Queue Configuration Host Interface Message


The structure below shows the fields in the host interface message to configure the ONU. A configuration
specifies the number of links the ONU will register. For each link, the number of queues is specified. For
each queue, a queue size is specified. In the downstream direction, the number of ports in use is specified.
For each port, the number of queues is specified, along with the size of each. Finally, the number and size
of the flooding queue is specified. For version 1 firmware the number of queues specified must always be
one. The TK3701 will allocate one shared flooding queue for both ports. The TK3711 does not need a
flooding queue, so no memory need be allocated for this purpose on TK3711-based ONUs.
Note: The ONU must be reset after applying a new queue configuration.

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

Set ONU Queue Configuration


Size
Description
6
ONU Label
Upstream Configuration
1
N, the number of links to configure.

1
1

Link 0 Configuration
M0, the number of upstream
queues for Link 0
Queue 0 Size

Units

Min

Max

TK3701
TK3711

1
1

3
6

TK3701 1KB
TK3711 4KB

2
1

60
240

1
1

6
12

2
2

60
122

1
2
2

1
58
120

1
Queue M - 1 Size
1
Link 1 Configuration

1
Link N 1 Configuration
Downstream Configuration
1
P, the number of Ports to configure.
Port 0 Configuration (i.e. Ethernet port 1)
1
J, the number of
TK3701
downstream queues for Port TK3711
0
1
Queue 0 Size
TK3701 1KB
TK3711 1KB

1
Queue J - 1 Size
Port 1 Configuration

Port P 1 Configuration
Multicast Queue Configuration
1
R, the number of Multicast Queues
1
1
Queue 0 Size
TK3701 1KB
TK3711 1KB

Default

Queue sizes are listed in highest priority to lowest priority order. Queue sizes are given in queue
increments, which vary in size based on the device and direction. For example, the upstream queue
increment on the TK3711 is 4 Kbytes, while the upstream queue increment on the TK3701 is 1 Kbytes.
Note that queue size of zero need not (and cannot) be specified. Queue numbers are relative to their
destination, and are numbered 0..N-1, where 0 is the highest priority queue of the N queues connected to
that destination.
Upstream, queues are associated with their destination Logical Link. Each link must have at least one
queue in the upstream direction.
Downstream, queues are associated with their destination port. A port may have zero queues if it is unused.

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

4.2 Example: Default ONU Configuration


The 2 LLID, 2 Queue, and 2 port configuration used as the default on the Teknovus evaluation kit can be
achieved by the following host interface message. For the example, the ONU has a EPON base MAC
address of 12:34:56:78:9A:BC
Size
Description
6
ONU Label
Upstream Configuration
1
N, the number of links to configure.
Link 0 Configuration
1
M, the number of upstream queues
for Link
1
Queue 0 Size
Link 1 Configuration
1
M, the number of upstream queues
for Link
1
Queue 0 Size
Downstream Configuration
1
P, the number of Ports to configure.
Port 0 Configuration (i.e. Ethernet UNI port 1)
1
J, the number of downstream queues
for Port 0
1
Queue 0 Size
Port 1 Configuration (i.e. Ethernet UNI port 2)
1
J, the number of downstream queues
for Port 0
1
Queue 0 Size
Multicast Queue Configuration
1
R, the number of Multicast Queues
1
Queue 0 Size

Value
12:34:56:78:9A:BC
2
1
30
1
30
2
1
22
1
22
1
16

Note: The ONU must be reset after applying the new queue configuration.

Downstream Broadcast Traffic

There are several types of multicast traffic, including broadcast traffic, on a typical network. Not all the
multicast frames have the same purpose. Frames may contain a broadcast or multicast Ethernet address,
which typically means they should be broadcast to all ports on a LAN. The bridge learning process
requires flooding frames with unicast addresses to all ports when the address has not been learned. There is
also IP multicast traffic, which uses a specific range of Ethernet multicast addresses, and involves special
handling controlled via snooping the IGMP control protocol. Each of these traffic types is handled
independently. When analyzing broadcast or multicast traffic, it is important to keep in mind exactly
what sort of traffic is being handled and the requirements for that particular type of traffic.

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

The purpose of VLAN tags is to divide a single physical network into several Virtual LANs, or VLANs.
The VLAN ID (VID) in the VLAN tag identifies the virtual network to which the frame belongs. Frames
without VLAN tags can be considered to belong to the virtual network with a null VID.
IEEE 802.3ah defines a special broadcast LLID, value 0x7FFF, which by definition is received by all
ONUs on the PON. Not all ONUs may belong to the same virtual network. A VLAN may consist of only
a few subscribers on the PON. It is desirable to limit broadcast traffic on the VLAN to only those
subscribers that receive it. Teknovus firmware accommodates this requirement by using an additional
LLID for broadcast traffic on each VLAN. The Simple Bridge that is, the network without VLAN tags
uses the the standard broadcast LLID for its broadcast channel. Each Shared VLAN uses its own LLID
to carry traffic that should be flooded within the VLAN. This LLID is a broadcast LLID for that VLAN,
though it has a different LLID value than 0x7FFF. Frames on the broadcast channel for a particular VLAN
are flooded out all ports on the ONU that belong to that VLAN. (Note that not all UNI ports on an ONU
necessarily belong to a given VLAN. The connection is a function of the classification rules on the ONU.)
IP multicast, most importantly digital video in common carrier applications, is another category of
multicast traffic. Video delivery is typically considered a separate service offering from Internet access,
VPNs, or other subscriber services, and so it deserves separate handling.. Teknovus firmware places IP
multicast traffic on the standard broadcast LLID to ensure it is available to all ONUs regardless of VLAN
mode. ONUs forward IP multicast groups based on the results of snooping the IGMP protocol. IP
multicast traffic is forwarded to those ports on an ONU which have Joined that group by using IGMP. An
IP multicast frame might be forwarded only to one port, or it might be flooded to all ports on the ONU if all
ports have joined that particular group.
The TK3701 and TK3711 hardware deals with flooding frames in slightly different fashion. The TK3701
is capable of copying frames from a single downstream queue to multiple UNI ports. Traffic that must be
sent out all UNI ports is placed into a flooding queue, which then transmits to all ports. Traffic that only
needs to reach a single UNI port does not use a flooding queue, even if the Ethernet address is a broadcast
type. Shared VLANs or Dedicated VLANs, or IP multicast, might only need to reach a single port, and
thus would not use the flooding queue.

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

The TK3711 improves on this architecture by adding the ability to copy downstream frames into multiple
queues. Instead of using a queue that connects to both ports, the TK3711 copies a flooded frame into two
queues, each of which connects to a different port. No flooding queue is needed.

The Host Interface message Set ONU Downstream Broadcast Queue allows the Host processor to control
which of several downstream queues on each port is used for flooding traffic from the VLAN broadcast
LLID. When firmware decides that traffic must be forwarded to a single UNI port, the queue set with this
command is used. When firmware decides that traffic must be forwarded to all UNI ports, the TK3701
firmware places traffic into the allocated flooding queue, while the TK3711 uses the broadcast queue
defined for each port by this command, copying the frame to both queues in the DLU.
The Host Interface also provides a field in the Set ONU IGMP Snooping Parameters message for
selecting the IP multicast forwarding queue. This value is used in a similar fashion to that for the broadcast
channel for the ONU VLANs. However, it is used in the forwarding rules for IP multicast. Thus,
downstream video traffic can be directed to a different queue than regular broadcast traffic if desired.
The queue(s) selected for broadcast and IP multicast may be the same as those used for unicast data, or they
may be queues dedicated to only to this type of traffic, as the Host chooses.

Traffic Filtering and Classification

Each Ethernet port on the ONU is associated with a particular lookup engine (LUE). The role of the LUE is
to filter unwanted frames from the data stream, as well as classify desirable traffic into particular priority
queues based on specific attributes of incoming frames.
The LUE associated with an ONU UNI port is referred to as an ELU (Ethernet Lookup Engine). The LUE
associated with the EPON port is known as the DLU (Downstream Lookup Engine). Gigabit ONUs also
feature a GLU (Gigabit Lookup engine) associated with the GbE UNI port.
The operation LUEs can be configured remotely by the Host Interface. This is accomplished by
provisioning rules. The ONU has two different types of lookup engine rules. Classification rules are used
8

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

to forward a class of frames to a particular queue. Filtering rules apply to an entire port and are used to
block particular frames.

6.1 Rules Defined


A rule consists of a number of clauses. Each clause is a Boolean operation which tests a particular field in
a frame against a value, using a particular operator. If all clauses in a rule evaluate to TRUE, the rule is
said to match the frame. That is, the results of each clauses are logically ANDed together to determine
whether the rule matches the frame. The result of a matching rule may be applied to the frame.
Parts of a Clause
FieldSelect
Returns a specific contiguous sequence of bits from the input frame
operator
The tested condition (equal to, greater than, etc.)
Value
Value used for comparison
Note: A rule with more than one clause is sometimes referred to as a chain rule or rule chain.
Operator
Symbol
F
==
!=
<=
>=
exists
!exists
T

Description
Never match
Equal to
Not equal to
Less than or equal to
Greater than or equal to
Match when field exists in the frame
Match when field does not exist in the frame
Always match

Each rule also has a result. The result is the action to be taken on the frame if the rule matches the frame.
Results in filtering rules contain an action to discard a frame. Results in classification rules contain an
action to forward the frame, and also the queue to which the frame should be forwarded. The TK3711 (and
OLT chips) supports additional actions, such as inserting or deleting a VLAN tag.
Each rule has a precedence value. All rules in the lookup engine are matched against every frame in an
unspecified order. So, it is possible to have more than one rule that matches a single frame. These rules
may have different results. The precedence value is used to resolve cases where more than one rule
matches a frame. The result of the rule with the lowest precedence value is used.
Conflicting rules at the same precedence level should not be created. The result in such a case will be the
result of one or the other rule, but which result is chosen will be indeterminate and could even vary from
frame to frame.
The rest of this document uses a pseudocode representation of a rule as shown below.
5: if (EtherType == 0800) then queue = link 0 queue 0;
The leading integer denotes the precedence of the rule (discussed below). Clauses are reprented by the
conditions in parentheses. The result of the rule follows then then keyword.
9

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

Every rule in the LUE table is evaluated for every frame. Thus, the condition if (Ethertype == 8808) OR
(Ethertype == 8809) can be represented as two rules, each with one clause, rather than one rule with two
clauses combined with OR.
5: if (Ethertype == 8808) then discard;
5: if (Ethertype == 8809) then discard;

6.2 The Rule Search Process


The rule search algorithm below describes the way frames will be evaluated by the TK3701.

Tk3701RuleSearch: (frame, ruleSet)


result.queue = queue 0
result.action = forward # hardware default action is changed by a precedence 7 system rule
result.precedence = LowestPrecedence # numerically smaller values have higher precedence
for each rule in ruleSet
if (rule.precedence result.precedence )
if (rule matches frame)
result.queue = rule.queue
result.action = rule.action # Filtering rules return Discard
result.precedence = rule.precedence
ApplyResult (frame, result)

That is, the result of the rule with the highest precedence is applied to the frame.
The TK3711 uses a slightly modified method of combining results of the rule search:
Tk3711RuleSearch: (frame, ruleSet)
result.queue = queue 0
result.action = forward # hardware default action is changed by a precedence 7 system rule
result.precedence = LowestPrecedence # numerically smaller values have higher precedence
for each rule in ruleSet
if (rule matches frame)
if (rule.precedence == result.precedence )
result.queue |= rule.queue
result.action |= rule.action # Filtering rules return Discard
else if (rule.precedence < result.precedence)
result.queue = rule.queue
result.action = rule.action # Filtering rules return Discard
result.precedence = rule.precedence
ApplyResult (frame, result)
10

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

In other words, results for rules at the same precedence level in the TK3711 are bitwise ORed together.
This effect can sometimes be useful when building up a queue destination using several rules. However, it
is also possible to misplace a frame into a system FIFO using this feature.
For this reason system vendors SHOULD take care to ensure that a particular frame is only classified into a
single TK3701 FIFO. In the case of the TK3711 the rules MUST be provisioned such that, for any
particular frame, only one FIFO is ever used for classification. Otherwise the result of the bitwise OR
operation could place an arbitrary frame into a System FIFO.
Note: Filtering and classification rules may be changed dynamically by the Host software without
requiring the ONU to be reset. Only changing the queue configuration requires that the ONU be reset.

6.3 Use of Precedence to Create Unambiguous Rule Sets


The purpose of classification rules is to examine frames and direct them to a desired queue. For example, a
rule to take all IP traffic from a port and direct it to link 0 upstream could be written as:
5: if (EtherType == 0800) then queue = link 0 queue 0;
A more complicated classification scheme might require splitting traffic into two queues based on priority.
This set of two rules, each with two clauses, creates priority queues for the IP TOS field:
5: if (TOS >= 0) and (TOS <= 3) then queue = link 0 queue 0;
5: if (TOS >= 4) and (TOS <= 7) then queue = link 0 queue 1;
Consider two rules at the same precedence level that classify traffic into two different FIFOs: QA and QB
respectively. The diagram above illustrates the relationship between rules A and B.

All Possible Frames

Frames
Forwarded
to Q[A]

All Possible Frames

Frames

Frames
Forwarded
to Q[A]

BAD Forwarded
to Q[B]

Frames
Forwarded
to Q[B]

OK
Figure 3: Invalid and Valid Classification Schemes
If the rules that forward to QA can match the same frame as the rules that forward to QB, the result is
ambiguous. Consider an attempt to forward all IP traffic into a low priority queue, except for that traffic
from one privileged station with MAC address 00-0d-b6-12-34-56.
11

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

5: if (SA == 00-0d-b6-12-34-56) then queue = link 0 queue 0;


5: if (Ethertype == 0800) then queue = link 1 queue 1;
Unfortunately, this rule set is ambiguous. Consider a frame from 00-0d-b6-12-34-56 that is also an IP
frame. Both rules match this frame. The result in such a case, as described above, is undetermined. The
frame might appear in queue 0, or it might appear in queue 1.
Rule precedence is used to remove the ambiguity from such cases. Consider
4: if (SA == 00-0d-b6-12-34-56) then queue = link 0 queue 0;
5: if (Ethertype == 0800) then queue = link 1 queue 1;
With this rule set, the problematic frame will still match both rules. However, the differing precedence of
the rules means that the result of the precedence 4 SA rule will be used instead of the precedence 5
Ethertype rule.
Note that filtering rules at the same precedence do not have the same ambiguity as classification rules.
Since the result of both rules is the same -- to discard -- in some sense it does not matter which rule
matches to produce the discard result. However, precedence is still useful with filtering rules when applied
in addition to the rules in the classification scheme.
The purpose of filtering rules is to block certain types of frames. Typically, these rules have higher
precedence than any classification rule. For example, a rule to block traffic from a particular device with
MAC address 01:23:45:67:89:AB could be written as:
2: if (SA == 01:23:45:67:89:AB) then discard;
Note that the rule precedence for the discard example is shown as 2 while the forwarding example is
shown as 5. If all three of these rules were programmed in the lookup engine at the same time, the
forwarding rules would try to forward traffic to one of two priority queues for all sources. The filter rule, at
higher precedence, would override this forwarding attempt for one particular source. So, the net result
would be priority traffic for all sources except 01:23:45:67:89:AB, from which all traffic is dropped.

6.4 System Rules and Precedence


The ONU firmware creates a number of rules in the lookup engines in order to perform basic system
functions and enforce proper operation. The table below shows an example of the ONU system rules,
along with the precedence ranges used. Please note that this table is only an example. System rules may
be changed or rearranged as necessary so that the ONU can correctly perform its functions and comply with
applicable standards.

12

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

Precedence
0

1
2
3
4
5
6
7

System Rules
Capture frames to ONU
Discard frames for other
ONUs
IP multicast forwarding
IP multicast discard
Bridge learning discard
Broadcast forwarding

Notes

Reserved for user rules

Typical classification rule


Typical classification default
The default action of the hardware is to forward frames to
queue 0. It is useful in most applications, however, only for
frames selected by the classification scheme to be forwarded.
This system rule sets the action for every frame to discard by
default. Higher level classification rules can then override
this action for desired frames.

Default discard.

Typical filter rule precedence

In order to provide customers with maximum flexibility, firmware allows use of any precedence level on a
rule. However, care must be taken not to interfere with the operation of system rules by applying user rules
that conflict with system rules. For example, a discard all frames rule at precedence 0 could prevent the
ONU from properly responding to frames addressed to it, or even from registering with the OLT. This
may, in fact, be the effect desired, but it could also be an error. Most user rules should be restricted to
precedence 4 through 6. Precedence 2 is the level used by the rules created by bridge learning to discard
user frames, and is a good general value for filter rules.

6.5 Viewing Default Rules via the ONU CLI


The ONU firmware provisions a set of default filtering and classification rules. To view the current rules
via the ONU CLI use the rule command. System rules always start at index 112. To view the first 3
downstream rules enter:

3701/>/dlu/rule 112 114


Rule 112: Static Pri 1 First
if Field 0 >= 544b3701e2e4
then Queue = 0 Forward;
(00000043 0158544b 3701e2e4)
Rule 113: Static Pri 1 Last
if Field 0 <= 544b3701e2e5
then Queue = 0 Forward;
(00000042 01d8544b 3701e2e5)
Rule 114: Static Pri 1 First
if Field 0 >= 0180c2000000
then Queue = 0 Forward;
(00000043 01580180 c2000000)

13

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

To view the first 3 upstream filter rules for UNI Port 1 enter:

3701/>/elu/rule 1 112 114


Rule 112: Static Pri 7 Single Ports 1 2 Age: 0
if Field 0 exists
then Discard;
(000000d1 39000000 00000000)
Rule 113: Static Pri 3 Single Ports 1 2 Age: 0
if Field 3 == 000000008808
then Discard;
(000000d6 19000000 00008808)
Rule 114: Static Pri 3 Single Ports 1 2 Age: 0
if Field 3 == 000000008809
then Discard;
(000000d6 19000000 00008809)

The TK3711 provides two commands for this purpose /elu/rule and /glu/rule. The syntax of these
commands is identical to that used to view the downstream filter rules. /elu/rule displays the rules for the
GbE port, and /elu/rule is used to display the rules for the 10/100 port. The meaning of the Field index
values is discussed in the section Lookup Engine Field Definition.

6.6 Rule Tables


The filtering and classification share a common rule table. Some rules are required for the embedded
software to redirect frames for OAM, MPCP, IGMP, and other firmware features. The following table
defines the number of rules available. The rule tables for upstream traffic are independent for each
Ethernet port.

Attribute

TK3701
Downstream

Total Clauses
Dynamic learning
Reserved for firmware
Available for users
Max Clause Per Rule
Precedence Levels

64
0
16
48
8
8

Upstream
(per port)
128
64
16
48
8
8

TK3711
Downstream
128
0
32
96
2
8

Upstream
(per port)
128
64
16
48
8
8

Filtering rules and classification rules share the same user rule space. If enabled, IGMP forwarding rules
will also share this space, requiring one rule clause per group forwarded.

14

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

6.7 Lookup Engine Field Definition


The lookup engines implement programmable fields which point to particular areas of interest in a frame.
These fields are used in rule clauses to decide the fate of a frame. Fields are thus typically portions of a
frame such as addresses, any of several priority fields or protocol types in different layers. The TK3701
can parse 8 fields simultaneously while the TK3711 and TK3713 support 12 fields. Several fields are
predefined by the firmware, while others are configurable through the host interface.
Field

Bits

48

48

2
3

32
32

4
5
6

32
32
32

7
8
9
10
11

32
16
16
16
16

TK3701
Downstream
L2 Dest Addr

Upstream
L2 Dest
Addr
L2 Source
Addr
User
L2
Length/Type
VLAN ID
User
IPv4
Protocol
User

L2 Source
Addr
Link index
L2
Length/Type
VLAN ID
User
IPv4 Protocol
User

TK3711
Downstream
L2 Dest
Addr
L2 Source
Addr
Link index
L2
Length/Type
VLAN ID
User
IPv4
Protocol
User
User
User
User
User

Upstream
L2 Dest
Addr
L2 Source
Addr
User
L2
Length/Type
VLAN ID
User
IPv4
Protocol
User
User
User
User
User

TK3713
Downstream
L2 Dest
Addr
L2 Source
Addr
Link index
L2
Length/Type
VLAN ID
User
IPv4
Protocol
User
User
User
User
User

Upstream
L2 Dest
Addr
L2 Source
Addr
User
L2
Length/Type
VLAN ID
User
IPv4
Protocol
User
User
User
User
User

The Get/Set ONU Field Selector host interface messages allows the host processor to query host interface
configurations and set values for the user configured fields.
A field may be any string of bits in a frame, starting at an offset from the beginning of a particular L2/3/4
header, up to 32 bits wide for fields 0..7. Fields 8..11 in the TK3711 can be up to 16 bits wide. A field in
a frame is defined by a field descriptor code which packs the protocol layer, offset into that layer, least
significant bit of the field, and the field bit width into a single, compact, 16-bit value.
Bits
15:11
10:6
5:3
2:0

Value
Bit Width (0..31 represents 1..32
Bit offset (LSB)
Dword offset (Dword = 32 bits)
Layer Select

Note that the bit width is one less than the actual width of the field. Since a field cannot be of width zero,
this convention allows encoding widths up to 32 bits in only five bits.
15
0

15

14
13
12
Width (5 bits)
1
1
1
7

11

10

9
8
7
Bit offset (5 bits)
0
0
0
8

5
4
3
Dword (3 bits)
0
0
0

0
0

7/1/2005
Teknovus Confidential - View Under NDA Only

2
1
0
Layer (3 bits)
0
1
0
2

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

A dword is a 32-bit word. The 3-bit dword offset ranges from 0 to 7, and so a field can reside anywhere
in the first 32 bytes of a particular protocol layer. On the TK3713, the dword offset is a 4 bit field, and so
the lookup engine can reach up to 64 bytes into a particular protocol layer.
16

15
14
13
Width (5 bits)
1
1
1
F

0
0

12

11

10
9
8
Bit offset (5 bits)
0
0
0
0

7
0

5
4
3
Dword (4 bits)
0
0
0
0
0

2
1
0
Layer (3 bits)
0
1
0
2

6.7.1 Layer Select Values


Number
0
1
2
3
4
5
6
7
8 to 255
1.
2.

Layer
Disabled Field Select
Preamble/Layer 2 - Header
Layer 2 - Type field 1
Layer 2 - VLAN tag 2
Reserved
Layer 3 IPv4 Header
Layer 4 XXX/IPv4 Header
Layer 3 IPv6 Header
Reserved

Common Fields found in layer


LLID, DA, SA, DSAP, SSAP, OUI
L2 Type field 1
L2 VLAN tag 2
TOS, Protocol, IP DA, IP SA
TCP port, UDP port
Traffic Class, Flow label, Source Address

The last EtherType field in the frame will be the one that is selected by the LUE.
Based on the Layer Select, all necessary fields are validated by the LUE. For instance, if Layer
Select 3 is specified, the frame will not match unless the EtherType field == 0x8100 (the VLAN
EtherType), and so on. All necessary validation up to the beginning of the layer is performed by
the ONU. Therefore, the host software should not provision redundant rules to validate the frame.

Note: Layer selects in the TK3701Y do not qualify the EtherType field for layers greater than 2.

6.7.2 Preamble/Layer 2 Header


The EPON downstream provides an additional frame header that carries the link index and LLID. By using
the preamble layer select, these values can be used for filtering or classification. The CRC-8 carried in the
preamble header is replaced with the link index. The link index provides an offset value from the ONU
base MAC address for the link. For example, an ONU with 4 links would receive packets on LLID index 0
to 3, where the MAC address for the ONU is the ONU base MAC address plus the LLID index value. In
the case that the LLID is not on this ONU, the frame has a link index one greater than the maximum
number of receive links (8). Field parsing in the preamble layer is allowed only on the EPON interface, but
not on the standard Ethernet interfaces (UNI, CNI/LNP/NNI).
The table below shows the fields and the bit selects for an Ethernet frame with a length field. The length
field should be followed by the LLC for SNAP encapsulation (DSAP=0xAA, SSAP=0xAA, CTL=0x3).
While other LLC frames can be received with extraction of the DSAP and SSAP, parsing of these frames
beyond the LLC is not possible. To extract the DSAP value into a field select, a layer select of 1, dword
(32 bits) offset 5, bit offset 24, and a length of 8 would be used. If the frame does not contain a DSAP
16

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

value, the field will store a not present value. All comparisons to a field with a not present value will
fail comparison except a check for not present.

3 3 2 2 2 2 2 2
1 0 9 8 7 6 5 4
Reserved (Unknown)
Reserved (Always 0)
L2 DA [31:0]
L2 SA [47:16]
L2 SA[15:0]
DSAP [7:0]
OUI [15:0]

2 2 2 2 1 1
3 2 1 0 9 8
LLID Value

1 1
7 6

1 1
5 4

1 1
3 2

1 1
1 0

9 8

7 6

5 4

3 2

1 0

LLID Index
L2 DA [47:32]

L2 Length Field [15:0]


CTL [7:0]
L2 Type Field [15:0]

SSAP [7:0]

OUI [23:16]

The following table shows a frame without the SNAP encapsulation. Although the L2 type field is present
in both of these tables, it is at different dword offsets. The different dword offsets make it impossible to
gather the type field of the packet using this layer select into a single field. The type should be parsed
using the L2 type field since this field will exist when the value is an EtherType, not a length field.
3 3 2 2 2 2 2 2
1 0 9 8 7 6 5 4
Reserved (Unknown)
Reserved (Always 0)
L2 DA [31:0]
L2 SA [47:16]
L2 SA[15:0]

17

2 2 2 2 1 1
3 2 1 0 9 8
LLID Value

1 1
7 6

1 1
5 4

1 1
3 2

1 1
1 0

9 8

7 6

5 4

3 2

1 0

LLID Index
L2 DA [47:32]

L2 Type Field [15:0]

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

6.7.2.1 Use of the Link Index Field Select Value


LLID values are dynamically assigned by the OLT, each time a particular Logical Link is discovered. The
LLID value assigned for a particular MAC may differ from a previously assigned value. For this reason the
ONU maintains a mapping table between the physically LLID values and the Links MAC address. The
Link Index is that integer that added to the ONU base MAC address specifies a particular Logical Link.
Every downstream classification rule MUST include a clause to qualifying the Logical Link on which a
particular frame was received, such as: Link Index == 2, to specify the first 2nd Link. *

EPON MAC

0xCD9E

Physical LLID

Link Index

0x5AC2

0x2452

0xCD9E

Ethernet Frame

LUE

Figure 4: Usage of the Link Index Field Select.


For the Link Index field select the equality operator is the most useful. Note that every rule in the
downstream classification scheme must contain a clause matching the link index equal to a value. This
information is used by the ONU firmware to determine which logical links are associated with which
queues in the downstream direction. Each queue should be owned by one and only one logical link.
If the Link Index is not used to qualify the Logical Link, traffic may still flow through the ONU. However
many functions of the ONU, such as link statistics or EPON MAC loopback, will cease to behave as
expected. The hardware is capable of directing traffic from multiple logical links into a single queue. But
if the ONU is configured in this manner, then there is no longer a unique mapping from queue to logical
link. So, for example, the queue received frame count will count frames from both links, and there is no
way to distinguish them. Similarly, looping back one logical link would affect both. Implementations that
need a full feature set conforming to IEEE 802.3ah should always maintain a unique queue to logical link
association in the classification scheme.
The Link Index is not required to qualify filtering rules.

6.7.3 Layer 2 Type field


The layer type field can be found in three possible frame locations. Frames without a length field or a
VLAN tag will have a type field following the source address. Frames with a VLAN tag and no length
field will have the type field after the last VLAN tag in the stack. Lastly, frames with a SNAP LLC will
contain the type field after the OUI. The layer 2 type field allows for a single layer and offset for all 3
cases. Note that a length field or a VLAN protocol type (i.e. 0x8100) will never match from this layer
select since these always lead to a final layer 2 protocol type. The last EtherType field in the frame will be
the one that is selected by the LUE.
18

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

3 3 2 2 2 2 2 2 2 2
1 0 9 8 7 6 5 4 3 2
Reserved (Unknown value)

19

2 2
1 0

1 1
9 8

1 1
7 6

1 1 1 1 1 1 9 8
5 4 3 2 1 0
Layer 2 Type [15:0]

7/1/2005
Teknovus Confidential - View Under NDA Only

7 6

5 4

3 2

1 0

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

6.7.4 Layer 2 VLAN tag


The TK3701 and TK3711 can parse up to 3 VLAN tags in a stack. A Dword offset of 0, always points to
the outermost tag with higher offsets to the next tags. The table below shows the position of the VLAN
tag. It is not recommended to parse the type or length field from this layer offset. The VLAN tag contains
3 fields. PRI[2:0] contains the VLAN priority bits while the VID[11:0] contains the VLAN identification
tag. The C field is the canonical format identifier. If a VLAN tag is not present, any field for the tag will
show up as not present. Checking for a does not exist or exists condition on the VID is the best way
to check for the presence of a tag. Based on the Layer Select, all necessary fields are validated by the LUE.
For instance, if Layer Select 3 is specified, the frame will not match unless the EtherType field == 0x8100
(the VLAN EtherType), and so on. All necessary validation up to the beginning of the layer is performed
by the ONU.
3 3 2 2
1 0 9 8
PRI[2:
C
0]
PRI[2:
C
0]
PRI[2:
C
0]

2 2 2 2 2 2
7 6 5 4 3 2
VID [11:0]

2 2
1 0

1 1
9 8

1 1
7 6

1 1 1 1 1 1 9 8 7 6
5 4 3 2 1 0
Layer 2 Type/Len [15:0]

VID [11:0]

Layer 2 Type/Len [15:0]

VID [11:0]

Layer 2 Type/Len [15:0]

5 4

3 2

1 0

6.7.5 Layer 3 IPv4


The IPv4 header can be parsed for the Type of Service (TOS), source IP address, destination IP address, or
any other portion of the header. It is a common practice, to use only the upper 3 bits of the TOS field (IP
Precedence) to signify class of service. It is not necessary to take the field based on the header definition.
The hardware will handle any string of bits in a 32-bit word.
3 3 2 2 2 2 2 2
1 0 9 8 7 6 5 4
Version
Hdr Len
Identification
Time to Live
Source IP Address
Destination IP Address
Options (if any)

20

2 2 2 2 1 1
3 2 1 0 9 8
Type of Service
Protocol

1 1
7 6

1 1 1 1 1 1 9 8 7 6
5 4 3 2 1 0
Length of datagram
Flags
Fragment Offset
Header Checksum

7/1/2005
Teknovus Confidential - View Under NDA Only

5 4

3 2

1 0

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

6.7.6 Layer 4 XXX/IPv4


It is often desirable to filter packets based on layer 4 (UDP or TCP) port numbers. The ability to block
ports can be used to disable certain applications from using the PON. Layer 4 parsing will only be done on
IPv4 frames. It is also required that layer 4 header be within the first 60 bytes of the packet. Rules that use
the layer 4 fields should qualify it with the IPv4 protocol type. The UDP header is shown below as a
reference.
3 3 2 2 2 2 2 2
1 0 9 8 7 6 5 4
Source Port [15:0]
Length [15:0]

2 2
3 2

2 2
1 0

1 1
9 8

1 1
7 6

1 1 1 1 1 1 9 8
5 4 3 2 1 0
Destination Port [15:0]
Checksum [15:0]

7 6

5 4

3 2

1 0

6.7.7 Layer 3 IPv6


The TK3701 and the TK3711 allow for parsing of the IPv6 header. The first 8 32-bit words are available
for parsing. In the TK3701, the IPv6 field rules should be qualified with a layer 2 protocol type equal to
0x86dd.
3 3 2 2 2 2 2 2 2 2
1 0 9 8 7 6 5 4 3 2
Version
Traffic Class
Payload Length
Source Address
Source Address
Source Address
Source Address
Destination Address
Destination Address

2 2
1 0

1 1 1 1 1 1 1 1 1 1
9 8 7 6 5 4 3 2 1 0
Flow Label
Next Header

9 8

7 6

5 4

3 2

1 0

Hop Limit

Field Code Examples

Example: EtherType
The EtherType is found in the Layer 2 Type layer select (2). It is in the first dword, which is to say offset
0. The field is 16 bits wide, starting at bit 0.
15
0

14
13
12
11
Width (16 1 = 15)
1
1
1
1
7

10

8
7
Bit offset (0)
0
0
0

0
8

4
3
Dword (0)
0
0
0

0
0

1
0
Layer (2)
0
1
0
2

So, the field code for this field is 7802 (hexadecimal)


Example: VLAN VID
21

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

The VID would be found in the Layer 2 VLAN Tag layer select (3). The VID is in dword 0, 12 bits wide,
starting at bit 16.

15
0

14
13
12
11
Width (12 1 = 11)
1
0
1
1
5

10

9
8
7
Bit offset (16)
0
0
0

4
3
Dword (0)
0
0
0

1
0
Layer (3)
0
1
1
3

So, the VID would be field code 5C03 (hex).


Example: IP Precedence (TOS, DSCP)
The IP Precedence field is the upper three bits of the TOS field. Note that traditional Internet
documentation such as RFCs number bits in a word from MSB to LSB, while the Teknovus convention is
to number bits starting from the LSB. So, the TOS field is found in layer select 5 (IPv4), Dword 0, three
bits wide starting at bit 21.
15
0

14
13
12
Width (3 1 = 2)
0
0
1
1

11

10

9
8
7
Bit offset (16)
0
1
0

6
1

4
3
Dword (0)
0
0
0

1
0
Layer (6)
1
1
0
5

So, the field code for the IP Precedence field would be 1545 (hex).
Example: TCP IP Port Number
The layer select table shows that Number 6 is the L4 TCP/IP port.
15
0

14
13
12
Width (16-1=15)
1
1
1
7

11

10

9
8
7
Bit offset (21)
0
0
0
C

4
3
Dword (0)
0
0
0

0
0

1
0
Layer (5)
1
0
1
5

So, the field code for TCP/UDP port number 7C05 (hex).
The following table lists field codes for commonly used IPV6 classification fields:
IPV6 Field Code
9807
3D07
1F07
380F
3A0F
7C0F
F817
22

IPV6 Field Name


Flow Label [19:0]
Traffic Class [7:0]
Version [3:0]
Hop Limit [7:0]
Next Header [7:0] Also known as Protocol Type which could indicate MLD.
Payload Length [15:0]
Source Address 1 [31:0]
7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

F81F
F827
F82F
F837
F83F

Source Address 2 [31:0]


Source Address 3 [31:0]
Source Address 4 [31:0]
Destination Address 1 [31:0]
Destination Address 2 [ 31:0]

7.1 Viewing and Editing Field Code Values via the ONU CLI
The ONU CLI provides the ability to view and modify field select values. Two commands are provided to
modify the default field select values /pers/upfield and /pers/dnfield. Entering either command with no
arguments will display the current default.
3711/pers/>dnfield
Field
0:
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:

Up
0000
0000
0000
7802
5c03
1545
3c15
1743
1647
3d07
0000
0000

Down
0000
0000
3809
7802
5c03
1545
3c15
1743
1647
3d07
0000
0000

The field select values at index [0, 2] upstream and index [0, 1] downstream are reserved by the OLT and
cannot be changed.
Reserved Index Definition
Index Meaning
0
Destination MAC Address
1
Source MAC Address
2
Link Index
Use the upfield command to modify the field select for UNI ports and use the dnfield command to modify
the field select for downstream ports. The command takes as its arguments the field select index of the field
to be modified followed by the new definition. e.g. /pers/upfield 10 0x1545 will modify field 10 to select
IPv4-ToS.
The ONU will display a human readable interpretation of the field select values with the field command.
For instance to display the value for field 9 upstream, enter:

3711>/elu/field 9
3d07 => L3 IPv6 DWord +0 Bits 27:20
23

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

8 Tips for Designing Rules


8.1 Default Rules
Designers of classification schemes should consider including a default rule for forwarding traffic. This
rule should exist at the lowest user precedence level (6), and should always forward traffic. The always
operator is useful to create a rule that is always true. For example, if always then queue = link 0 queue 0
would be a default rule that puts any frame into the first queue for the first link. Other rules can then be set
at precedence 5 that override the default rule. Another way to create a rule that is always true is to check
for Field 0 (MAC DA) exists. All valid frames must have a MAC DA, so the exists operator is always
true for this field.
Note that a default rule can save clauses in the rule table. Consider the following two classification
schemes:
5: if (field 5 >= 0) and (field 5 <= 3) then queue = link 0 queue 0;
5: if (field 5 >= 4) and (field 5 <= 7) then queue = link 0 queue 1;
This pair of rules requires four clauses and completely specifies a classification scheme with two
precedence queues. Compare to this set:
6: if (DA exists) then queue = link 0 queue 1;
5: if (field 5 >= 0) and (field 5 <= 3) then queue = link 0 queue 0;
This rule set accomplishes the same task with three clauses instead of four. A more extreme example using
four precedence queues might be:
6: if (always) then queue = link 0 queue 3;
5: If (field 5 == 2) then queue = link 0 queue 0;
5: If (field 5 == 4) then queue = link 0 queue 1;
5: If (field 5 == 6) then queue = link 0 queue 2;
In this case, TOS 4 and TOS 6 each get a queue. TOS values 0, 1, 3, 5, and 7 go into the lowest precedence
queue. It would take eight clauses to explicitly specific this result without a default, whereas the default
rule allows specifying the result in four.
Default rules can also guard against leaving some traffic without a destination, and thus dropped. Some
applications may desire the default action to drop frames. Many, however, should attempt to forward all
frames, and a default rule is a good way to ensure that the other classification rules do not leave any gaps in
their description of the traffic to be forwarded.
24

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

8.2 Conditions Involving Logical OR


Note that all clauses of a rule are ANDed together. There is no representation of a logical OR operator.
Since all rules are matched against a frame, an OR condition can be created by entering two (or more)
rules. That is, to create a filter scheme that drops traffic if SA = 1 OR SA = 2, create two rules:
if (SA == 1) then discard;
if (SA == 2) then discard;
To implement a condition such as (SA == 1) and ((EtherType == 0800) or (EtherType < 1536)), create
two rules by distributing the first clause thus:
if ((SA == 1) and (EtherType == 0800)) then discard;
if ((SA == 1) and (EtherType < 1536) then discard;
That is, you can consider a rule set to be the sum of products form of the desired Boolean expression,
where each conjunctive term corresponds to a single rule.

25

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

8.3 Special Considerations when Working with TK3711 Rules


The TK3711 classification supports only 2 clause rule chains, as opposed to the 8 clauses supported by the
TK3701. For this reason, creating a TK3711 classification scheme can be tricky. This section describes
methods that may aid in provisioning the TK3711.
Before providing specific example of rule chains in TK3701 and TK3711 ONUs, lets review the basics of
logical AND and OR operations. In the following tables, inputs A and B determine the outputs X and Y.
The logical AND is represented by & while the logical OR is represented by | symbols.
X = A&B
Y = A|B
A
B
X
Y
0
0
0
0
0
1
0
1
1
0
0
1
1
1
1
1
Logical outputs X and Y as function of inputs A and B.
As an example of a rule with a complex set of conditions to block all TCP ports in range 20-25, there are
two ways to implement these rules.
1) using logical AND
2) using logical OR
By DeMorgans theorem, X = A | B . This implies that we can determine the X output using logical OR
instead of AND.

8.3.1 Example 1: Logical AND


An example of a rule with a complex set of conditions ANDed together to block frames with TCP ports in
range 20-25:
Rule to Block All TCP Frames in range [20, 25]
Clause
EtherType == 0x0800 (TK3701Y layer select does not qualify the EtherType field for L3)
IPv4 Protocol == 6 (TCP)
AND
TCP Port >= 20
TCP Port <= 25
This example uses the user defined field 7 to extract the TCP port from the TCP header for use in the rule
comparison.
In this example, a single rule command is sent from Host to OLT to set the ONU filter rule. This single rule
command contains 4 rules ANDed together. The result is that TCP/IP frames with ports in the range of 2025 are discarded.

26

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

8.3.2 Example 2: Logical OR


In TK3701 and TK3711 chipsets, multiple separate rules at the same precedence level are logically ORed.
Thus multiple rules can be used in place of multiple clauses. An example of a rule chain with a complex set
of conditions ORed together to block frames with TCP ports in range 20-25:
Using ORed Rules for Filtering
Rule Type
Rule Level
Filter
4
Classification 4
Classification 4
Classification 4
Classification 4

Rule
If Exists (DA), Drop
if EtherType != 0x0800 (IPv4), Forward
if IPv4 Protocol != TCP, Forward
if TCP Port <= 19, Forward
if TCP Port >= 26, Forward

This example uses the user defined field 7 to extract the TCP port from the TCP header for use in the rule
comparison.
The result of this Logical OR rule setting is identical to the result of the Logical AND rule setting in
example 1. It is recommended to use this type of logic for TK3711 ONUs when complex rules are
required.

8.4 Identical Downstream Flows


Identically configured flows arise when two links with the same egress UNI port are configured in the same
bridged VLAN, or configured in Simple Bridged mode. The ONU must never be configured in this manner.

8.5 One FIFO Fed by Multiple UNI Ports


Upstream Data Path
CPU

Port 1

System
EPON 0

User 0

UNI 1

Link 0
Link 1
System
User 0

TK3711

NG

UNI 2

Figure 5: One Upstream FIFO Shared by two UNI Ports


In the figure above both UNI 1 and UNI 2 are classified into the same priority FIFO (M + 1).0.0. Each
FIFO may have only one associated ingress port. Otherwise, frames will be lost.
27

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

The mechanism to resolve such a race condition would involve complex hardware, such as a second layer
of priority queues. A far les costly solution is to simply allocate each port its own priority queue.
This example illustrates a second problem. Link 1 is fed by 2 different ports. This is functionally
acceptable, but will cause certain link statistics to be calculated as the sum of both links.

8.6 Two downstream FIFOs receiving frames from the same link
Downstream Data Path
EPON 0

CPU

EPON 0
Link 0
Link 1

Multicast/Unicast 0
UNI 1
Multicast Unicast 1

Multicast 0
Multicast 1

TK3711

NG

UNI 2

Figure 6: Two links configured to Share the same FIFO


If data from two links is classified into the same downstream FIFO, certain functions in the ONU, such as
statistics gathering will not work as expected. Teknovus strongly recommends against such configurations.

Teknovus FIFO Labeling Convention Review

Teknovus uses a hierarchal labeling convention to denote a particular ONU FIFO. The label contains all
information necessary to uniquely identify any FIFO known to the Element Management Layer.
Decomposed from left to right, each field specifies an entity encompassing the next field. The first field
identifies an ONU or Logical Link. The second field identifies a particular port associated with the
ONU/Link. The last field identifies a queue feeding into that port.

9.1 Upstream
Upstream labels take the form: (M + i).p.q, where:
1.
2.
3.

28

M + i, Specifies the link to which the frames shall be forwarded. M is the base MAC of the ONU,
i is the link index.
p specifies the egress ONU port used for classification. This is always the EPON port 0.
q specifies the ONU queue for classification, associated with the link from 1. Remember that
system queues are not visible to the Host. The Teknovus convention, is to number only the user
FIFOs, starting at 0. Where the 0th queue is the highest priority FIFO.

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

9.2 Downstream
Downstream labels take the form: M.p.q, where:
1.
2.
3.

M specifies the link to which the frames shall be forwarded. M is the base MAC of the ONU, i is
the link index.
p specifies the egress ONU port used for classification. Upstream this is always the EPON port 0.
q specifies the ONU queue for classification, associated with the port from 2. Remember that the
processor queues are not visible to the Host. The Teknovus convention, is to number only the user
FIFOs, starting at 0. Where the 0th queue is the highest priority FIFO

10 Example Configurations
10.1 Teknovus Default
Downstream Data Path

Port 1
CPU

Port 2

EPON 0

CPU

EPON 0
System
EPON 0

User 0

UNI 1

Link 0

Link 0

User 0 [Unicast]

Link 1

Flooding [Multicast]

UNI 1

Multicast 0

Link 1
System
User 0

User 0 [Unicast]

UNI 2

UNI 2

Flooding [Multicast]

TK3711

Upstream Data Path

TK3711

Figure 7: Teknovus Default Configuration


Each user port is served by a single FIFO. At the ingress of the ONU, one unicast link is classified into
each FIFO. Assuming that both links are configured in Simple Bridged, Multicast 0 will be assigned the
IEEE standard broadcast LLID (0x7FFF). Traffic sent by the OLT on this address will be flooded to both
ports. The TK3711 FIFOs are scheduled independently and operate at the line rate of the PON. Therefore
traffic sent to UNI 1 will not inhibit the flow of data to UNI 2, even if the PHYs associated with the two
UNI ports are operating at different line rates. The processor FIFOs are used for management traffic such
as OAM and IGMP.

29

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

10.1.1 Sample Classification Scheme


Received by UNI 1
Rule Level
If
5
Exists ( L2-DA )

Forward to FIFO
(M + 0).0.0

Received by UNI 2
Rule Level
If
5
Exists ( L2-DA )

Forward to FIFO
(M + 1).0.0

Received by EPON 0
Rule Level
If
5
Link Index == 0
5
Link Index == 1

Forward to FIFO
M.1.0
M.2.0

The Exists operator is used to test whether or not the provisioned field is present in the frame. For binary
operators, if the field does not exist the operator will always return false (the notable exception being
TK3701Y L3 EtherType.) However, it is sometimes useful to classify traffic based on the existence of a
field only. For instance Exists ( IPv4-SA ) could be used to classify all IPv4 traffic to a particular ONU
FIFO. By default the ONU drops all traffic with a filter rule of precedence 7. The Exists, clause is used
only to override the default classification rule. All traffic received by port 1 shall be forwarded to link 0
and all packets received by port 2 shall be classified to link 1.

10.2 One UNI, Two Links


Upstream Data Path
CPU

Downstream Data Path

Port 1

EPON 0

EPON 0

System
EPON 0

User 0

CPU

UNI 1

Link 0
Link 1

Link 0

Multicast/Unicast 0
UNI 1
Unicast 1

Multicast 0

Link 1

Multicast 1
System
User 0

TK3711

UNI 2

UNI 2

TK3711

Figure 8: One Port Two-Link

30

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

10.2.1 Sample Classification Scheme


Received by UNI 1
Rule Level
If
4
IPv4 SA == 192.168.1.2
5
Exists ( L2-DA )

Forward to FIFO
(M + 0).0.0
(M + 1).0.0

Received by EPON 0
Rule Level
If
5
Link Index == 0
5
Link Index == 1

Forward to FIFO
M.1.0
M.2.0

In this example if the IPv4 SA == 192.168.1.2, the traffic will be classified into link 1s first user FIFO (0),
else the traffic will be sent to link 2s first user FIFO (0). Notice that in this case Exists ( L2-DA ) == True,
even when IPv4 SA == 192.168.1.2. How is this conflicting classification resolved? Rules with a higher
precedence have a lower Rule Level. If two rules are both true the rule with the higher precedence is used.

31

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

10.3 One UNI, One Link, Four FIFOs


Downstream Data Path

Port 1
CPU

EPON 0

EPON 0

System
EPON 0

User 0

CPU

User 0 [Multcast / Unicast]


User 1 [Unicast]

UNI 1
Link 0

User 1

UNI 1
User 2 [Unicast]

Multicast 0

Link 0
User 2

User 3 [Unicast]

User 3
UNI 2

TK3701

UNI 2

Upstream Data Path

TK3701

Figure 9: One link, Four FIFOs


The diagram above depicts a single link configuration with multiple priority queues. The received data
from the Ethernet port goes to one of four queues that feed a single link. The OLT DBA uses a single
service level agreement (SLA) to schedule the data upstream. Multiple queues allow higher precedence
data to pass lower priority data while the data waits in the ONU. Multiple queues feeding a single LLID
will be serviced in strict priority, with the lowest numbered queue as the highest priority. Splitting the
downstream traffic into multiple queues, or the receive data from the user port into multiple queues requires
classification rules. Classification rules provided from the OLT are used to direct frames based on the layer
2/3/4 header information into the priority queues.

10.3.1 Sample Classification Scheme


Received by UNI 1
Rule Level
If
4
ToS <= 1
5
ToS <= 3
6
ToS <= 5
4
ToS >= 6
6
Not Exists ( ToS )
Received by EPON 0
Rule Level
If
Link Index == 0
4
ToS <= 1
Link Index == 0
5
ToS <= 3
Link Index == 0
6
ToS <= 5
Link Index == 0
4
ToS >= 6
Link Index == 0
6
Not Exists ( ToS )
32

Forward to FIFO
(M + 0).0.0
(M + 0).0.1
(M + 0).0.2
(M + 0).0.3
(M + 0).0.3

Forward to FIFO
M.1.0
M.1.1
M.1.2
M.1.3
M.1.3
7/1/2005

Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

10.4 Two FIFOs per UNI


Downstream Data Path

Port 1
CPU

Port 2

EPON 0

CPU

EPON 0

System

User 0 [Multicast/Unicast]
EPON 0

User 0

UNI 1

Link 0
Link 1

User 1
Link 0

UNI 1
User 1 [Unicast]

Multicast 0

Link 1

Multicast 1
System
User 0 [Multicast/Unicast]
User 0

UNI 2

UNI 2
User 1 [Unicast]

User 1

TK3711

Upstream Data Path

TK3711

Figure 10: Two Links, Multi-UNI, Multi-FIFO

10.4.1 Sample Classification Scheme


Received by UNI 1
Rule Level
If
4
ToS <= 3
5
Exists ( L2-DA )

Forward to FIFO
(M + 0).0.0
(M + 1).0.1

Received by UNI 2
Rule Level
If
4
CoS <= 3
5
CoS >= 4

Forward to FIFO
(M + 1).0.0
(M + 1).0.1

Received by EPON 0
Rule Level
If
Link Index == 0
4
ToS <= 3
5
Link Index == 0
Link Index == 1
4
CoS <= 3
5
Link Index == 1

Forward to FIFO
M.1.0
M.1.1
M.2.0
M.2.1

In this example the ToS field is used to prioritized traffic received on link 0, while the CoS field prioritizes
traffic received on link 1. The classification scheme is symmetrical; both upstream and downstream use the
same fields for the same links. Additional classification or filtering rules could be used to guarantee the
value of the VID used for link 1. Note that every downstream rule contains a clause to qualify the link. If
this clause is omitted many functions of the ONU such as performance metrics will not work as expected.

33

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

10.5 One UNI, Two Links, Two FIFOs per Link


Upstream Data Path
CPU

Downstream Data Path

Port 1

EPON 0

EPON 0

System

CPU

User 0 [Multicast / Unicast]


User 1 [Unicast]

EPON 0

User 0

UNI 1

Link 0
Link 1

User 1
Link 0

Multicast 0

Link 1

Multicast 1

UNI 1
User 2 [Multicast / Unicast]
User 3 [Unicast]

System
User 0

UNI 2

UNI 2

User 1

TK3711

TK3711

Figure 11: One UNI, Two Links, Two FIFOs per Link

10.5.1 Sample Classification Scheme


Received by UNI 1
Rule Level
If
ToS <= 3
4
IPv4-SA == 192.168.100.1
5
IPv4-SA == 192.168.100.1
EtherType != IPv4
4
CoS <= 3
5
EtherType != IPv4
Received by EPON 0
Rule Level
If
Link Index == 0
4
ToS <= 3
5
Link Index == 0
Link Index == 1
4
CoS <= 3
5
Link Index == 1

Forward to FIFO
(M + 0).0.0
(M + 0).0.1
(M + 1).0.0
(M + 1).0.1

Forward to FIFO
M.1.0
M.1.1
M.1.2
M.1.2

The example above classifies traffic with IPv4-SA == 192.168.100.1 into the first link, and non-IP traffic
into the second link. For IP traffic, if any of the lower two ToS bits are set the first FIFO shall be used.
Otherwise traffic is classified into the second FIFO. Non-IP traffic is classified in the same way, except
that the CoS field will be used.
Note: For the TK3701Y rules involving a L3 or higher field select must contain a clause to specify that the
EtherType==0800

34

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

10.6 Asymmetrical Configuration


Downstream Data Path

Upstream
Data Path

EPON 0
CPU

CPU

EPON 0
EPON 0

System

Link 0

User 0
EPON 0
Link 0
Link 1
Link 2

Link 1
UNI 1

System
User 0

User 0 [Multicast / Unicast]

Link 2

User 1 [Multicast / Unicast]

Link 3

User 2 [Multicast / Unicast]

Multicast 0

UNI 1

User 3 [Multicast / Unicast]

Multicast 1

System

Multicast 2

User 0

Link 3

UNI 2

Multicast 3

UNI 2

System

TK3711

User 0

TK3711

Figure 12: Asymmetrical Configuration


Typically an extra level of scheduling within a Logical Link dose not makes a significant difference to
performance. However, such a configuration poses many problems when it comes to picking appropriate
FIFO sizes. For this reason it makes a lot of sense to provision a simpler downstream classification scheme.

10.6.1 Sample Classification Scheme


Received by UNI 1
Rule Level
If
4
ToS <= 1
5
ToS <= 3
5
ToS >= 4
4
ToS >= 6
4
Not Exists ( ToS )

Forward to FIFO
(M + 0).0.0
(M + 1).0.0
(M + 2).0.0
(M + 3).0.0
(M + 3).0.0

Received by EPON 0
Rule Level
If
5
Link Index == 0
5
Link Index == 1
5
Link Index == 2
5
Link Index == 3

Forward to FIFO
M.1.0
M.1.1
M.1.2
M.1.3

In this example frames received upstream are classified by ToS, non-IP frames are classified into the FIFO
associated with Link 3. Downstream frames are classified by Logical Link only.

35

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

11 IGMP Snooping Parameters


The ONU may be configured
to support up to 32 groups
TOTAL. 32 groups per port
maximum. The number of
groups supported is
subtracted from the available
number of user rules.

Downstream Data Path


EPON 0

Block all
IP- Multicast
Allow 239.0.0.1
Allow 239.0.0.5

CPU

EPON 0

User 0 [Multcast / Unicast]

Link 0

User 1 [Unicast]
UNI 1

Multicast 0

User 2 [Uni./IP-Multicast]
User 3 [Unicast]

The ONU is initially


provisioned to drop all IPMulticast traffic. As groups
are joined, the ONU adds
rules to classify the group
address onto the host
provisioned multicast queue.

UNI 2

ONU

Figure 13: IGMP Snooping Function


If IGMP snooping is enabled the queue to be used for IP-Multicast traffic can be specified by the Host
software using the Get/Set IGMP Snooping Parameters Host Interface message. Non-IP multicast traffic
and broadcast traffic is forwarded to FIFO 0.

11.1 L3-to-L2 Binding used by Snooping Function (as per RFC 1112)
32 bits
239.252.0.1

Upper nibble, used to signify


class D, IP Multicast Address
is not needed

5 bits lost in conversion

Convert to
Binary

1110 1111 1111 1100 0000 0000 0000 0001

4 bits

28 bit group ID

1110

1111 1111 1100 0000 0000 0000 0001

Step 1

Step 2
5 bits

23 bits

1111 1

111 1100 0000 0000 0000 0001


Step 3

Append L2 IP Multicast Prefix

25 bit IP-Multicast Prefix

23 bit group ID

0001 0000 0000 0101 1110 0

111 1100 0000 0000 0000 0001


Result

01-00-5e-7C-0-01

Figure 14: L3-to-L2 IP-Multicast Binding


The ONU uses the L3-to-L2 binding specified by the IANA (International Assigned Numbers Authority) to
classify IP Multicast traffic. This binding is based on a mapping between the IP multicast MAC addresses
and the range of MAC address that begins with the address 01-00-5e-00-00-00 and ends with 01-00-5e-7fff-ff. It is never possible, given only an Ethernet address, to work back to the original IP address. This is
36

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

because 5 of the significant bits of the original IP address are not used. The implication is that for any given
Ethernet address there are 32 unique IP addresses that could be specified.

11.2 IP Multicast Addresses Always Forwarded


The IANA has reserved the range 224.0.0.0 through 224.0.0.255 (inclusive), to be used by network
protocols on a local network segment. These addresses are used by routers for various administrative
purposes and will not be blocked by the IGMP snooping function. Since the Teknovus snooping
implementation is not based on the L3 address but the L2 equivalent, these frames will be bridged based on
the equivalent range of L2 addresses:
[01-00-5e-00-00-00, 01-00-5e-00-00-ff]
Some Well Known Reserved Multicast Address
IP Address
Usage
224.0.0.1
All systems on this subnet
224.0.0.2
All routers on this subnet
224.0.0.5
OSPF routers
224.0.0.6
OSPF designated routers
224.0.0.12
DHCP server/relay agent

37

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

12 Q and A
Q: Is there any correspondence between upstream and downstream queue configuration and/or
classification?
A: Every link allocated by the Host MUST have at least one associated FIFO in each direction. (The
resources for upstream and downstream FIFOs are totally separate.) To keeps performance metrics accurate
multiple links should not be classified into the same FIFO downstream.
Q: How does Teknovus high level Host Interface Queue Configuration map into the absolute hardware
indexes?
A: In the upstream direction the ONU will allocate the highest priority queue within each link for system
purposes. The queues with highest indices will also be allocated to system purposes, such as IGMP
snooping. On the TK3711 there are 16 queues, so indices 15 and 14 will be used for system purposes.
System queues are invisible to Host software.
Q: If IGMP snooping is disabled, can system FIFO 15 and/or 14 be used for user data traffic.
A: Yes, however Teknovus recommends that these FIFOs not be used for user data. Future functionality
that requires input from the UNI may be unavailable to hosts that have dedicated the system FIFOs to serve
user traffic.
Q: Wouldnt it be better to use the FIFO at physical index x, for a particular function, rather than the
physical index that Teknovus has chosen?
A: The physical FIFO IDs do not make any difference to the system performance. In future Teknovus
products FIFOs may need to be allocated in particular orderings to achieve prioritization. If physical IDs
were used, the host software would have to provision each flavor of ONU correctly. The Host Interface
layers logical queue labels allow the underlying hardware to change without the need to rewrite host
software.
Q: My service model associates multiple queues on the same link. It seems that flow statistics are
insufficient for debugging the configuration and performance profiling. Do you support ONU FIFO
statistics?
A: Yes, ONU FIFO statistics are supported.
Q: I am using a TK3711 with multiple FIFOs per Link. However, I observed no performance difference
between the multiple FIFO and single FIFO solution. Why is this?
A: In order to make a scheduling decision, the ONU scheduler must be able to examine two FIFOs
simultaneously. If the ONUs view of the data is limited to a single FIFO, a scheduling decision cannot be
made. Cut through design of the ONU means that, frames are typically transmitted as they are received.
Since the TK3711s ingress line rate is exactly matched to the egress, normally frames will never build up
in its priority FIFOs and the ONUs view of the data will be restricted to the single frame that is currently
passing through its buffers. Thus the TK3711 scheduler will have only a small effect as illustrated by the
figure below:
38

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

Rate Limited to PHY

TK3701

Ingress frames are


received at line rate.

Frames are transmitted at


1/10 of the ingress line rate. This
means that data may build up in the
ONU FIFOs allowing the ONU a
chance to schedule the traffic.

4
3 2

UNI 1

5 1

Ingress Pattern

Egress Pattern

7 6 0
100 Mbps
1 Gbps

TK3711

Ingress frames are


received at line rate.

Frames are transmitted at the same rate as the


ingress. This means that only rarely will more than
one packet ever be in the ONU FIFOs at any one
time. An exception would be when the port is flow
controlled.

UNI 1

Ingress Pattern

Egress Pattern
7
1 Gbps

Figure 15: Downstream Scheduling for GbE port typically has only small effect on output data
The figure above represents a snapshot of two identically configured ONUs after receiving the exact same
data pattern. One ONU is a TK3701 with an egress line rate of 100Mbps; the other ONU is a TK3711 with
egress line rate 1000Mbps. For each data path an input and output sequence of frames is displayed.
Numbers within each frame represent the order in which the frames were received (these numbers should
not be misconstrued as time stamps). Notice how the output pattern for the TK3711 appears unchanged
while the output pattern of the TK3701 is prioritized. Unscheduled frames have been omitted for emphasis.
Q: What will happen if downstream classification rules are not provisioned with the Link Index == N, link
qualification rule?
A: Flow statistics will not work correctly. Other ONU functionality may be degraded. Unqualified
downstream rules are NOT allowed.
Q: When will the ONU flooding queue be used?
A: When two links connected to different ports are configured in the same Shared VLAN or Simple
Bridged multicast group. In a future firmware release the TK3711 flooding queues may not be necessary.

39

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath

Technical Note

ONU Data Path Config.


Confidential

Downstream Data Path


EPON 0

Downstream Data Path


CPU

EPON 0

EPON 0
Link 0

CPU

EPON 0
User 0 [Unicast]
UNI 1

Link 1
Multicast 0

Link 0

User 0 [Unicast]

Link 1

Flooding [Multi./Broadcast]

UNI 1

Multicast 0
Flooding [Muti./Broadcast]
User 0 [Unicast]

UNI 2
User 0 [Unicast]

UNI 2

Flooding [Multi./Broadcast]

TK3701

TK3711

Figure 16: Architectural differences between 3701 and 3711


On the TK3701 there is no hardware mechanism to copy a packet into two independent queues; however it
is able to copy data from one queue into two UNI ports. This can change the latency characteristics of the
broadcast traffic. The TK3711 is able to copy data to two queues.
Q: Changing the ONU queue configuration requires that the ONU MUST be reset. Is there a similar
limitation for adding classification and filtering rules?
A: There is no such limitation.

40

7/1/2005
Teknovus Confidential - View Under NDA Only

TN303_SW_OnuDataPath