From patchwork Fri May 18 21:01:08 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?T25kcmVqIE1vc27DocSNZWs=?= X-Patchwork-Id: 10412129 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 3D9656031B for ; Fri, 18 May 2018 21:01:59 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2C48B286D7 for ; Fri, 18 May 2018 21:01:59 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 207A928AC8; Fri, 18 May 2018 21:01:59 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 925E3286D7 for ; Fri, 18 May 2018 21:01:58 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751942AbeERVB5 (ORCPT ); Fri, 18 May 2018 17:01:57 -0400 Received: from mail-wm0-f68.google.com ([74.125.82.68]:51877 "EHLO mail-wm0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751429AbeERVB5 (ORCPT ); Fri, 18 May 2018 17:01:57 -0400 Received: by mail-wm0-f68.google.com with SMTP id j4-v6so16235574wme.1 for ; Fri, 18 May 2018 14:01:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=bJR1UeeclqL5D12OFSMuUwEcUglpgy3TrI0rfcGYxY4=; b=UNacLquhZeIospPoExw0dCe2LeSOV91ypEpqkV2NnpY/QGghTVFWsV+h+2vhxRy76b FyNJNybXoKnHKBl8KUM902xxcxj0SLVtPWRqg/4lfNNvvUsMA/jUawwvK6Rg52G4JPTT uhWdd8TmWNeCnm1Tic7+iHv//++ImsCxpHLP1jBbjAwJDd97E+rDvXUEr+vcstI4AR/J ecz2bjGKg7akUV0LVKQwbN7dwlBQPBCuxL7IHQCsrhLDcF0HrTddBNXvgmZzp4WvRiLw 5+HvjINYbcQp9X1uo2B93AeoFcjiinuZlj+aZf3GOiVRgMtugI/oORstxRyw/R5dDuMR EkAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=bJR1UeeclqL5D12OFSMuUwEcUglpgy3TrI0rfcGYxY4=; b=GhC9h+wUphhoWKRkXWFBEYoRdOYO9m+wg9cM1g1DRjPCqqO0f0zxfWd9ZupmEj+/Yq d0HGf42yUFXoZAVHxX572QajWdHxiIQb8L457xloDEQeGqpKkn+YaPXFqzn6GPkolwmq x0ceg0Jbplh6kDdV1L4NZXAQHRGWyAX+SydJQtNGZBqzrd2fRZxELYnEfjde4bfals8g nM8snwpqEKWoUvRMsUZGblq8/Yh2Yr/T0SLUxuWQJyqKwwiYe4OlJ5aQSrna17760XLw 4afcUjWbKT8FXXDsT2RnxGRymI0GSYZol/8wWVDOdvypyfhHqU6gZEsoovku/n1n0e97 /VQg== X-Gm-Message-State: ALKqPwdPBHdsZ9gEwmVaZ9nZUy8/O81sR2MT7ZcZCZF2V3MVtYshuFb2 hwdXJgoZP3VE8GtLelQ5XWzDQg== X-Google-Smtp-Source: AB8JxZptGDw6I2l3QoCb8wCFE5r1faaqnaxN3gySFRUMD8rfxvkdATE/0T63hZp1Jx3ckN89mtB3hQ== X-Received: by 2002:a1c:8645:: with SMTP id i66-v6mr5932605wmd.40.1526677315464; Fri, 18 May 2018 14:01:55 -0700 (PDT) Received: from omosnacek-acer.redhat.com ([2a02:8308:b041:e600:4d58:ff19:2f22:76b8]) by smtp.gmail.com with ESMTPSA id z66-v6sm8929745wme.13.2018.05.18.14.01.53 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 18 May 2018 14:01:54 -0700 (PDT) From: =?UTF-8?q?Ondrej=20Mosn=C3=A1=C4=8Dek?= To: linux-crypto@vger.kernel.org Cc: Herbert Xu , Milan Broz , Ondrej Mosnacek Subject: [PATCH] crypto: Mark MORUS SIMD glue as x86-specific Date: Fri, 18 May 2018 23:01:08 +0200 Message-Id: <20180518210108.28063-1-omosnacek@gmail.com> X-Mailer: git-send-email 2.17.0 Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Ondrej Mosnacek Commit 56e8e57fc3a7 ("crypto: morus - Add common SIMD glue code for MORUS") accidetally consiedered the glue code to be usable by different architectures, but it seems to be only usable on x86. This patch moves it under arch/x86/crypto and adds 'depends on X86' to the Kconfig options. Reported-by: kbuild test robot Signed-off-by: Ondrej Mosnacek --- arch/x86/crypto/Makefile | 3 +++ {crypto => arch/x86/crypto}/morus1280_glue.c | 4 ++-- {crypto => arch/x86/crypto}/morus640_glue.c | 4 ++-- crypto/Kconfig | 6 ++++-- crypto/Makefile | 2 -- 5 files changed, 11 insertions(+), 8 deletions(-) rename {crypto => arch/x86/crypto}/morus1280_glue.c (98%) rename {crypto => arch/x86/crypto}/morus640_glue.c (98%) diff --git a/arch/x86/crypto/Makefile b/arch/x86/crypto/Makefile index 3813e7cdaada..48e731d782e9 100644 --- a/arch/x86/crypto/Makefile +++ b/arch/x86/crypto/Makefile @@ -42,6 +42,9 @@ obj-$(CONFIG_CRYPTO_AEGIS128_AESNI_SSE2) += aegis128-aesni.o obj-$(CONFIG_CRYPTO_AEGIS128L_AESNI_SSE2) += aegis128l-aesni.o obj-$(CONFIG_CRYPTO_AEGIS256_AESNI_SSE2) += aegis256-aesni.o +obj-$(CONFIG_CRYPTO_MORUS640_GLUE) += morus640_glue.o +obj-$(CONFIG_CRYPTO_MORUS1280_GLUE) += morus1280_glue.o + obj-$(CONFIG_CRYPTO_MORUS640_SSE2) += morus640-sse2.o obj-$(CONFIG_CRYPTO_MORUS1280_SSE2) += morus1280-sse2.o diff --git a/crypto/morus1280_glue.c b/arch/x86/crypto/morus1280_glue.c similarity index 98% rename from crypto/morus1280_glue.c rename to arch/x86/crypto/morus1280_glue.c index ce1e5c34b09d..0dccdda1eb3a 100644 --- a/crypto/morus1280_glue.c +++ b/arch/x86/crypto/morus1280_glue.c @@ -1,6 +1,6 @@ /* * The MORUS-1280 Authenticated-Encryption Algorithm - * Common glue skeleton + * Common x86 SIMD glue skeleton * * Copyright (c) 2016-2018 Ondrej Mosnacek * Copyright (C) 2017-2018 Red Hat, Inc. All rights reserved. @@ -299,4 +299,4 @@ EXPORT_SYMBOL_GPL(cryptd_morus1280_glue_exit_tfm); MODULE_LICENSE("GPL"); MODULE_AUTHOR("Ondrej Mosnacek "); -MODULE_DESCRIPTION("MORUS-1280 AEAD mode -- glue for optimizations"); +MODULE_DESCRIPTION("MORUS-1280 AEAD mode -- glue for x86 optimizations"); diff --git a/crypto/morus640_glue.c b/arch/x86/crypto/morus640_glue.c similarity index 98% rename from crypto/morus640_glue.c rename to arch/x86/crypto/morus640_glue.c index c7e788cfaa29..7b58fe4d9bd1 100644 --- a/crypto/morus640_glue.c +++ b/arch/x86/crypto/morus640_glue.c @@ -1,6 +1,6 @@ /* * The MORUS-640 Authenticated-Encryption Algorithm - * Common glue skeleton + * Common x86 SIMD glue skeleton * * Copyright (c) 2016-2018 Ondrej Mosnacek * Copyright (C) 2017-2018 Red Hat, Inc. All rights reserved. @@ -295,4 +295,4 @@ EXPORT_SYMBOL_GPL(cryptd_morus640_glue_exit_tfm); MODULE_LICENSE("GPL"); MODULE_AUTHOR("Ondrej Mosnacek "); -MODULE_DESCRIPTION("MORUS-640 AEAD mode -- glue for optimizations"); +MODULE_DESCRIPTION("MORUS-640 AEAD mode -- glue for x86 optimizations"); diff --git a/crypto/Kconfig b/crypto/Kconfig index 75f5efde9aa3..0c9883d60a51 100644 --- a/crypto/Kconfig +++ b/crypto/Kconfig @@ -341,7 +341,8 @@ config CRYPTO_MORUS640 Support for the MORUS-640 dedicated AEAD algorithm. config CRYPTO_MORUS640_GLUE - tristate "MORUS-640 AEAD algorithm (glue for SIMD optimizations)" + tristate "MORUS-640 AEAD algorithm (glue for x86 SIMD optimizations)" + depends on X86 select CRYPTO_AEAD select CRYPTO_CRYPTD help @@ -363,7 +364,8 @@ config CRYPTO_MORUS1280 Support for the MORUS-1280 dedicated AEAD algorithm. config CRYPTO_MORUS1280_GLUE - tristate "MORUS-1280 AEAD algorithm (glue for SIMD optimizations)" + tristate "MORUS-1280 AEAD algorithm (glue for x86 SIMD optimizations)" + depends on X86 select CRYPTO_AEAD select CRYPTO_CRYPTD help diff --git a/crypto/Makefile b/crypto/Makefile index 68a7c546460a..6d1d40eeb964 100644 --- a/crypto/Makefile +++ b/crypto/Makefile @@ -91,8 +91,6 @@ obj-$(CONFIG_CRYPTO_AEGIS128L) += aegis128l.o obj-$(CONFIG_CRYPTO_AEGIS256) += aegis256.o obj-$(CONFIG_CRYPTO_MORUS640) += morus640.o obj-$(CONFIG_CRYPTO_MORUS1280) += morus1280.o -obj-$(CONFIG_CRYPTO_MORUS640_GLUE) += morus640_glue.o -obj-$(CONFIG_CRYPTO_MORUS1280_GLUE) += morus1280_glue.o obj-$(CONFIG_CRYPTO_PCRYPT) += pcrypt.o obj-$(CONFIG_CRYPTO_CRYPTD) += cryptd.o obj-$(CONFIG_CRYPTO_MCRYPTD) += mcryptd.o