From patchwork Sun Jul 9 15:42:42 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Heiko_St=C3=BCbner?= X-Patchwork-Id: 117518 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9f45:0:b0:3ea:f831:8777 with SMTP id v5csp4511193vqx; Sun, 9 Jul 2023 08:53:35 -0700 (PDT) X-Google-Smtp-Source: APBJJlGI8zLUYrsOiJBBGKqmslYzEpLCYrFPyX7DMo1uVscWdxUtnGoBauIVBMrUp+wOq78UEaCa X-Received: by 2002:a17:903:1205:b0:1b3:b998:8007 with SMTP id l5-20020a170903120500b001b3b9988007mr10562270plh.55.1688918015273; Sun, 09 Jul 2023 08:53:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1688918015; cv=none; d=google.com; s=arc-20160816; b=mtc4sMm295doGYNi1/FwzZCujRSu1eSB4I4VCa+vB9fpNSAuUHLZoKCoWnHDIZDx9I s3gsdOlN1dHBJ5+hVjMgH1WYtCWA8L5o44aP5v+0E5N8XGGfu/w8BEPG530F+G2/JdLv fCo/gAh0yG+xOq3SyJgcT/oZUTBOvaYUVmVfyfX+3070iIUUp4NzIx8E6tKORkcLqhDc rg6RMid1DpNOzGxuqKksgud9QL6iXxpial3Jn1yeMeFySzI+0eg4MAuvH7cWophMd0TU pPHRTkoT/ogqg+h5JBK4iwPlnjgukfbFhahZGB0UCXAwZc/tNSTJ06rQhbsdRE+QAx3v 3Drw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=7n2Ju8tJxyRE6J5IDn+0SwIxC9RWXygDkyWLcZ/+E7o=; fh=kdZoYQ7OxiOlgk8JV6AaRDhZ3ti3Lsh9kEAaaefSh4Y=; b=nxc5+2iCa+2grbpOM05827S+EoK9m0XKeCpYpaVl4IaoaYvrPv8NwQt6N5qYXH9TY7 trFB6wxenYDMK/zhj286RHq6XBteykBThaPEp4sw473CKg7b1Mwi9KxA18vrtDG37zbo YATcHxaej3Ugm6L95BFtoSR7NnBwRXbKUuQN3UVv+zBcwYWirzQgGukYOWz8682CEVqI 4coh1PErHdkEeyV1EEkS0oKdCaF+FwxVdMEOlkHVyXLNmTHCn9vLsZxgnEAdX2vNvVy2 yKyxDJ+AxKdz3zKxgo0CEHFNWM3yvq0kNHBEyCnySCpbRNoLnZFZvtYN/2cK8iuGZ4Op 0XGw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=sntech.de Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x4-20020a17090aca0400b00263c7cadb62si5829995pjt.38.2023.07.09.08.52.58; Sun, 09 Jul 2023 08:53:35 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=sntech.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231448AbjGIPnE (ORCPT + 99 others); Sun, 9 Jul 2023 11:43:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53094 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229868AbjGIPnC (ORCPT ); Sun, 9 Jul 2023 11:43:02 -0400 Received: from gloria.sntech.de (gloria.sntech.de [185.11.138.130]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CB34FDD; Sun, 9 Jul 2023 08:42:56 -0700 (PDT) Received: from i53875a50.versanet.de ([83.135.90.80] helo=phil.fritz.box) by gloria.sntech.de with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qIWYh-0002yG-3V; Sun, 09 Jul 2023 17:42:47 +0200 From: Heiko Stuebner To: palmer@dabbelt.com, paul.walmsley@sifive.com Cc: aou@eecs.berkeley.edu, heiko@sntech.de, herbert@gondor.apana.org.au, davem@davemloft.net, conor.dooley@microchip.com, linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, linux-crypto@vger.kernel.org, christoph.muellner@vrull.eu, ebiggers@kernel.org, Heiko Stuebner Subject: [PATCH v6 2/3] RISC-V: hook new crypto subdir into build-system Date: Sun, 9 Jul 2023 17:42:42 +0200 Message-Id: <20230709154243.1582671-3-heiko@sntech.de> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230709154243.1582671-1-heiko@sntech.de> References: <20230709154243.1582671-1-heiko@sntech.de> MIME-Version: 1.0 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_BLOCKED,SPF_PASS,T_SCC_BODY_TEXT_LINE, T_SPF_HELO_TEMPERROR autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1770958896807789640 X-GMAIL-MSGID: 1770958896807789640 From: Heiko Stuebner Create a crypto subdirectory for added accelerated cryptography routines and hook it into the riscv Kbuild and the main crypto Kconfig. Signed-off-by: Heiko Stuebner --- arch/riscv/Kbuild | 1 + arch/riscv/crypto/Kconfig | 5 +++++ arch/riscv/crypto/Makefile | 4 ++++ crypto/Kconfig | 3 +++ 4 files changed, 13 insertions(+) create mode 100644 arch/riscv/crypto/Kconfig create mode 100644 arch/riscv/crypto/Makefile diff --git a/arch/riscv/Kbuild b/arch/riscv/Kbuild index afa83e307a2e..250d1fd38618 100644 --- a/arch/riscv/Kbuild +++ b/arch/riscv/Kbuild @@ -2,6 +2,7 @@ obj-y += kernel/ mm/ net/ obj-$(CONFIG_BUILTIN_DTB) += boot/dts/ +obj-$(CONFIG_CRYPTO) += crypto/ obj-y += errata/ obj-$(CONFIG_KVM) += kvm/ diff --git a/arch/riscv/crypto/Kconfig b/arch/riscv/crypto/Kconfig new file mode 100644 index 000000000000..10d60edc0110 --- /dev/null +++ b/arch/riscv/crypto/Kconfig @@ -0,0 +1,5 @@ +# SPDX-License-Identifier: GPL-2.0 + +menu "Accelerated Cryptographic Algorithms for CPU (riscv)" + +endmenu diff --git a/arch/riscv/crypto/Makefile b/arch/riscv/crypto/Makefile new file mode 100644 index 000000000000..b3b6332c9f6d --- /dev/null +++ b/arch/riscv/crypto/Makefile @@ -0,0 +1,4 @@ +# SPDX-License-Identifier: GPL-2.0-only +# +# linux/arch/riscv/crypto/Makefile +# diff --git a/crypto/Kconfig b/crypto/Kconfig index 650b1b3620d8..c7b23d2c58e4 100644 --- a/crypto/Kconfig +++ b/crypto/Kconfig @@ -1436,6 +1436,9 @@ endif if PPC source "arch/powerpc/crypto/Kconfig" endif +if RISCV +source "arch/riscv/crypto/Kconfig" +endif if S390 source "arch/s390/crypto/Kconfig" endif