]> git.baikalelectronics.ru Git - kernel.git/commit
ice: ignore protocol field in GTP offload
authorMarcin Szycik <marcin.szycik@linux.intel.com>
Mon, 9 May 2022 19:01:18 +0000 (21:01 +0200)
committerTony Nguyen <anthony.l.nguyen@intel.com>
Tue, 21 Jun 2022 18:14:36 +0000 (11:14 -0700)
commit0343e10927c115364f260f39e50383ef0a8af00e
tree4903ecb6825561615b0ceb06b69d357a0942a39e
parent4bf37baec807c1fa0377c26f495f04cb90ff8822
ice: ignore protocol field in GTP offload

Commit e70157e27c56 ("ice: Add support for inner etype in switchdev")
added the ability to match on inner ethertype. A side effect of that change
is that it is now impossible to add some filters for protocols which do not
contain inner ethtype field. tc requires the protocol field to be specified
when providing certain other options, e.g. src_ip. This is a problem in
case of GTP - when user wants to specify e.g. src_ip, they also need to
specify protocol in tc command (otherwise tc fails with: Illegal "src_ip").
Because GTP is a tunnel, the protocol field is treated as inner protocol.
GTP does not contain inner ethtype field and the filter cannot be added.

To fix this, ignore the ethertype field in case of GTP filters.

Fixes: a30bca62517b ("ice: Support GTP-U and GTP-C offload in switchdev")
Signed-off-by: Marcin Szycik <marcin.szycik@linux.intel.com>
Tested-by: Sandeep Penigalapati <sandeep.penigalapati@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
drivers/net/ethernet/intel/ice/ice_tc_lib.c