]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
i40e: flower: validate control flags
authorAsbjørn Sloth Tønnesen <ast@fiberby.net>
Tue, 16 Apr 2024 14:43:19 +0000 (14:43 +0000)
committerTony Nguyen <anthony.l.nguyen@intel.com>
Wed, 8 May 2024 16:12:09 +0000 (09:12 -0700)
commit174ee5bcfeb7a194b107a8e1a6fa9a1b98de399a
treee86eb998bda9ee4db8fc68cb113c6b591b16a27f
parent252aa6d53931381bd774acd06866ed0fb1976ead
i40e: flower: validate control flags

This driver currently doesn't support any control flags.

Use flow_rule_has_control_flags() to check for control flags,
such as can be set through `tc flower ... ip_flags frag`.

In case any control flags are masked, flow_rule_has_control_flags()
sets a NL extended error message, and we return -EOPNOTSUPP.

Only compile-tested.

Signed-off-by: Asbjørn Sloth Tønnesen <ast@fiberby.net>
Reviewed-by: Simon Horman <horms@kernel.org>
Tested-by: Sujai Buvaneswaran <sujai.buvaneswaran@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
drivers/net/ethernet/intel/i40e/i40e_main.c