]> git.baikalelectronics.ru Git - kernel.git/commit
net/sched: Allow flower to match on GTP options
authorWojciech Drewek <wojciech.drewek@intel.com>
Fri, 4 Mar 2022 16:40:45 +0000 (17:40 +0100)
committerTony Nguyen <anthony.l.nguyen@intel.com>
Fri, 11 Mar 2022 16:28:27 +0000 (08:28 -0800)
commite42e8450b63f4fb3e78cb4ce0f94266708b1af75
tree5594653411b5cd18f68525d89d3043b56839a312
parent2c2148197cfc0a4ff039ac69dcc25ba81ebf8ab7
net/sched: Allow flower to match on GTP options

Options are as follows: PDU_TYPE:QFI and they refernce to
the fields from the  PDU Session Protocol. PDU Session data
is conveyed in GTP-U Extension Header.

GTP-U Extension Header is described in 3GPP TS 29.281.
PDU Session Protocol is described in 3GPP TS 38.415.

PDU_TYPE -  indicates the type of the PDU Session Information (4 bits)
QFI      -  QoS Flow Identifier (6 bits)

  # ip link add gtp_dev type gtp role sgsn
  # tc qdisc add dev gtp_dev ingress
  # tc filter add dev gtp_dev protocol ip parent ffff: \
      flower \
        enc_key_id 11 \
        gtp_opts 1:8/ff:ff \
      action mirred egress redirect dev eth0

Signed-off-by: Wojciech Drewek <wojciech.drewek@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
include/net/gtp.h
include/uapi/linux/if_tunnel.h
include/uapi/linux/pkt_cls.h
net/sched/cls_flower.c