From mboxrd@z Thu Jan 1 00:00:00 1970 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 553B6C001DE for ; Tue, 8 Aug 2023 16:43:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233255AbjHHQn6 (ORCPT ); Tue, 8 Aug 2023 12:43:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58636 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233256AbjHHQnD (ORCPT ); Tue, 8 Aug 2023 12:43: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 66F8A1657E for ; Tue, 8 Aug 2023 08:55:32 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 75AE16259C for ; Tue, 8 Aug 2023 15:18:09 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 637C7C433C7; Tue, 8 Aug 2023 15:18:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1691507888; bh=HCIa94Zv6SIWWoG/MsBuHuvS7X4QM3uRoNVny9Wk6QQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=C2PYGOMMq1T1P10Tw+P0qnKvFHY5k8+n/73jijKBGi/UqEf3ZiJfA7eUXoLmOsrj1 yBEUCFG3n75E+sCS5+BwBGpqrQe6MprzxhqPGrcmE2Yf1RtZ7HBYRtv4MmCwkW+TVy cqb+TcpGywq/DbD54rpLYcNO3vpoMh59Y7HRlchVRT2fpLB5b/b4uhC0ukG33zxrsQ IuEuVhsP+rb8rfaHQSi9+4N2WVfSEbO9oPJjZSdLbGgX/V8fQQaePk2njuV+tQZiLQ 2jV3YZcw69xtcOey7jgc8wB0pgB0H28ekvpV5p9wXNb+ygU2aUsdlTu7xZkF+qLXLB mrKph9gxknk6w== Date: Tue, 8 Aug 2023 17:18:03 +0200 From: Simon Horman To: Leon Romanovsky Cc: Jason Gunthorpe , Jakub Kicinski , Patrisious Haddad , "David S . Miller" , Eric Dumazet , linux-rdma@vger.kernel.org, Maor Gottlieb , Mark Zhang , netdev@vger.kernel.org, Paolo Abeni , Raed Salem , Saeed Mahameed Subject: Re: [PATCH mlx5-next 09/14] net/mlx5: Configure MACsec steering for egress RoCEv2 traffic Message-ID: References: <4e114bd19fe2cd8732c0efffa2f0f90d1dc5ec44.1691403485.git.leon@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4e114bd19fe2cd8732c0efffa2f0f90d1dc5ec44.1691403485.git.leon@kernel.org> Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org On Mon, Aug 07, 2023 at 01:44:18PM +0300, Leon Romanovsky wrote: > From: Patrisious Haddad > > Add steering table in RDMA_TX domain, to forward MACsec traffic > to MACsec crypto table in NIC domain. > The tables are created in a lazy manner when the first TX SA is > being created, and destroyed upon the destruction of the last SA. > > Signed-off-by: Patrisious Haddad > Signed-off-by: Leon Romanovsky > --- > .../mellanox/mlx5/core/lib/macsec_fs.c | 46 ++++++++++++++++++- > 1 file changed, 45 insertions(+), 1 deletion(-) > > diff --git a/drivers/net/ethernet/mellanox/mlx5/core/lib/macsec_fs.c b/drivers/net/ethernet/mellanox/mlx5/core/lib/macsec_fs.c > index d39ca7c66542..15e7ea3ed79f 100644 > --- a/drivers/net/ethernet/mellanox/mlx5/core/lib/macsec_fs.c > +++ b/drivers/net/ethernet/mellanox/mlx5/core/lib/macsec_fs.c > @@ -95,6 +95,8 @@ struct mlx5_macsec_tx { > struct ida tx_halloc; > > struct mlx5_macsec_tables tables; > + > + struct mlx5_flow_table *ft_rdma_tx; > }; > > struct mlx5_macsec_rx_rule { > @@ -173,6 +175,9 @@ static void macsec_fs_tx_destroy(struct mlx5_macsec_fs *macsec_fs) > struct mlx5_macsec_tx *tx_fs = macsec_fs->tx_fs; > struct mlx5_macsec_tables *tx_tables; > > + if (mlx5_is_macsec_roce_supported(macsec_fs->mdev)) > + mlx5_destroy_flow_table(tx_fs->ft_rdma_tx); Hi Patrisious and Leon, mlx5_is_macsec_roce_supported() is used here, but it doesn't seem to be added until a later in this series. ...