From patchwork Wed Jan 4 01:34:32 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neal Liu X-Patchwork-Id: 13088270 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A6AD9C4332F for ; Wed, 4 Jan 2023 08:18:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:Subject:CC :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=TtOTyw5zQfa7U3ppnAOx+nJmvTmocLzEcvxCHz63Ew8=; b=0GTTaFsQqDTinf 2yvulVpdImTHHAInNadqBXPwiXs4/lFhgxQy3Ms/GHDzx5qfbcQgfjr3B6n7Et6vH6RrzeCHR1cih tfMh8QVV23NAiCR0mBreEsEPs+SCdgNv8Dp1FKjBwH1HspKllN9Wf+B4kCo2dfyaYAGvI1+Mw+xUE krkAZ7ncm8/Ri1RB3C4E2V4RwzwTDkQFbwgK5zEK7EjcH5QyfCbefZJ6gST/5noQmHVUElLRQ47QF AdgmGl60MUj97lv7+HaOkPCjogXS2Fs7JtW1YKMw+w4skeOWFTIyp/xV4TBaxLeahWXlVy4CxYwZI zbR1QH9vUcC5n8k96m1w==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pCyyD-007ZbY-U0; Wed, 04 Jan 2023 08:17:58 +0000 Received: from desiato.infradead.org ([90.155.92.199]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pCyuA-007YRd-04 for linux-arm-kernel@bombadil.infradead.org; Wed, 04 Jan 2023 08:13:46 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=Content-Type:Content-Transfer-Encoding :MIME-Version:Message-ID:Date:Subject:CC:To:From:Sender:Reply-To:Content-ID: Content-Description:In-Reply-To:References; bh=+63jJOF0hAimDoXSFeFTtncwm++wjRG95BNrtAb8WHA=; b=aaEz7oRXlbzcIzSrdSqPtmtlQd Rza/o6LkrhtrUciS3czxRWV6dkpIH2R/0hJjwawodmgsjEsioSFwam5bSAzeumWjsNiJxs0QHrcTk 3pixHlaoTbveozeHlqXOwEZ28DEmG5Zrq9XaWuYYJuOhR4oWJcjjPoOXMq0wLCD+U8+e4Ihxpl92H IWiY2VSlDu+kP0f1HpiqoXCtr6fBo53ACQW3CfiyxVKw1zbedmjSM3yGNyCSpEjDS2tDFKaCoHldK vm+SUs6gZXIRKBmtgeN+BFYtBzuB2xLiFU2rknGIJM6jcanNEoxr1eceLRmlnineuT5qodSVfKJSc FaJPJ/7g==; Received: from twspam01.aspeedtech.com ([211.20.114.71]) by desiato.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1pCsgp-000lvo-35 for linux-arm-kernel@lists.infradead.org; Wed, 04 Jan 2023 01:35:38 +0000 Received: from mail.aspeedtech.com ([192.168.0.24]) by twspam01.aspeedtech.com with ESMTP id 3041OcIf076237; Wed, 4 Jan 2023 09:24:38 +0800 (GMT-8) (envelope-from neal_liu@aspeedtech.com) Received: from localhost.localdomain (192.168.10.10) by TWMBX02.aspeed.com (192.168.0.24) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Wed, 4 Jan 2023 09:34:41 +0800 From: Neal Liu To: Rob Herring , Krzysztof Kozlowski , Joel Stanley , "Andrew Jeffery" , Neal Liu , Herbert Xu , "David S . Miller" , Chia-Wei Wang CC: , , , , Subject: [PATCH v5 0/4] Add Aspeed ACRY driver for hardware acceleration Date: Wed, 4 Jan 2023 09:34:32 +0800 Message-ID: <20230104013436.203427-1-neal_liu@aspeedtech.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-Originating-IP: [192.168.10.10] X-ClientProxiedBy: TWMBX02.aspeed.com (192.168.0.24) To TWMBX02.aspeed.com (192.168.0.24) X-DNSRBL: X-MAIL: twspam01.aspeedtech.com 3041OcIf076237 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230104_013536_657818_3E4E7FC0 X-CRM114-Status: GOOD ( 12.50 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Aspeed ACRY engine is designed to accelerate the throughput of ECDSA/RSA signature and verification. These patches aim to add Aspeed ACRY RSA driver support. This driver also pass the run-time self tests that take place at algorithm registration on both big-endian/little-endian system in AST2600 evaluation board . Tested-by below configs: - CONFIG_CRYPTO_MANAGER_DISABLE_TESTS is not set - CONFIG_CRYPTO_MANAGER_EXTRA_TESTS=y - CONFIG_DMA_API_DEBUG=y - CONFIG_DMA_API_DEBUG_SG=y - CONFIG_CPU_BIG_ENDIAN=y Change since v4: - Remove GFP_DMA flag since it's unnecessary. Change since v3: - Revise aspeed,ast2600-ahbc.yaml dt-bindings description. Change since v2: - Fix format and uninitialized warning. - Revise binding description. Change since v1: - Fix dt-bindings description. - Refine the Makefile which has been addressed. Neal Liu (4): crypto: aspeed: Add ACRY RSA driver ARM: dts: aspeed: Add ACRY/AHBC device controller node dt-bindings: crypto: add documentation for Aspeed ACRY dt-bindings: bus: add documentation for Aspeed AHBC .../bindings/bus/aspeed,ast2600-ahbc.yaml | 37 + .../bindings/crypto/aspeed,ast2600-acry.yaml | 49 ++ MAINTAINERS | 2 +- arch/arm/boot/dts/aspeed-g6.dtsi | 13 + drivers/crypto/aspeed/Kconfig | 11 + drivers/crypto/aspeed/Makefile | 2 + drivers/crypto/aspeed/aspeed-acry.c | 828 ++++++++++++++++++ 7 files changed, 941 insertions(+), 1 deletion(-) create mode 100644 Documentation/devicetree/bindings/bus/aspeed,ast2600-ahbc.yaml create mode 100644 Documentation/devicetree/bindings/crypto/aspeed,ast2600-acry.yaml create mode 100644 drivers/crypto/aspeed/aspeed-acry.c