From patchwork Tue Apr 23 18:13:05 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rahul Rameshbabu X-Patchwork-Id: 13640530 X-Patchwork-Delegate: kuba@kernel.org Received: from NAM10-DM6-obe.outbound.protection.outlook.com (mail-dm6nam10on2058.outbound.protection.outlook.com [40.107.93.58]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 769B9140361; Tue, 23 Apr 2024 18:13:34 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.93.58 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713896015; cv=fail; b=Fn74+nTFYRHVGQ8FLB6R7z5mOHJsrhDjPV6DU3R3+aiDTmOtqURsg0Q8s9GE6Kiq1L7gJkvnLOaanoIv1RibFL1aYnblAdBrn1JkK/w8WIg6j5AsEboQUV+iV3KUZA6/X5Zv+yI9DWiVq5WMExX6PzHvGmQp++RCdgexpwsySog= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713896015; c=relaxed/simple; bh=wlNxrNZT6VtVgr+St5xHk9CM9YwyQIld5BZC051NgzY=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: Content-Type:MIME-Version; b=LW1LjNY6Vct6dslJR0ihNtwOG4JMEizQp90Hk1eKCb19EZPsln9sg21DuqHMwvtDytzgdihTl/l+JSSwlGcDAz9Mx4uNKWPpqnO/OcMnqQsz27n2XHdy+/5Th9WLueu+engKe/go5uTatSHUUo/kYaIYFSGEMZh8bzCR6vNARMU= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=nvidia.com; spf=fail smtp.mailfrom=nvidia.com; dkim=pass (2048-bit key) header.d=Nvidia.com header.i=@Nvidia.com header.b=ZZ+IPijC; arc=fail smtp.client-ip=40.107.93.58 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=nvidia.com Authentication-Results: smtp.subspace.kernel.org; spf=fail smtp.mailfrom=nvidia.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=Nvidia.com header.i=@Nvidia.com header.b="ZZ+IPijC" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=PIme1XC0EjHtVYFcQZDKyorpD0XNNe8B0PwaETGFBuOBGZ/UssZS00U3vJFsouWdFLqmh6u7mYUNT8GQdtYTocEpLUAoPXBGbRy4ID2CqKNVDHGUjLYtJSHbirTk6Qa5LE1W0GthpvLCqY+oLssc2Kx2O9q3UUcniSj49VuEhHcltt9CsVG1UwNxnk+PJCfk4TXcPujZp+ufD+JhmP7Xj0CP5iQRVVgwt9DjpqTNg0bGUYIsgt8TSO8DTYzjZHcxQwFpAfXnVpcN/kMaCeQgIGufaQ2+YwfKWpS5B36PPV+MS+CWsTyMYymfGspCqOGAmOmVpdtYfiGrRcVu0056ng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=eCTQ4Tq6NI7rX1L0FMlB2I4qV4lqKOSFAGQSBwlW6oQ=; b=Tbt0mvSFn46u6sMDQyCdy/hCjw7elrW1oV6dNNgNwID2n73ggv+02cuRx6q0G0j4q8wULz4YLHdKTyzmX13mrgh9E91WclyTuVj0qOakhhhl1rEoT+8udg6hdDFCv+EhYmk6HrvBEKyiSyIR80tZP/csJvK7z0wugv/YrMm+pVi/HS/b0qDdHQv9KqQRHS/HYhwNtXS+ABQUb7lfFWzqtTmbJ3CWqKGBVwikE4hEPCwxiQhLnW8VcVbjr5RHGSMbMhX4QK8i7gQrQugy1599jaJzq/siXnpTgNFTXJBzTxjeECe11TfvRDsdIlgEjI8IatJ+XQvfb6ohIokQx2Kfaw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nvidia.com; dmarc=pass action=none header.from=nvidia.com; dkim=pass header.d=nvidia.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=eCTQ4Tq6NI7rX1L0FMlB2I4qV4lqKOSFAGQSBwlW6oQ=; b=ZZ+IPijCH5yVh6qud+3fLAOiT2fL8+XLqHJFUUFQCchMRVdGkfRLA/GjhrVMbJci6rQ9z5OUruRX/7zdztFaywwCdtNTVSc+i7fZWFN6Qgm0L2OV8L//Cs+t2EaqIQLves8VaQWnff0wYT3nJbxFsK6dMolfZZ5/OfBrVwugjISf0JxWfqtsdoREoGv55EybNgnn6z5S2QQRaG9IFOeY+SVBsnyjevXT2iOOsVNNg7pTxwLAqqhGfVZSMR/B2i63Mef8P5zxYaWPTFp798QKOgfWS8CKVOnK4N6P7cJIWj3p4Ig5jhVxktNk9GMfNO+yr5qqm4to7vrHjACs3Z4rwA== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nvidia.com; Received: from BYAPR12MB2743.namprd12.prod.outlook.com (2603:10b6:a03:61::28) by SA1PR12MB6799.namprd12.prod.outlook.com (2603:10b6:806:25b::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7472.44; Tue, 23 Apr 2024 18:13:27 +0000 Received: from BYAPR12MB2743.namprd12.prod.outlook.com ([fe80::3ec0:1215:f4ed:9535]) by BYAPR12MB2743.namprd12.prod.outlook.com ([fe80::3ec0:1215:f4ed:9535%4]) with mapi id 15.20.7472.044; Tue, 23 Apr 2024 18:13:27 +0000 From: Rahul Rameshbabu To: netdev@vger.kernel.org, stable@vger.kernel.org Cc: Jakub Kicinski , Eric Dumazet , "David S. Miller" , Paolo Abeni , Gal Pressman , Tariq Toukan , Sabrina Dubroca , Yossi Kuperman , Benjamin Poirier , Cosmin Ratiu , Rahul Rameshbabu Subject: [PATCH net v3 4/4] net/mlx5e: Advertise mlx5 ethernet driver updates sk_buff md_dst for MACsec Date: Tue, 23 Apr 2024 11:13:05 -0700 Message-ID: <20240423181319.115860-5-rrameshbabu@nvidia.com> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20240423181319.115860-1-rrameshbabu@nvidia.com> References: <20240423181319.115860-1-rrameshbabu@nvidia.com> X-ClientProxiedBy: BYAPR21CA0030.namprd21.prod.outlook.com (2603:10b6:a03:114::40) To BYAPR12MB2743.namprd12.prod.outlook.com (2603:10b6:a03:61::28) Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BYAPR12MB2743:EE_|SA1PR12MB6799:EE_ X-MS-Office365-Filtering-Correlation-Id: 160aedb0-501c-432e-f329-08dc63c112cc X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 1WZBjjx34CR5DzcHSNmoduRNdc7BwSfIeX2BqUfUCfKhadf8qXB9xn7VSI1ZUO7lGVx1WFkRWqbKmgJ36mliOhfnLnPFSXgclj31TPgm44WgZpWTf/7VmL63ij6N0z9lZ6roLZmL0T/zD0zmE6C9jaMoApXXd2If6iw4bjGsrwihbLBFu+3jO9FR4FXSfTicnRcWl4cvuvjd8JEGdWo4NnXrf3j3Yq/Lx2Q3GWWXCcAL+Ahla/vDj0444WCwKM07/AKbHirjWLcPjKbsVt0zLldsIwhX6ZSSg1yujeNeRt9+ssH0f3SO/x2ETfqZupxEtBKSkjB2RGtnWZBHXJ3boGvK4e0Th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69yMKH6jmtGeKMjTIL4M7JRb4dx1+VEZvd7WOef+pOJXBz5hHD9KnKqkkzJYNkvoCRQU3/Qvsr2JmWSJ1kmZdpfAgeBdv1D4M3jHGhLZzfjBc5fLuucCxuY4pscrTlO7Y0FWfcGsYhHhxVeKajCTjuyPiOu70HHOUZu0GG/6QYsodtWwLBZBj9nP3pNpJWZsTsT8dUKXQ+SXFqK0vNj0Ox1x38S/yG+QBmMwxecXgWreRfJ/9dJPUtt2lqe5ckIKPZp6hZ24B6T3/j+V0vo0ocnE7EE5M7eDWNy1dWQdw8HqNd4e8CAZKzhQhQE9sFKKQPh1oKmjVfGW8S7Lh2/gryhe0k9FfGHE4YpoJpzNShMt6lifL4qYt8PN5/hWsogjs3S6pvb34ia8FmF4Ki7e4MkuPZsk3Osvk86UfxgzxmvqzCoFOSPmnxZAIwBhhNw8rwokk9uKEFgqXp9NDUbdKaR6lG970FyhpfhiyROSiEx/CmNsN02YrJzo9ZD8uwfgk+RSSgPTYa4SzojZXgzB+H9fsT1thqdQYEyX3wuQlUJWywnyqBq8IDyAVqs5WHLl8UkUhlsDwGzRTg9HKOmBpmgcAQz/I964wGPE27Z4jfLyAMr9qg== X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-Network-Message-Id: 160aedb0-501c-432e-f329-08dc63c112cc X-MS-Exchange-CrossTenant-AuthSource: BYAPR12MB2743.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Apr 2024 18:13:27.6510 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: UHN/d1yoU893ueeLkjUiLtOcxltqJISx9Gzq30lTttrE6fqyd9LBdZ8fbPjUBpwP5AeL6rDqKg1VUqRonhkgKw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SA1PR12MB6799 X-Patchwork-Delegate: kuba@kernel.org mlx5 Rx flow steering and CQE handling enable the driver to be able to update an skb's md_dst attribute as MACsec when MACsec traffic arrives when a device is configured for offloading. Advertise this to the core stack to take advantage of this capability. Cc: stable@vger.kernel.org Fixes: b7c9400cbc48 ("net/mlx5e: Implement MACsec Rx data path using MACsec skb_metadata_dst") Signed-off-by: Rahul Rameshbabu Reviewed-by: Benjamin Poirier Reviewed-by: Cosmin Ratiu --- drivers/net/ethernet/mellanox/mlx5/core/en_accel/macsec.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_accel/macsec.c b/drivers/net/ethernet/mellanox/mlx5/core/en_accel/macsec.c index b2cabd6ab86c..cc9bcc420032 100644 --- a/drivers/net/ethernet/mellanox/mlx5/core/en_accel/macsec.c +++ b/drivers/net/ethernet/mellanox/mlx5/core/en_accel/macsec.c @@ -1640,6 +1640,7 @@ static const struct macsec_ops macsec_offload_ops = { .mdo_add_secy = mlx5e_macsec_add_secy, .mdo_upd_secy = mlx5e_macsec_upd_secy, .mdo_del_secy = mlx5e_macsec_del_secy, + .rx_uses_md_dst = true, }; bool mlx5e_macsec_handle_tx_skb(struct mlx5e_macsec *macsec, struct sk_buff *skb)