From patchwork Thu Sep 2 19:05:44 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Saeed Mahameed X-Patchwork-Id: 506973 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-19.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1633FC433F5 for ; Thu, 2 Sep 2021 19:06:16 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id E54A26056B for ; Thu, 2 Sep 2021 19:06:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1347351AbhIBTHN (ORCPT ); Thu, 2 Sep 2021 15:07:13 -0400 Received: from mail.kernel.org ([198.145.29.99]:55058 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1347310AbhIBTHF (ORCPT ); Thu, 2 Sep 2021 15:07:05 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 7710D610C8; Thu, 2 Sep 2021 19:06:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1630609566; bh=d5ZqYaJG4nHoFIQFDHDv9wUBFTekpdzrqPG2AEeTWPw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=RelxqEZWiR8wWbK5a1Z0ypCdQ9rFxOEEDBKBCimHRVsr1UG6sJ4VVCwoEbSWRR0Oi y1+05dbEHhE5HkvTWp6hlwqhylWu0JIwIOdg8Jl3g9uLOe2NFBHHawWy4ttXeWFP0n B6mhvEVRR5UKtYwwtGylDmO0XEj9fHDyKWZ0HwVDEUXDOGE8d0QWG3SwV40pu1YEgU WiHCIcHLpXUX4BNqPALvUX1h8sLlMjwytly8OtrJ/uG1ASzNFxXwGPRpDw98RpDFXa sHhFCaHk1JpN0bFVWszZAoW+sCgDSFSwlsLNQisOvqPvJkmgjULhd34RD007Vuw3qJ yqEZph1yCyntg== From: Saeed Mahameed To: "David S. Miller" , Jakub Kicinski Cc: netdev@vger.kernel.org, Roi Dayan , Maor Dickman , Saeed Mahameed Subject: [net-next 05/15] net/mlx5e: Remove incorrect addition of action fwd flag Date: Thu, 2 Sep 2021 12:05:44 -0700 Message-Id: <20210902190554.211497-6-saeed@kernel.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210902190554.211497-1-saeed@kernel.org> References: <20210902190554.211497-1-saeed@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org From: Roi Dayan A user is expected to explicit request a fwd or drop action. It is not correct to implicit add a fwd action for the user, when modify header action flag exists. Signed-off-by: Roi Dayan Reviewed-by: Maor Dickman Signed-off-by: Saeed Mahameed --- drivers/net/ethernet/mellanox/mlx5/core/en_tc.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_tc.c b/drivers/net/ethernet/mellanox/mlx5/core/en_tc.c index f55fc8553664..d68c67b98d94 100644 --- a/drivers/net/ethernet/mellanox/mlx5/core/en_tc.c +++ b/drivers/net/ethernet/mellanox/mlx5/core/en_tc.c @@ -3491,9 +3491,6 @@ static int parse_tc_nic_actions(struct mlx5e_priv *priv, attr->action |= MLX5_FLOW_CONTEXT_ACTION_FWD_DEST; } - if (attr->action & MLX5_FLOW_CONTEXT_ACTION_MOD_HDR) - attr->action |= MLX5_FLOW_CONTEXT_ACTION_FWD_DEST; - if (!actions_match_supported(priv, flow_action, parse_attr, flow, extack)) return -EOPNOTSUPP;