From patchwork Fri Jan 13 08:33:26 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ard Biesheuvel X-Patchwork-Id: 9514821 X-Patchwork-Delegate: herbert@gondor.apana.org.au 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 417E1601DA for ; Fri, 13 Jan 2017 08:34:42 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 376182860A for ; Fri, 13 Jan 2017 08:34:42 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2C33B2862E; Fri, 13 Jan 2017 08:34:42 +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=-6.3 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID 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 F305D28626 for ; Fri, 13 Jan 2017 08:34:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751343AbdAMIeh (ORCPT ); Fri, 13 Jan 2017 03:34:37 -0500 Received: from mail-wm0-f41.google.com ([74.125.82.41]:37778 "EHLO mail-wm0-f41.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751222AbdAMIeg (ORCPT ); Fri, 13 Jan 2017 03:34:36 -0500 Received: by mail-wm0-f41.google.com with SMTP id c206so60379002wme.0 for ; Fri, 13 Jan 2017 00:34:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=ugb6ZG2dgfVE2m1V3Mh90n1+jt2C2zes28KP0G1pOOM=; b=CJzplso3ttGsX/O6ceF2n/DZT8bxNuFPDxrQpej0hfjPrbekQlb1wTmtZL0whQ5fu3 MbHTviv8YvXgR17eN3exXN0Ua08JbaWmcTdq49kza8sYeOHbAVWLoD1YUP3IODNjVs5L l66WRoIGqVh8/KZHqhW8DiX2CAV6Ap8TDvjqo= 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=ugb6ZG2dgfVE2m1V3Mh90n1+jt2C2zes28KP0G1pOOM=; b=KtwYxgJWn7oh4Gz4e1AEg1W+2C+/jzSJwQv0CfEM7zYo0sy2C1zLswMLgfckqUIYRx PeEeQO5f73yp0AdeL7/koFxQKpLWOzEr8iv0P1LBYd01P5cKQyqf53AGYxRAMN1oIK8A Nn897RiRXMIC04NIJGZqzexLCIbNNHEOOZGIDBisXGczuhRqUSKM2+ZiBxswovJcBkox i8zUL8n2THfCcECSRHvmHAYJvHtCtqzXS7hF0KDuSdmK/gqwWVs7ISliW7RDmfq/pWbA DFIzxdUbwe0g703/Y0z8H26ZZJz4HjWO1iTzgj7VEPO2uSvs8qZWPDNytkeDQz6Lwm49 3EhQ== X-Gm-Message-State: AIkVDXI8DLuJsQuITKblFyzb3VN8nY6No/fJwzDAW8NtOcnn1kFgeMRNDuJn0GwqLrfhR+WF X-Received: by 10.28.25.135 with SMTP id 129mr1158692wmz.122.1484296462568; Fri, 13 Jan 2017 00:34:22 -0800 (PST) Received: from localhost.localdomain ([160.167.203.25]) by smtp.gmail.com with ESMTPSA id 135sm2675929wmh.14.2017.01.13.00.34.20 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 13 Jan 2017 00:34:21 -0800 (PST) From: Ard Biesheuvel To: linux-crypto@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org, herbert@gondor.apana.org.au, arnd@arndb.de, Ard Biesheuvel Subject: [PATCH] crypto: arm/aes - avoid reserved 'tt' mnemonic in asm code Date: Fri, 13 Jan 2017 08:33:26 +0000 Message-Id: <1484296406-13224-1-git-send-email-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.7.4 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 The ARMv8-M architecture introduces 'tt' and 'ttt' instructions, which means we can no longer use 'tt' as a register alias on recent versions of binutils for ARM. So replace the alias with 'ttab'. Fixes: 81edb4262975 ("crypto: arm/aes - replace scalar AES cipher") Signed-off-by: Ard Biesheuvel --- arch/arm/crypto/aes-cipher-core.S | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/arch/arm/crypto/aes-cipher-core.S b/arch/arm/crypto/aes-cipher-core.S index b04261e1e068..c817a86c4ca8 100644 --- a/arch/arm/crypto/aes-cipher-core.S +++ b/arch/arm/crypto/aes-cipher-core.S @@ -18,7 +18,7 @@ rounds .req r1 in .req r2 out .req r3 - tt .req ip + ttab .req ip t0 .req lr t1 .req r2 @@ -34,9 +34,9 @@ .macro __load, out, in, idx .if __LINUX_ARM_ARCH__ < 7 && \idx > 0 - ldr \out, [tt, \in, lsr #(8 * \idx) - 2] + ldr \out, [ttab, \in, lsr #(8 * \idx) - 2] .else - ldr \out, [tt, \in, lsl #2] + ldr \out, [ttab, \in, lsl #2] .endif .endm @@ -136,7 +136,7 @@ eor r6, r6, r10 eor r7, r7, r11 - __adrl tt, \ttab + __adrl ttab, \ttab tst rounds, #2 bne 1f @@ -146,7 +146,7 @@ 1: subs rounds, rounds, #4 \round r8, r9, r10, r11, r4, r5, r6, r7 - __adrl tt, \ltab, ls + __adrl ttab, \ltab, ls \round r4, r5, r6, r7, r8, r9, r10, r11 bhi 0b