From patchwork Thu Sep 29 03:27:40 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zhangfei Gao X-Patchwork-Id: 117089 Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 2DA3DA00C4; Thu, 29 Sep 2022 05:27:59 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id C6B8040E5A; Thu, 29 Sep 2022 05:27:58 +0200 (CEST) Received: from mail-pg1-f171.google.com (mail-pg1-f171.google.com [209.85.215.171]) by mails.dpdk.org (Postfix) with ESMTP id E19FA40DDC for ; Thu, 29 Sep 2022 05:27:57 +0200 (CEST) Received: by mail-pg1-f171.google.com with SMTP id f193so347892pgc.0 for ; Wed, 28 Sep 2022 20:27:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date; bh=q55uISSKYwvNzJ7wCvG7+y/VRVmvT8Bx6Ql3tjG9Km8=; b=QLIWtZ1LRqLrpOuhlMMtrdNClVMmlQ7CB0DUIiJ4Gvk4nuO2VWVpGlTwjdBR/SRvmo yrbpFeQ36uf7Mkf/4ix+J4r4on0fsB7k1huTGHkPr0tor0zkIXNC4OlnAvTzYRu47Aw/ O+JBmTTm5pkN/8k9bjgB/0d28XOk8lNI3BH1mXEsOFdO9kno90+ce7YRMbJHC6h/vYhj l91hZ0PBcx0y4b54F//VYbYmOVDQ0q+LjegbU5Cb+O8bNSSTXPayp66XYgCPe0jb7yVQ MqDW3iTvF5w043VCXsotJr1SHBlSWxWU5O74ytJjNrP4NJ6m8CrcjI5eeisxUOUxiK+/ fwdQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date; bh=q55uISSKYwvNzJ7wCvG7+y/VRVmvT8Bx6Ql3tjG9Km8=; b=BF6aVrAr5F8Hs4S+oLgiT7Hh2mN6J2LPHAi5jajtwehaMeLV5jWEHednKhv2PWpQlb Foson8y+ZFJLOlaO2/NvrXPWa/AjaQZI6V/szYGG3MvGOWk3lZpPPg1EfzZPTo4Z8OyO 9qwJc0iiPfXMu4GOHYFvpdle+kDzq4qcw5xo2u4JkKx4j//iEFf5wKj/RkV9Hedz5BIv c1i0/ctCkhZSBOEubDALlc2QlLAAUSWcOG9qTT/Pukg/itTHu4yVSxa0RzU6jbiRUIbV jC52ZJK7jx3sZCJjLYMGjejTi8IEO2104ncHQMalfNi2nHsyTGi5jymRhMAH+7J5ydWU YvUQ== X-Gm-Message-State: ACrzQf14zGXXJBGVuJriRHgrRxQjBBvco6VUXHSk0JbWgXOP1xS4f7fb DpKizSyUvNKkDFvyozEHsnluNA== X-Google-Smtp-Source: AMsMyM7RdSSTrv7zHsB0y6ntjq7+TkN7c8LqWWeVTHrjPg151jhLfEzItoBQWdwyaPWoPaigPholeA== X-Received: by 2002:aa7:93dd:0:b0:548:c85b:18d5 with SMTP id y29-20020aa793dd000000b00548c85b18d5mr1059157pff.21.1664422077113; Wed, 28 Sep 2022 20:27:57 -0700 (PDT) Received: from localhost.localdomain ([45.128.198.71]) by smtp.gmail.com with ESMTPSA id gn4-20020a17090ac78400b001fd66d5c42csm2304271pjb.49.2022.09.28.20.27.52 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 28 Sep 2022 20:27:56 -0700 (PDT) From: Zhangfei Gao To: Akhil Goyal , Declan Doherty , Fan Zhang , Ashish Gupta , Ray Kinsella Cc: dev@dpdk.org, acc@openeuler.org, Zhangfei Gao Subject: [PATCH v3 0/5] crypto/uadk: introduce uadk crypto driver Date: Thu, 29 Sep 2022 11:27:40 +0800 Message-Id: <20220929032746.10659-1-zhangfei.gao@linaro.org> X-Mailer: git-send-email 2.36.1 MIME-Version: 1.0 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 Introduce a new crypto PMD for hardware accelerators based on UADK [1]. UADK is a framework for user applications to access hardware accelerators. UADK relies on IOMMU SVA (Shared Virtual Address) feature, which share the same page table between IOMMU and MMU. Thereby user application can directly use virtual address for device dma, which enhances the performance as well as easy usability. [1] https://github.com/Linaro/uadk Test: sudo dpdk-test --vdev=crypto_uadk (--log-level=6) RTE>>cryptodev_uadk_autotest RTE>>quit update in v3: Split patches according to Akhil's suggestions Please split the patches as below. 1. introduce driver - create files with meson.build and with probe/remove and device ops defined but not implemented. You do not need to write empty functions. Add basic documentation also which defines what the driver is. You can explain the build dependency here. 2. define queue structs and setup/remove APIs 3. Add data path 4. implement cipher op. Add capabilities and documentation of what is supported in each of the patch. Add feature flags etc. 5. implement auth, add capabilities and documentation 6. test app changes. Update in v2: Change uadk_supported_platform to uadk_crypto_version, which matches better than platform. enum uadk_crypto_version { UADK_CRYPTO_V2, UADK_CRYPTO_V3, }; Update in v1, compared with rfc Suggested from Akhil Goyal Only consider crypto PMD first Split patch into small (individually compiled) patches. Update MAINTAINERS and doc/guides/cryptodevs/features/uadk.ini Zhangfei Gao (6): crypto/uadk: introduce uadk crypto driver crypto/uadk: support basic operations crypto/uadk: support enqueue/dequeue operations crypto/uadk: support cipher algorithms crypto/uadk: support auth algorithms test/crypto: add cryptodev_uadk_autotest MAINTAINERS | 6 + app/test/test_cryptodev.c | 7 + app/test/test_cryptodev.h | 1 + doc/guides/cryptodevs/features/uadk.ini | 55 ++ doc/guides/cryptodevs/index.rst | 1 + doc/guides/cryptodevs/uadk.rst | 74 ++ drivers/crypto/meson.build | 1 + drivers/crypto/uadk/meson.build | 36 + drivers/crypto/uadk/uadk_crypto_pmd.c | 1158 +++++++++++++++++++++++ drivers/crypto/uadk/version.map | 3 + 10 files changed, 1342 insertions(+) create mode 100644 doc/guides/cryptodevs/features/uadk.ini create mode 100644 doc/guides/cryptodevs/uadk.rst create mode 100644 drivers/crypto/uadk/meson.build create mode 100644 drivers/crypto/uadk/uadk_crypto_pmd.c create mode 100644 drivers/crypto/uadk/version.map