From patchwork Tue Jan 17 15:22:30 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ard Biesheuvel X-Patchwork-Id: 91674 Delivered-To: patch@linaro.org Received: by 10.140.20.99 with SMTP id 90csp543162qgi; Tue, 17 Jan 2017 07:23:45 -0800 (PST) X-Received: by 10.98.63.210 with SMTP id z79mr44490269pfj.134.1484666625399; Tue, 17 Jan 2017 07:23:45 -0800 (PST) Return-Path: Received: from bombadil.infradead.org (bombadil.infradead.org. [2001:1868:205::9]) by mx.google.com with ESMTPS id 145si25230864pfa.222.2017.01.17.07.23.45 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 17 Jan 2017 07:23:45 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 2001:1868:205::9 as permitted sender) client-ip=2001:1868:205::9; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org; spf=pass (google.com: best guess record for domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 2001:1868:205::9 as permitted sender) smtp.mailfrom=linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1cTVbr-00030s-JX; Tue, 17 Jan 2017 15:23:43 +0000 Received: from mail-wm0-x234.google.com ([2a00:1450:400c:c09::234]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1cTVbP-0002A8-78 for linux-arm-kernel@lists.infradead.org; Tue, 17 Jan 2017 15:23:17 +0000 Received: by mail-wm0-x234.google.com with SMTP id r144so227513178wme.1 for ; Tue, 17 Jan 2017 07:22:54 -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:in-reply-to:references; bh=Twhl3TaN4Yleujf68Qk0fFCweF7qBJDAw0TmYcZHr54=; b=LaEelGgUYQ8wmmkdPw193rHSBrKGMSTXMpXjBD6ShClf3MC3TZDKbC9CzDdAMUINho +zweqZxTE6WScQvRYIsGnz0TcePXGR5IJTzzxvWlroukP4Jeqw593jq15D0f6K9/GGeX Va/OWP0puIdCi9xt3R3pZErtiLsBt/mog46so= 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:in-reply-to :references; bh=Twhl3TaN4Yleujf68Qk0fFCweF7qBJDAw0TmYcZHr54=; b=MJ4PovakO9MuEOVWHxT5BINtsXMAPs0OfnQYEF+JQLA0oRbqTkPbUfq2YZPvfykHmO pKAf2NonScVPZ/KBLXBht2zLrqHh4UEHRcnS571vjqtIgr0q2S9tv7+JeFaoc3iQMsV2 UIl6SfgXoRNJLW5Acn3hfzJ3zwRdACcGWm8bDFKXsGRm0jv6jFeI5VoF/2fNc7P3Yydy Oackdf1ABp9eGNazKV9FZbp1s9awYSg0+Rjr0O+5/XT/N9smODmoGILhWZA8Bx5JUj9q UAhMxGM3MLHg+Ab6zSf5PhXXjVD3DeQEonwzVXv3sVajSPDrSEmTiTWLEhAz65R4uBMi Iufw== X-Gm-Message-State: AIkVDXISYwR5f220hkJthkTzbWHUaOjm+baprjOBzQtYvs46TKD/b4T4BCucGhlmTpdoPlg8 X-Received: by 10.28.100.70 with SMTP id y67mr15894596wmb.45.1484666573346; Tue, 17 Jan 2017 07:22:53 -0800 (PST) Received: from localhost.localdomain ([160.167.203.25]) by smtp.gmail.com with ESMTPSA id y127sm37590359wmg.12.2017.01.17.07.22.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 17 Jan 2017 07:22:52 -0800 (PST) From: Ard Biesheuvel To: linux-crypto@vger.kernel.org, herbert@gondor.apana.org.au Subject: [PATCH 03/10] crypto: arm/chacha20 - remove cra_alignmask Date: Tue, 17 Jan 2017 15:22:30 +0000 Message-Id: <1484666557-31458-4-git-send-email-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1484666557-31458-1-git-send-email-ard.biesheuvel@linaro.org> References: <1484666557-31458-1-git-send-email-ard.biesheuvel@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170117_072315_538616_8D76D591 X-CRM114-Status: GOOD ( 10.54 ) X-Spam-Score: -2.7 (--) X-Spam-Report: SpamAssassin version 3.4.1 on bombadil.infradead.org summary: Content analysis details: (-2.7 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [2a00:1450:400c:c09:0:0:0:234 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-arm-kernel@lists.infradead.org, Ard Biesheuvel MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org Remove the unnecessary alignmask: it is much more efficient to deal with the misalignment in the core algorithm than relying on the crypto API to copy the data to a suitably aligned buffer. Signed-off-by: Ard Biesheuvel --- arch/arm/crypto/chacha20-neon-glue.c | 1 - 1 file changed, 1 deletion(-) -- 2.7.4 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel diff --git a/arch/arm/crypto/chacha20-neon-glue.c b/arch/arm/crypto/chacha20-neon-glue.c index 592f75ae4fa1..59a7be08e80c 100644 --- a/arch/arm/crypto/chacha20-neon-glue.c +++ b/arch/arm/crypto/chacha20-neon-glue.c @@ -94,7 +94,6 @@ static struct skcipher_alg alg = { .base.cra_priority = 300, .base.cra_blocksize = 1, .base.cra_ctxsize = sizeof(struct chacha20_ctx), - .base.cra_alignmask = 1, .base.cra_module = THIS_MODULE, .min_keysize = CHACHA20_KEY_SIZE,