summaryrefslogtreecommitdiff
path: root/drivers/net
diff options
context:
space:
mode:
authorAya Levin <ayal@nvidia.com>2021-09-23 09:51:45 +0300
committerDavid S. Miller <davem@davemloft.net>2021-09-23 15:17:39 +0300
commitfdbccea419dc782079ce5881d2705cc9e3881480 (patch)
tree40f472d0d7a73af1ff2fb26256777ae270eb894c /drivers/net
parentacc64f52afac15e9e44d9b5253271346841786e0 (diff)
downloadlinux-fdbccea419dc782079ce5881d2705cc9e3881480.tar.xz
net/mlx4_en: Don't allow aRFS for encapsulated packets
Driver doesn't support aRFS for encapsulated packets, return early error in such a case. Fixes: 1eb8c695bda9 ("net/mlx4_en: Add accelerated RFS support") Signed-off-by: Aya Levin <ayal@nvidia.com> Signed-off-by: Tariq Toukan <tariqt@nvidia.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/ethernet/mellanox/mlx4/en_netdev.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx4/en_netdev.c b/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
index 35154635ec3a..8af7f2827322 100644
--- a/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
+++ b/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
@@ -372,6 +372,9 @@ mlx4_en_filter_rfs(struct net_device *net_dev, const struct sk_buff *skb,
int nhoff = skb_network_offset(skb);
int ret = 0;
+ if (skb->encapsulation)
+ return -EPROTONOSUPPORT;
+
if (skb->protocol != htons(ETH_P_IP))
return -EPROTONOSUPPORT;