Skip to content

Commit

Permalink
ethdev: update flow item GTP QFI definition
Browse files Browse the repository at this point in the history
[ upstream commit 7d96f57 ]

'qfi' field is 8 bits which represent single bit for
PPP (paging Policy Presence) single bit for RQI
(Reflective QoS Indicator) and 6 bits for QFI
(QoS Flow Identifier)
This is based on RFC 38415-g30
https://www.3gpp.org/ftp/Specs/archive/38_series/38.415/38415-g30.zip

Updated the doxygen comment and the mask for 'qfi'
to properly identify the full 8 bits of the field.

note: changing the default mask would cause different
patterns generated by testpmd.

Fixes: 346553d ("ethdev: add GTP extension header to flow API")

Signed-off-by: Raslan Darawsheh <rasland@nvidia.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
  • Loading branch information
raslandarawsheh authored and steevenlee committed May 8, 2021
1 parent 42c05be commit 5ecc163
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion doc/guides/testpmd_app_ug/testpmd_funcs.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3729,7 +3729,8 @@ This section lists supported pattern items and their attributes, if any.
- ``gtp_psc``: match GTP PDU extension header with type 0x85.

- ``pdu_type {unsigned}``: PDU type.
- ``qfi {unsigned}``: QoS flow identifier.

- ``qfi {unsigned}``: PPP, RQI and QoS flow identifier.

- ``pppoes``, ``pppoed``: match PPPoE header.

Expand Down
4 changes: 2 additions & 2 deletions lib/librte_ethdev/rte_flow.h
Original file line number Diff line number Diff line change
Expand Up @@ -1385,14 +1385,14 @@ static const struct rte_flow_item_meta rte_flow_item_meta_mask = {
*/
struct rte_flow_item_gtp_psc {
uint8_t pdu_type; /**< PDU type. */
uint8_t qfi; /**< QoS flow identifier. */
uint8_t qfi; /**< PPP, RQI, QoS flow identifier. */
};

/** Default mask for RTE_FLOW_ITEM_TYPE_GTP_PSC. */
#ifndef __cplusplus
static const struct rte_flow_item_gtp_psc
rte_flow_item_gtp_psc_mask = {
.qfi = 0x3f,
.qfi = 0xff,
};
#endif

Expand Down

0 comments on commit 5ecc163

Please sign in to comment.