From patchwork Sat Jun 30 00:01:41 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eric Biggers X-Patchwork-Id: 10497759 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 8B62B602CC for ; Sat, 30 Jun 2018 00:05:06 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8A5EC295F5 for ; Sat, 30 Jun 2018 00:05:06 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7E388296A9; Sat, 30 Jun 2018 00:05:06 +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 32A00295F5 for ; Sat, 30 Jun 2018 00:05:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S936886AbeF3AFF (ORCPT ); Fri, 29 Jun 2018 20:05:05 -0400 Received: from mail-pl0-f66.google.com ([209.85.160.66]:42721 "EHLO mail-pl0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S936859AbeF3AFD (ORCPT ); Fri, 29 Jun 2018 20:05:03 -0400 Received: by mail-pl0-f66.google.com with SMTP id y15-v6so3296487pll.9 for ; Fri, 29 Jun 2018 17:05:03 -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:in-reply-to:references; bh=DG4WPwQX14m/4Du/4Ght/TeELIX+PF+JPZ+M7W+EMc4=; b=XC+EIDHKWae3/rHGVxIwdaQTvW+Bo+IK86jgsGyHgKBcLrjj6Yfs4TQE1xizFq1wKG JQSjZOzTU68FD2AkdwL83NxfeIweDwuxB7T1/ja3MWgUFERMWKxrBnOAPGxQogjmCjxn /amu3KrYG4l5XACfhBnrjOdYYOalVsLOKROaXM9sXHq7fR2XodZfpo5AsgJUz27vHiJI GSsK940YnbKjdOXKMiqqz8sFvjk5kzD1iucoqNx3kyoC5/Jm0wx0hLY6HTJ64RVF9DDm hc1AjB9J1J7bTViHPKDEGma6J/XkmVsj26vaZtnWD+JtrDgVpDhZGqPwRsNgIpr2mrH3 itLg== 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=DG4WPwQX14m/4Du/4Ght/TeELIX+PF+JPZ+M7W+EMc4=; b=aLhUFlORGGkcCyqtgG0vZ/0MPhbkJaPqBiyoQNR1F272+DzJl9rSDKTf84CjyclpIW 9p6FiNXKt6PzvFE55hSU7KUzGukhfXcFhu3agA2gC8uRBUYaYIA1/MFjjQC8Hxcxenf+ RRQjiaYIta46D0wwGpWNCKKzK+z0FDaf07PFP3AfRlR9BTRTmDUgtYph3Uk0jr19QQtC IHy/faxHnXOgCocY47dBpxTPBHis35AGlHsjOoGHORdN5dFVquhtexGJ3CsL0G3eVRz2 BnK3Bxb7+QjgHbtFRy8JwFDulO3ybh3RvodUaivWfhl7K+jQlk2umSOaoS44gOMGVSje vcSg== X-Gm-Message-State: APt69E2sm9iAqSw57FkAJuOMHRmn6sfu4o49N7g1e3BQf56xbcbDX9wW HoEpNjPTBrJGvhPqMk17iW6eoxqZ X-Google-Smtp-Source: ADUXVKIew3OXqAy0sJB2fyXcwLuyq99cq3L9MehqkCHuOoQLwmidBnrYSJ+i+56R8FAOmA3dxIMO1g== X-Received: by 2002:a17:902:7202:: with SMTP id ba2-v6mr16563408plb.119.1530317103228; Fri, 29 Jun 2018 17:05:03 -0700 (PDT) Received: from ebiggers-linuxstation.kir.corp.google.com ([2620:15c:17:3:dc28:5c82:b905:e8a8]) by smtp.gmail.com with ESMTPSA id j13-v6sm16335788pgq.73.2018.06.29.17.05.02 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 29 Jun 2018 17:05:02 -0700 (PDT) From: Eric Biggers To: linux-crypto@vger.kernel.org, Herbert Xu Cc: Megha Dey , Tim Chen , Eric Biggers Subject: [PATCH 1/4] crypto: sha1_generic - add cra_priority Date: Fri, 29 Jun 2018 17:01:41 -0700 Message-Id: <20180630000144.62230-2-ebiggers3@gmail.com> X-Mailer: git-send-email 2.18.0.399.gad0ab374a1-goog In-Reply-To: <20180630000144.62230-1-ebiggers3@gmail.com> References: <20180630000144.62230-1-ebiggers3@gmail.com> 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: Eric Biggers sha1-generic had a cra_priority of 0, so it wasn't possible to have a lower priority SHA-1 implementation, as is desired for sha1_mb which is only useful under certain workloads and is otherwise extremely slow. Change it to priority 100, which is the priority used for many of the other generic algorithms. Signed-off-by: Eric Biggers --- crypto/sha1_generic.c | 1 + 1 file changed, 1 insertion(+) diff --git a/crypto/sha1_generic.c b/crypto/sha1_generic.c index 6877cbb9105f..a3d701632ca2 100644 --- a/crypto/sha1_generic.c +++ b/crypto/sha1_generic.c @@ -76,6 +76,7 @@ static struct shash_alg alg = { .base = { .cra_name = "sha1", .cra_driver_name= "sha1-generic", + .cra_priority = 100, .cra_flags = CRYPTO_ALG_TYPE_SHASH, .cra_blocksize = SHA1_BLOCK_SIZE, .cra_module = THIS_MODULE,