Skip to content

Commit 8bbf740

Browse files
committed
docs(linux): AM64X: Update docs
- Issue Tracker Update containing details of ICSSG firmware related bugs resolved and bugs open. - Adds new PRP feature in What's New section - Adds documentation on PRP offload mode supported by ICSSG Signed-off-by: Himanshu Mittal <[email protected]>
1 parent 0844fa6 commit 8bbf740

File tree

5 files changed

+368
-1
lines changed

5 files changed

+368
-1
lines changed

configs/AM64X/AM64X_linux_toc.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ linux/Foundational_Components/Kernel/Kernel_Drivers/Network/CPSW-TSN-Tuning
5858
linux/Foundational_Components/Kernel/Kernel_Drivers/Network/NETCONF-YANG
5959
linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_PRP_Non_Offload
6060
linux/Foundational_Components/Kernel/Kernel_Drivers/Network/HSR_Offload
61+
linux/Foundational_Components/Kernel/Kernel_Drivers/Network/PRP_Offload
6162
linux/Foundational_Components/Kernel/Kernel_Drivers/SPI
6263
linux/Foundational_Components/Kernel/Kernel_Drivers/PCIe/PCIe_End_Point
6364
linux/Foundational_Components/Kernel/Kernel_Drivers/PCIe/PCIe_Root_Complex

source/devices/AM64X/linux/Release_Specific_Release_Notes.rst

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,9 @@ What's new
5050
- Important Bug Fixes on top of Processor SDK 10.01.10.04 Release
5151
- Review Issue Tracker Section for the new fixes.
5252

53+
- PRP Offload support has been added to ICSSG prueth-driver. Now PRP functionality
54+
can be offloaded to ICSSG hardware, saving CPU cycles.
55+
5356
**Key Release References:**
5457

5558
- RT Kernel : Real-Time Linux Interrupt Latency numbers here - :ref:`RT Interrupt Latencies <RT-linux-performance>`
@@ -193,9 +196,15 @@ Issues Resolved
193196
"EXT_EP-12111","Linux SDK v10.0: TI-added support for W25N01JW SPI NAND breaks other existing Flash support"
194197
"EXT_EP-12051","AM64x: Linux hangs on repetitive probe/removal of gadget zero"
195198
"EXT_EP-12071","sdk-doc: missing SK-AM64B information in CDNS3 USB page"
199+
"EXT_EP-12336","Last 1B of payload missing in forwarding scenario"
196200
"EXT_EP-12337","ICSSG: TAPRIO - Firmware can’t handle base-time which is not a multiple of cycle-time."
197201
"EXT_EP-12338","ICSSG: PA_STATS are not sequenced properly"
198202
"EXT_EP-12339","Switch/MAC/HSR firmware does not drop corrupted packets"
203+
"EXT_EP-12715","Local injection (TX) - Transmission failure due ""TX Pkt not available"""
204+
"EXT_EP-12716","PRU - Task Manager disable during firmware init"
205+
"EXT_EP-12717","Packets reception failure: 10Mbps speed"
206+
"EXT_EP-12718","Non-recoverable TX underflow with Bidirectional traffic in 100M MII mode"
207+
"EXT_EP-12719","Throughput drop: Software buffer pool implementation @1G speed"
199208

200209

201210
Issues Open
@@ -209,5 +218,4 @@ Issues Open
209218
"EXT_EP-12300","ICSSG: Ethernet: Promiscuous mode is always enabled in bridge mode"
210219
"EXT_EP-12075","U-boot gets stuck when DDR size changed to 512 MB"
211220
"EXT_EP-12060","AM64x: Lower core count on variant devices no supported"
212-
"EXT_EP-12336","Last 1B of payload missing in forwarding scenario"
213221

source/images/AM64_PRP_Setup.jpg

132 KB
Loading
Lines changed: 357 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,357 @@
1+
===================
2+
PRP Offload
3+
===================
4+
5+
.. rubric:: **Introduction**
6+
7+
HSR framework in linux supports HSR and PRP modes of redundancy using 2 ports.
8+
It also allows below functionalities of PRP to be offloaded to the device:
9+
10+
- hsr-tag-ins-offload: Add PRP trailer to the frame
11+
- hsr-dup-offload: Duplicate the outgoing PRP frame
12+
- hsr-tag-rm-offload: Remove PRP trailer from the frame
13+
14+
The ICSSG PRP firmware supports offloading of all above functionalities saving overhead from the driver.
15+
16+
.. note::
17+
The offload of functionality hsr-fwd-offload should also be enabled for correct driver configuration.
18+
19+
The below script sets up a PRP interface with all possible offload functionalities enabled
20+
21+
.. code-block:: bash
22+
23+
#!/bin/sh
24+
25+
#For non offload - sh prp_setup.sh prp_sw <INTF_A> <INTF_B> <PRP_INTF_IP_ADDR>
26+
#For offload - sh prp_setup.sh prp_hw <INTF_A> <INTF_B> <PRP_INTF_IP_ADDR>
27+
28+
if [ "$#" != "4" ]
29+
then
30+
echo "$0 <prp_sw/prp_hw> <intf1> <intf2> <ip addr>"
31+
exit
32+
fi
33+
34+
if [ "$1" != "prp_sw" ] && [ "$1" != "prp_hw" ]
35+
then
36+
echo "$0 <prp_sw|prp_hw>"
37+
exit
38+
fi
39+
40+
if=prp0
41+
42+
ifa=$2
43+
ifb=$3
44+
45+
ip=$4
46+
mac=$(ifconfig "$ifa" | grep ether | cut -d " " -f 10)
47+
48+
echo "ip=$ip"
49+
echo "if=$if"
50+
echo "mac=$mac"
51+
echo "slave-a=$ifa"
52+
echo "slave-b=$ifb"
53+
54+
ip link set $if down
55+
ip link delete $if 2> /dev/null
56+
57+
if [ "$1" = "prp_hw" ]
58+
then
59+
echo "Available offload features for $ifa: "
60+
ethtool -k "$ifa" | grep hsr
61+
ethtool -K "$ifa" hsr-fwd-offload on
62+
ethtool -K "$ifa" hsr-dup-offload on
63+
ethtool -K "$ifa" hsr-tag-ins-offload on
64+
ethtool -K "$ifa" hsr-tag-rm-offload on
65+
echo "Enabled offload features for $ifa: "
66+
ethtool -k "$ifa" | grep hsr
67+
68+
echo "Available offload features for $ifb: "
69+
ethtool -k "$ifb" | grep hsr
70+
ethtool -K "$ifb" hsr-fwd-offload on
71+
ethtool -K "$ifb" hsr-dup-offload on
72+
ethtool -K "$ifb" hsr-tag-ins-offload on
73+
ethtool -K "$ifb" hsr-tag-rm-offload on
74+
echo "Enabled offload features for $ifb: "
75+
ethtool -k "$ifb" | grep hsr
76+
fi
77+
78+
ip link set dev "$ifa" address "$mac"
79+
ip link set dev "$ifb" address "$mac"
80+
81+
ip link add name $if type hsr slave1 "$ifa" slave2 "$ifb" supervision 45 proto 1
82+
83+
sleep 3
84+
85+
ip addr add "$ip"/24 dev $if
86+
ip link set $if up
87+
88+
To create PRP interface with IP address 192.168.1.10 using eth1 and eth2,
89+
run the script by passing the arguments as below
90+
91+
.. code-block:: console
92+
93+
sh prp_setup.sh prp_hw eth1 eth2 192.168.1.10
94+
95+
.. rubric:: *Multicast Filtering*
96+
97+
All multi-cast addresses not registered will be filtered out.
98+
99+
.. rubric:: Multicast Add/Delete
100+
101+
Multicast MAC address can be added/deleted using ip maddr commands or Linux socket ioctl SIOCADDMULTI/SIOCDELMULTI.
102+
103+
.. rubric:: Show multicast address
104+
105+
Show current list of multicast address for the PRP interface
106+
107+
.. code-block:: console
108+
109+
ip maddr show dev <prp_intf>
110+
111+
Example:
112+
113+
.. code-block:: console
114+
115+
# ip maddr show dev prp0
116+
7: prp0
117+
link 33:33:00:00:00:01 users 3
118+
link 01:80:c2:00:00:0e users 3 static
119+
link 01:80:c2:00:00:03 users 3 static
120+
link 01:80:c2:00:00:00 users 3 static
121+
link 01:00:5e:00:00:01 users 3
122+
link 33:33:ff:1e:a0:a8 users 3
123+
link 01:00:5e:00:00:fb users 3
124+
link 33:33:00:00:00:fb users 3
125+
inet 224.0.0.251
126+
inet 224.0.0.1
127+
inet6 ff02::fb
128+
inet6 ff02::1:ff1e:a0a8
129+
inet6 ff02::1
130+
inet6 ff01::1
131+
132+
.. rubric:: Add multicast address
133+
134+
Add a multicast address
135+
136+
.. code-block:: console
137+
138+
ip maddr add <multicast_mac_addr> dev <prp_intf>
139+
140+
Example: To add a multicast address and display the list in PRP and slave ports
141+
142+
.. code-block:: console
143+
144+
# ip maddr add 01:80:c4:00:00:0e dev prp0
145+
# ip maddr show dev prp0
146+
7: prp0
147+
link 33:33:00:00:00:01 users 3
148+
link 01:80:c2:00:00:0e users 3 static
149+
link 01:80:c2:00:00:03 users 3 static
150+
link 01:80:c2:00:00:00 users 3 static
151+
link 01:00:5e:00:00:01 users 3
152+
link 33:33:ff:1e:a0:a8 users 3
153+
link 01:00:5e:00:00:fb users 3
154+
link 33:33:00:00:00:fb users 3
155+
link 01:80:c4:00:00:0e users 3 static
156+
inet 224.0.0.251
157+
inet 224.0.0.1
158+
inet6 ff02::fb
159+
inet6 ff02::1:ff1e:a0a8
160+
inet6 ff02::1
161+
inet6 ff01::1
162+
163+
# ip maddr show dev eth1
164+
5: eth1
165+
link 33:33:00:00:00:01 users 3
166+
link 01:00:5e:00:00:01 users 3
167+
link 01:80:c2:00:00:0e users 4 static
168+
link 01:80:c2:00:00:03 users 4 static
169+
link 01:80:c2:00:00:00 users 4 static
170+
link 33:33:ff:1e:a0:a8 users 3
171+
link 33:33:00:00:00:fb users 3
172+
link 01:00:5e:00:00:fb users 2
173+
link 01:80:c4:00:00:0e users 2
174+
inet 224.0.0.1
175+
inet6 ff02::fb
176+
inet6 ff02::1:ff1e:a0a8
177+
inet6 ff02::1 users 2
178+
inet6 ff01::1
179+
180+
# ip maddr show dev eth2
181+
6: eth2
182+
link 33:33:00:00:00:01 users 3
183+
link 01:00:5e:00:00:01 users 3
184+
link 01:80:c2:00:00:0e users 4 static
185+
link 01:80:c2:00:00:03 users 4 static
186+
link 01:80:c2:00:00:00 users 4 static
187+
link 33:33:ff:1e:a0:a7 users 2
188+
link 33:33:00:00:00:fb users 3
189+
link 33:33:ff:1e:a0:a8 users 2
190+
link 01:00:5e:00:00:fb users 2
191+
link 01:80:c4:00:00:0e users 2
192+
inet 224.0.0.1
193+
inet6 ff02::fb
194+
inet6 ff02::1:ff1e:a0a7
195+
inet6 ff02::1 users 2
196+
inet6 ff01::1
197+
198+
.. rubric:: Delete multicast address
199+
200+
Delete a multicast address
201+
202+
.. code-block:: console
203+
204+
ip maddr del <multicast_mac_addr> dev <prp_intf>
205+
206+
Example: To delete an added multicast address and dislay the list of PRP and
207+
slave intefaces.
208+
209+
.. code-block:: console
210+
211+
# ip maddr del 01:80:c4:00:00:0e dev prp0
212+
# ip maddr show dev prp0
213+
7: prp0
214+
link 33:33:00:00:00:01 users 3
215+
link 01:80:c2:00:00:0e users 3 static
216+
link 01:80:c2:00:00:03 users 3 static
217+
link 01:80:c2:00:00:00 users 3 static
218+
link 01:00:5e:00:00:01 users 3
219+
link 33:33:ff:1e:a0:a8 users 3
220+
link 01:00:5e:00:00:fb users 3
221+
link 33:33:00:00:00:fb users 3
222+
inet 224.0.0.251
223+
inet 224.0.0.1
224+
inet6 ff02::fb
225+
inet6 ff02::1:ff1e:a0a8
226+
inet6 ff02::1
227+
inet6 ff01::1
228+
229+
# ip maddr show dev eth1
230+
5: eth1
231+
link 33:33:00:00:00:01 users 3
232+
link 01:00:5e:00:00:01 users 3
233+
link 01:80:c2:00:00:0e users 4 static
234+
link 01:80:c2:00:00:03 users 4 static
235+
link 01:80:c2:00:00:00 users 4 static
236+
link 33:33:ff:1e:a0:a8 users 3
237+
link 33:33:00:00:00:fb users 3
238+
link 01:00:5e:00:00:fb users 2
239+
inet 224.0.0.1
240+
inet6 ff02::fb
241+
inet6 ff02::1:ff1e:a0a8
242+
inet6 ff02::1 users 2
243+
inet6 ff01::1
244+
245+
# ip maddr show dev eth2
246+
6: eth2
247+
link 33:33:00:00:00:01 users 3
248+
link 01:00:5e:00:00:01 users 3
249+
link 01:80:c2:00:00:0e users 4 static
250+
link 01:80:c2:00:00:03 users 4 static
251+
link 01:80:c2:00:00:00 users 4 static
252+
link 33:33:ff:1e:a0:a7 users 2
253+
link 33:33:00:00:00:fb users 3
254+
link 33:33:ff:1e:a0:a8 users 2
255+
link 01:00:5e:00:00:fb users 2
256+
inet 224.0.0.1
257+
inet6 ff02::fb
258+
inet6 ff02::1:ff1e:a0a7
259+
inet6 ff02::1 users 2
260+
inet6 ff01::1
261+
262+
.. rubric:: *Multicast Filtering for VLAN Interfaces*
263+
264+
Multicast filtering for VLAN interfaces is also supported.
265+
266+
Show current list of multicast address for the PRP VLAN interface
267+
268+
.. code-block:: console
269+
270+
ip maddr show dev <prp_vlan_intf>
271+
272+
Example:
273+
274+
.. code-block:: console
275+
276+
# ip maddr show dev prp0.5
277+
278+
Add multicast address for the PRP VLAN interface
279+
280+
.. code-block:: console
281+
282+
ip maddr add <multicast_mac_addr> dev <prp_vlan_intf>
283+
284+
Example:
285+
286+
.. code-block:: console
287+
288+
# ip maddr add 01:80:c4:00:00:0e dev prp0.5
289+
290+
Delete multicast address for the PRP VLAN interface
291+
292+
.. code-block:: console
293+
294+
ip maddr del <multicast_mac_addr> dev <prp_vlan_intf>
295+
296+
Example:
297+
298+
.. code-block:: console
299+
300+
# ip maddr del 01:80:c4:00:00:0e dev prp0.5
301+
302+
.. rubric:: Performance
303+
304+
This section describes the throughput and CPU usage metrics in the offload case
305+
306+
.. rubric:: Setup
307+
308+
A sample test setup is as shown below
309+
310+
.. Image:: /images/AM64_PRP_Setup.jpg
311+
:width: 400
312+
313+
.. rubric:: Test Procedure
314+
315+
#. Connect the LAN cables between the DANP DUTs as shown in the setup image
316+
317+
#. Execute the commands to setup and create PRP interface
318+
319+
.. code-block:: console
320+
321+
sh prp_setup.sh prp_hw <INTF_A> <INTF_B> <PRP_INTF_IP_ADDR>
322+
323+
#. Confirm ping across all Nodes
324+
325+
a. Node A < - - > Node B
326+
b. Node B < - - > Node C
327+
c. Node C < - - > Node A
328+
329+
#. Disconnect one of the cable for a node and retry
330+
331+
#. Monitor the CPU usage on DUTs
332+
333+
.. code-block:: console
334+
335+
mpstat -P ALL 1
336+
337+
#. Run iperf3 server on Node C
338+
339+
.. code-block:: console
340+
341+
iperf3 -s
342+
343+
#. Run iperf3 client on Node A for 60 secs
344+
345+
.. code-block:: console
346+
347+
iperf3 -c -t60 <Node_C_IP_Addr>
348+
349+
.. rubric:: Throughput at Node A
350+
351+
.. list-table:: Throughput performance
352+
:widths: 25 25
353+
354+
* - Sender
355+
- Receiver
356+
* - 610 Mbits/sec
357+
- 605 Mbits/sec

0 commit comments

Comments
 (0)