LKML Archive on lore.kernel.org
 help / color / Atom feed
From: Herbert Xu <herbert@gondor.apana.org.au>
To: Megha Dey <megha.dey@linux.intel.com>
Cc: linux-kernel@vger.kernel.org, linux-crypto@vger.kernel.org,
	megha.dey@intel.com
Subject: Re: [RFC] crypto: Remove mcryptd
Date: Fri, 20 Jul 2018 11:53:25 +0800
Message-ID: <20180720035325.m5tzeuqsfej3y6wd@gondor.apana.org.au> (raw)
In-Reply-To: <1526089453-6542-1-git-send-email-megha.dey@linux.intel.com>

On Fri, May 11, 2018 at 06:44:13PM -0700, Megha Dey wrote:
>
> +static struct ahash_alg *simd_ahash_create_compat(const char *algname,
> +						       const char *drvname,
> +						       const char *basename)
> +{
> +	struct ahash_alg *alg;
> +	struct ahash_alg *ialg;
> +	int err;

I think there has been a misunderstsanding.  You're not actually
using the simd wrapper here.  All you're doing is creating a function
with the word simd in its name.  In all other respects this is just
exposing the underlying algorithm to users directly, which cannot
work because the underlying algorithm requires SIMD.

What you need to do is create an actual simd wrapper with cryptd
and all the functions that may do SIMD work needs to invoke cryptd
if may_use_simd() (and other conditions) is false.

This wrapper should live in crypto/simd.c.

Cheers,
-- 
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

  parent reply index

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-12  1:44 Megha Dey
2018-05-31 18:15 ` Megha Dey
2018-07-20  3:53 ` Herbert Xu [this message]
2018-07-27  0:25   ` Megha Dey
2018-08-08  9:56     ` Herbert Xu
2018-08-10  2:40       ` Megha Dey
2018-08-16  6:55         ` Herbert Xu

Reply instructions:

You may reply publically to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180720035325.m5tzeuqsfej3y6wd@gondor.apana.org.au \
    --to=herbert@gondor.apana.org.au \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=megha.dey@intel.com \
    --cc=megha.dey@linux.intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

LKML Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/lkml/0 lkml/git/0.git
	git clone --mirror https://lore.kernel.org/lkml/1 lkml/git/1.git
	git clone --mirror https://lore.kernel.org/lkml/2 lkml/git/2.git
	git clone --mirror https://lore.kernel.org/lkml/3 lkml/git/3.git
	git clone --mirror https://lore.kernel.org/lkml/4 lkml/git/4.git
	git clone --mirror https://lore.kernel.org/lkml/5 lkml/git/5.git
	git clone --mirror https://lore.kernel.org/lkml/6 lkml/git/6.git
	git clone --mirror https://lore.kernel.org/lkml/7 lkml/git/7.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 lkml lkml/ https://lore.kernel.org/lkml \
		linux-kernel@vger.kernel.org linux-kernel@archiver.kernel.org
	public-inbox-index lkml


Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-kernel


AGPL code for this site: git clone https://public-inbox.org/ public-inbox