From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id A8B3AA00C4; Mon, 18 Apr 2022 13:10:25 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 45C1840150; Mon, 18 Apr 2022 13:10:24 +0200 (CEST) Received: from NAM02-DM3-obe.outbound.protection.outlook.com (mail-dm3nam07on2053.outbound.protection.outlook.com [40.107.95.53]) by mails.dpdk.org (Postfix) with ESMTP id E21384014F for ; Mon, 18 Apr 2022 13:10:21 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=DoVuOq47lJ+WekeXFNGazdiFL3OrhhefIzayuQ69SAwbh8n1qO6tcPxPIHcTsshqyKN1gCQf3NsHdCt/VwZa720E11oWg5pOeYKp1a2UF9cd/wv218sGyCZ1P3yA0ryAa4SoaVCn33SEI2t5t3rPOsP3udaUG8ysAbTzW3mnp/cubk8xrykg1kzNyvULy9AfziFTBp/CDo8cEx7zKV+JJuiL3zdlQaeWQ2eILX31JEcTOUy8dVqmOnMMiv5Eh+IdOMsKXC2G0gVxVfsdz8wXhKd9amrhsG4gd7sm/KoEOSZJx5I+cwdanwLDdoCMUElnWhVZo8LKucR4LDkdm5nzpA== 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=QQjivbmafilg0SwYl7v99BNvg1SqqyM6Ra11oJif2hQ=; b=arb/P9rcnzaGX1f7Takd/CSNePgxoXuPA4PCMAs9shX5KPZiL++S+P47gh51jPdFGGJM1j1lRfYE1TKLq5ed1KEpFZZrB9avnsxCYoMYJn92XtxMa8niZS7pcZJj6QfPyrrPF89ZWy70WDma3ZELodSl/DBxnlJxLlDdCuCOWlciN5YukiS+frC/CVlhE1gNroqvBAEmYocecWHMH4CYvDXYJaLzsCyxdZXTXhpUz3V1ipKYkbbrFnVfxqQSYZ08iWHcRC7GqxW06Ee7pbkRFQx1OPsAMStrVFPEg42O1XXKbmqS/uMaMrVNpUWY4jB+zRnXCU8/l/dTSIirZRPTRg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 12.22.5.238) smtp.rcpttodomain=dpdk.org smtp.mailfrom=nvidia.com; dmarc=pass (p=reject sp=reject pct=100) action=none header.from=nvidia.com; dkim=none (message not signed); 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=QQjivbmafilg0SwYl7v99BNvg1SqqyM6Ra11oJif2hQ=; b=Pg5Oi6ewP7gTrsfZOZ5xN2K4QrJTaKHXSYJ9hhR51dWXgjdCRbpoinqsN7RP30BUj9yN5I+k+ouASBRJJyuZtOIeD+xgEwBb5xoVHRVR50nB3MOYx/GcymSfGgwP0TPbj6fCvtvZCdc+Sh2X+wcgKRk41RA4dr4FeCx1fQ2cQDibqgrapsBvAOyonHRj7J96Ds7rw4yoVR1YUlGQvskcN+/ldugN2dV5qIeUQHsDRo1vr7WvwQIuyK+kTWhUG2zeVFrAFSkp4AyqSJhtC3wJONwlmpelHYNMfgWbvXTdilFVyaQwpaY6ZOy0aat7pe57dC2K/IBABjFBXa+GXbJuIQ== Received: from MW4PR03CA0224.namprd03.prod.outlook.com (2603:10b6:303:b9::19) by DM5PR12MB1484.namprd12.prod.outlook.com (2603:10b6:4:11::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5164.20; Mon, 18 Apr 2022 11:10:20 +0000 Received: from CO1NAM11FT055.eop-nam11.prod.protection.outlook.com (2603:10b6:303:b9:cafe::ae) by MW4PR03CA0224.outlook.office365.com (2603:10b6:303:b9::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5164.20 via Frontend Transport; Mon, 18 Apr 2022 11:10:20 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 12.22.5.238) smtp.mailfrom=nvidia.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=nvidia.com; Received-SPF: Pass (protection.outlook.com: domain of nvidia.com designates 12.22.5.238 as permitted sender) receiver=protection.outlook.com; client-ip=12.22.5.238; helo=mail.nvidia.com; Received: from mail.nvidia.com (12.22.5.238) by CO1NAM11FT055.mail.protection.outlook.com (10.13.175.129) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.5164.19 via Frontend Transport; Mon, 18 Apr 2022 11:10:19 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by DRHQMAIL105.nvidia.com (10.27.9.14) with Microsoft SMTP Server (TLS) id 15.0.1497.32; Mon, 18 Apr 2022 11:10:19 +0000 Received: from nvidia.com (10.126.231.35) by rnnvmail201.nvidia.com (10.129.68.8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.22; Mon, 18 Apr 2022 04:10:17 -0700 From: Raja Zidane To: CC: Subject: [PATCH 0/2] crypto/mlx5: add support for plaintext import method Date: Mon, 18 Apr 2022 14:10:03 +0300 Message-ID: <20220418111005.2291-1-rzidane@nvidia.com> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.126.231.35] X-ClientProxiedBy: rnnvmail201.nvidia.com (10.129.68.8) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 0cdcf014-6866-460a-e23c-08da212c0693 X-MS-TrafficTypeDiagnostic: DM5PR12MB1484:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: YtlJ7hJ63n31TABlRGJ47YhRDDN560vqhwAvCA4xzP/FGtGVQq5MUFsxVKt7HPjNJHQnf0AJahP08h9LnGg2LHm5AwwFXztE+mGHCP4+EumDH+Ay7rLbERaggZcF+ASq3hkjCJ0EQs2cH203hGjXa0LrWIlqYyECQOVVRJxdsfMLnBL5ofZVu7H86rWFjEFYH14lfQgAAKgvA3mAtTtOie2y8oi96H/uWrdwrWsw64FxgZqFjSdijoLCh79UMYJLAN1V8gtdeQMaALDGUXA8fHipc17MynFWpJrAKuVoiPgVwf4F0BKa0gh+AftWX0NzVQkOK/wv4K4ztRQoA+YCob8FAS/cOEZCYmeu/dq2TYfWPuIFNAyTJXwghgFQcp3ENYWPuzcHEMbddINQLOM2/e6fc9pYRUNNRs7yHgO7lBJrOSFHG2GlPYeXmDn7hSDox7ZsEhzKOcHi0szYDBeCF79ffyR3zMMxeVj0imVmXdLIRyRVVQEw+9QDETvrtfTxgEDZl18udmf+NI0Ev6Sk9h8Xae2DSNqgNWpUaw+MvQtfdOSFNhpwObdTde9zTHGX96PDwsHNJ7VVfqjrAezwGHBxusPlpgA54FgT+ZPVDbANQBOXNT1hOooGsuCgxmU7OWPAf7o3GvZGlzWIQAFYHUQPcgFfb63GxdX6k133fZJff5g4BGIN6SYGaPstQ1JDULmIEnIKRbSx5HSyzTW6iaSaSowr04x4SjZtP94cJd0AeYCF0Ukpildz2TPQ6V5rPdcPZuGr1v0yvNFSIa+qGNI2dj9C63ro2dUMsm2HJ8M= X-Forefront-Antispam-Report: CIP:12.22.5.238; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:InfoNoRecords; CAT:NONE; SFS:(13230001)(4636009)(40470700004)(36840700001)(46966006)(6666004)(81166007)(26005)(186003)(426003)(47076005)(16526019)(336012)(83380400001)(6916009)(1076003)(6286002)(2616005)(107886003)(356005)(316002)(2906002)(82310400005)(508600001)(7696005)(55016003)(8936002)(86362001)(5660300002)(70206006)(4326008)(8676002)(70586007)(36860700001)(40460700003)(966005)(36756003)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Apr 2022 11:10:19.7885 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 0cdcf014-6866-460a-e23c-08da212c0693 X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[12.22.5.238]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT055.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR12MB1484 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Using crypto devs requires the user to log in and the supplied DEK to be encrypted with a KEK (keys encryption key). KEK is burned once on the nic, along with credentials for users, and for a user to log in, he is needed to supply his creds wrapped with the KEK. A device comes out of the Mellanox factory with a pre-defined import method for each algorithm. The defined method could be wrapped mode, so the device can be used as described above, or plaintext mode, without the need to log in and wrap supplied DEKs. Raja Zidane (2): common/mlx5: extend crypto capabilities crypto/mlx5: support plaintext keys doc/guides/cryptodevs/mlx5.rst | 17 ++++++++-- drivers/common/mlx5/mlx5_devx_cmds.c | 13 ++++++-- drivers/common/mlx5/mlx5_devx_cmds.h | 1 + drivers/common/mlx5/mlx5_prm.h | 29 +++++++++++++++++ drivers/crypto/mlx5/mlx5_crypto.c | 43 +++++++++++++++--------- drivers/crypto/mlx5/mlx5_crypto.h | 3 +- drivers/crypto/mlx5/mlx5_crypto_dek.c | 47 +++++++++++++++++++-------- 7 files changed, 117 insertions(+), 36 deletions(-) -- dependant on https://patchwork.dpdk.org/project/dpdk/patch/20220418110516.2105-1-rzidane@nvidia.com/ 2.21.0