From patchwork Fri Sep 13 18:36:18 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ard Biesheuvel X-Patchwork-Id: 173786 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:ce:0:0:0:0 with SMTP id r14csp506892ilq; Fri, 13 Sep 2019 11:36:44 -0700 (PDT) X-Google-Smtp-Source: APXvYqzEY4hccRUTwZxvTubmu+HUpmvCB/tbk3dHVfF7gXn2axAygLOOY75pLDgIFp6+SeokIWQ/ X-Received: by 2002:a50:9734:: with SMTP id c49mr49729529edb.93.1568399804350; Fri, 13 Sep 2019 11:36:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568399804; cv=none; d=google.com; s=arc-20160816; b=YVu/0my+JZyGPwZ6Hz6MKr4eKLszhuhbJoTyLUsywacZp8TzMNHYW8iYma/68sc3Lm 5RcHUxQaNVWrQsvNxL3L9t9yXWzOiApSbCO9ty5fK0Zmq8HzYayZhpRvgc9FINaW0dkU GrxAwt8s17FWc73/Y4rCWl0GnydLpoak4Ixx/jnugl+ofrWxdmB0X2rHgW0Tn3xP2NrV 6xryRD3d+QxclgSL8qwWcHDneBHkIl9Fj5mBvFVK6PwXW9vVLKmoQY1pJQX/2ABVNDzQ wLm+ejpOtewAjBFielLBdNS+mF1gCchveUXyAhc8ktgFshSs6FSKub14JKBUY7IxxXAz pWFw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature; bh=pj41kIDb9Coue4E/MdelRN5iEuUFhPMsEolC9yFleNw=; b=FA3EuRIa1NrzgzaKk9OCj0cCyfAbSVwRwfa9WrHfQ+j65Oyh0ygdnNUtIBKAdHGEek QbeBg2h7FbOnI5Gqt0OtrUq+uMIBYiB+S0050dO1QEj/vb5EIleBBMIKgDL7Rde39Nb1 0pgn+FwDyQ+/D+BYkD8ex4lwzv09oykXNHFvcMdnWHqJA8QDHxVuZDP18f1dUgjj2MKo gukBXDDS0pwI5QJTRTiDouX0N1BaOzfgZR7gHFKlk4TNQcpUhKeRzWrSEeW/PquME8Hk fTsmzhsBObiUstiwK8rjRzW64QdiuLNLiz8lLB/Fxk3rPsAozqifrrkIHt5iQmZCZoYf Vomw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=gDWUdqbm; spf=pass (google.com: best guess record for domain of linux-crypto-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e24si17146723edq.167.2019.09.13.11.36.44; Fri, 13 Sep 2019 11:36:44 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-crypto-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=gDWUdqbm; spf=pass (google.com: best guess record for domain of linux-crypto-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389805AbfIMSgn (ORCPT + 3 others); Fri, 13 Sep 2019 14:36:43 -0400 Received: from mail-wr1-f68.google.com ([209.85.221.68]:39587 "EHLO mail-wr1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389788AbfIMSgm (ORCPT ); Fri, 13 Sep 2019 14:36:42 -0400 Received: by mail-wr1-f68.google.com with SMTP id r3so2897711wrj.6 for ; Fri, 13 Sep 2019 11:36:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=pj41kIDb9Coue4E/MdelRN5iEuUFhPMsEolC9yFleNw=; b=gDWUdqbm1Ed95qny4mrCx8qNYok1fDg0pMqFxi5Oau1NrQhaAaZXWvKsthlK0RLmv6 zEs2o21RT1+pHZY7lQnWlwkUGuB0TVTP1iwINFSIK22MFxpiSA8YfyVsvSfWMqyaEPYe uX1+4f6nYjHgfY40zHKR4S34CDUGqcy9ceQdg3p/0EKdDHP4ZAVvVlVhGlcgemNDsKcT FG6eHrMi01tFxZigeLDUMHPmYgODBnZNRvw7WTV8dOe2InZgpx0Y0CjmGB2cFrobcqTu j2ZtiIfJpiOXXL231q/3hdjXygYX2y+TsXjTqtudqom3ho7n5JjnQRnGfAdo7L4sofNa aCWQ== 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=pj41kIDb9Coue4E/MdelRN5iEuUFhPMsEolC9yFleNw=; b=Mg8UfbVqEE1m8kz3t/KoZzFrASy6O35bsei0x3sqPxaApzxzMeDGVHRSHam6+Nk5OG AJ0SvRr1UJ1Ar1pIQfLzWCHU4IUb+hMOjzw7B088AcHO7yxX6WWIHfe+BpmQteol+zUk 55ZsDxgUAEvb22l6wXp0eWreE+NaLRMPa9xRT5kv127LJsL55eUpvfMR8tGM21OD+0Y7 ov5UAK4cvJbUtZ2DPo6ekJiSEB8QO8W7ZmIcIvbds4BoSFjTNx78hUPO6QhNWMizbzs/ fYajMI6rbRzgiacfI5lle9AQ3aSOzjm88PrDZlyHtYXrIJP4w0jrN9TGCkvsHSomTG7j mCtQ== X-Gm-Message-State: APjAAAV9a9BdhLl9ePvLv8DKjECQ6nN8kjhfGmoYmSSUy9nf8PJ0RiYk fT5Hs4kKmUbsfHeGdU5jIf8KJxV+Dd9ZBPWZ X-Received: by 2002:a5d:6846:: with SMTP id o6mr2911647wrw.73.1568399800446; Fri, 13 Sep 2019 11:36:40 -0700 (PDT) Received: from e111045-lin.c.hoisthospitality.com ([135.196.99.211]) by smtp.gmail.com with ESMTPSA id q10sm56216611wrd.39.2019.09.13.11.36.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 Sep 2019 11:36:39 -0700 (PDT) From: Ard Biesheuvel To: linux-crypto@vger.kernel.org Cc: herbert@gondor.apana.org.au, yvan.roux@linaro.org, maxim.kuvyrkov@linaro.org, Ard Biesheuvel Subject: [PATCH] crypto: aegis128-neon - use Clang compatible cflags for ARM Date: Fri, 13 Sep 2019 19:36:18 +0100 Message-Id: <20190913183618.6817-1-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.17.1 Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org The next version of Clang will start policing compiler command line options, and will reject combinations of -march and -mfpu that it thinks are incompatible. This results in errors like clang-10: warning: ignoring extension 'crypto' because the 'armv7-a' architecture does not support it [-Winvalid-command-line-argument] /tmp/aegis128-neon-inner-5ee428.s: Assembler messages: /tmp/aegis128-neon-inner-5ee428.s:73: Error: selected processor does not support `aese.8 q2,q14' in ARM mode when buiding the SIMD aegis128 code for 32-bit ARM, given that the 'armv7-a' -march argument is considered to be compatible with the ARM crypto extensions. Instead, we should use armv8-a, which does allow the crypto extensions to be enabled. Signed-off-by: Ard Biesheuvel --- crypto/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.17.1 diff --git a/crypto/Makefile b/crypto/Makefile index 0d2cdd523fd9..e76d8bd2f72c 100644 --- a/crypto/Makefile +++ b/crypto/Makefile @@ -93,7 +93,7 @@ obj-$(CONFIG_CRYPTO_AEGIS128) += aegis128.o aegis128-y := aegis128-core.o ifeq ($(ARCH),arm) -CFLAGS_aegis128-neon-inner.o += -ffreestanding -march=armv7-a -mfloat-abi=softfp +CFLAGS_aegis128-neon-inner.o += -ffreestanding -march=armv8-a -mfloat-abi=softfp CFLAGS_aegis128-neon-inner.o += -mfpu=crypto-neon-fp-armv8 aegis128-$(CONFIG_CRYPTO_AEGIS128_SIMD) += aegis128-neon.o aegis128-neon-inner.o endif