From patchwork Thu Apr 20 08:02:48 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Leon Romanovsky X-Patchwork-Id: 13218064 X-Patchwork-Delegate: kuba@kernel.org Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id EB72FC77B73 for ; Thu, 20 Apr 2023 08:03:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234019AbjDTIDG (ORCPT ); Thu, 20 Apr 2023 04:03:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38364 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234245AbjDTIDD (ORCPT ); Thu, 20 Apr 2023 04:03:03 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AFB652D5A for ; Thu, 20 Apr 2023 01:03:02 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id F0E8C64147 for ; Thu, 20 Apr 2023 08:03:01 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id DDD32C433D2; Thu, 20 Apr 2023 08:03:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1681977781; bh=aVDk6ixFl8pnaVx8A4coreNuNqeLPPrwiKySjH6MFOA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=p+fM9CLYDj89ht8cEjUnbU0wHra/KQK8cY2U1jHaijRzNrRZTUeVY+yvcwym6T0TB 03oSqYFeI9k1waP6t1TBYYzaQqezID3pJvNCo0l6/78I46Bd6usj2Z9cBb24BW+evS bnTi+5s/FDTVqV7uo13xgzRnOgd7cjYT6bOXNnGvmvYiIcf1djpiJ8YWy66tJVMjcs RgxIWokIMqLRdUm9lKJINQIJhLcla2knFVpwrEbXAVIyGYFjtueVeRRRxwNfu/wCCi 48id/DgeX/3/hcM1yWd01axy4P0Rab6enzIOx3g5kRKyV/HMCpUjjW40Uamj3aIt34 F2iXnD+MKWr/g== From: Leon Romanovsky To: Jakub Kicinski Cc: Leon Romanovsky , Emeel Hakim , Eric Dumazet , netdev@vger.kernel.org, Paolo Abeni , Raed Salem , Saeed Mahameed , Steffen Klassert , Simon Horman Subject: [PATCH net-next 2/5] net/mlx5e: Don't overwrite extack message returned from IPsec SA validator Date: Thu, 20 Apr 2023 11:02:48 +0300 Message-Id: X-Mailer: git-send-email 2.40.0 In-Reply-To: References: MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org X-Patchwork-Delegate: kuba@kernel.org From: Leon Romanovsky Addition of new err_xfrm label caused to error messages be overwritten. Fix it by using proper NL_SET_ERR_MSG_WEAK_MOD macro together with change in a default message. Fixes: aa8bd0c9518c ("net/mlx5e: Support IPsec acquire default SA") Reviewed-by: Raed Salem Signed-off-by: Leon Romanovsky Reviewed-by: Simon Horman --- drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c b/drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c index 5fd609d1120e..1547d8cda133 100644 --- a/drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c +++ b/drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c @@ -712,7 +712,7 @@ static int mlx5e_xfrm_add_state(struct xfrm_state *x, kfree(sa_entry->work); err_xfrm: kfree(sa_entry); - NL_SET_ERR_MSG_MOD(extack, "Device failed to offload this policy"); + NL_SET_ERR_MSG_WEAK_MOD(extack, "Device failed to offload this state"); return err; }