Skip to contentSkip to conversation

i40e: flower: Fix return value for unsupported offload

PATCH New Jiri Pirko 2 participants 2 messages Dec 22, 2017 – Jan 2, 2018

Subsystems (3)
lore
Share & tools
lore

Jiri Pirko

author
#0 lore raw

PATCH 1/1 i40e: flower: Fix return value for unsupported offload

From: Jiri Pirko <[email protected]>

When filter configuration is not supported, drivers should return -EOPNOTSUPP so the core can react correctly.

Fixes 2f4b411a3d67 ("i40e: Enable cloud filters via tc-flower")
---
 drivers/net/ethernet/intel/i40e/i40e_main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/intel/i40e/i40e_main.c +1 -1
index 321d8be..9da2069 100644
@@ -7356,7 +7356,7 @@ static int i40e_configure_clsflower(struct i40e_vsi *vsi,
 
 	if (tc < 0) {
 		dev_err(&vsi->back->pdev->dev, "Invalid traffic class\n");
-		return -EINVAL;
+		return -EOPNOTSUPP;
 	}
 
 	if (test_bit(__I40E_RESET_RECOVERY_PENDING, pf->state) ||
Signature · 1 line
2.9.5
#1 lore raw

PATCH 1/1 i40e: flower: Fix return value for unsupported offload

Quoted 12 lines

-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at osuosl.org] On Behalf Of Jiri Pirko
Sent: Friday, December 22, 2017 3:45 AM
To: netdev at vger.kernel.org
Cc: mlxsw at mellanox.com; jhs at mojatatu.com; intel-wired-
lan at lists.osuosl.org; xiyou.wangcong at gmail.com; davem at davemloft.net
Subject: [Intel-wired-lan] [patch net] i40e: flower: Fix return value for unsupported offload

From: Jiri Pirko <[email protected]>

Quoted 8 lines

When filter configuration is not supported, drivers should return - EOPNOTSUPP so the core can react correctly.

Fixes 2f4b411a3d67 ("i40e: Enable cloud filters via tc-flower")
---
 drivers/net/ethernet/intel/i40e/i40e_main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)