* [dpdk-dev] [RFC] net/mlx5: support match on IPv4 and IPv6 fragment fields
[not found] <AM4PR05MB346043CD1A77B2204BB92A2AB6F70@AM4PR05MB3460.eurprd05.prod.outlook.com>
@ 2020-03-18 16:50 ` Dekel Peled
0 siblings, 0 replies; only message in thread
From: Dekel Peled @ 2020-03-18 16:50 UTC (permalink / raw)
To: Matan Azrad, Slava Ovsiienko; +Cc: Ori Kam, Asaf Penso, Eli Britstein, dev
In order to send a packet that is larger than the path MTU<https://en.wikipedia.org/wiki/Maximum_transmission_unit>, the sending node splits the packet into fragments.
IPv4 Flags and Fragment Offset header fields , and IPv6 fragment extension header fields, contain the required
Information to indicate that a packet is a fragment of a large, fragmented packet.
They also indicate the fragment packet location in the fragmented packet (first, last or other), and the offset of
this fragment in the fragmented packet.
In IPv4 header, the relevant fields are:
1. Flags.MF (More Fragments):
Set if More fragments follow..
2. Fragment Offset (13 bits):
Offset of fragment, in 8-bytes blocks, from the beginning of the original packet data.
In IPv6 header of fragmented packet, a Fragment extension header is present, identified by Next Header value of 44.
This extension header includes:
1. M flag, with the same function as IPv4 MF flag.
2. Fragment Offset, same as IPv4 Fragment Offset.
The following table shows the expected values of these fields.
Packet type
M/MF flag
Fragment Offset
Unfragmented packet
0
0
Fragmented packet, first fragment
1
0
Fragmented packet, following fragments
1
Larger than 0
Fragmented packet, last fragment
0
Larger than 0
This RFC introduces, in MLX5 PMD, the support of matching on the header fields mentioned above.
The matching on M/MF flag, and Fragment Offset=0, is plain and straight forward.
The matching on Fragment Offset > 0 will be specified by range from item.spec=1 to maximal value item.last=(2^13-1).
Following rte_flow update [1], IPv6 item validation and translation will be enhanced, to check the Next Header field,
and look for the fragment extension header to process.
Testpmd code will be updated to support the use of added items and fields.
The command line option to match on IPv6 fragment extension item and it's fields will be added.
[1] http://patches.dpdk.org/patch/66849/
Signed-off-by: Dekel Peled <dekelp@mellanox.com<mailto:dekelp@mellanox.com>>
^ permalink raw reply [flat|nested] only message in thread