[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20090115094926.GA410@gondor.apana.org.au>
Date: Thu, 15 Jan 2009 20:49:26 +1100
From: Herbert Xu <herbert@...dor.apana.org.au>
To: Huang Ying <ying.huang@...el.com>
Cc: Sebastian Siewior <linux-crypto@...breakpoint.cc>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-crypto@...r.kernel.org" <linux-crypto@...r.kernel.org>
Subject: Re: [PATCH crypto -v4 1/2] AES-NI: Add support to access
underlying blkcipher under cryptd ablkcipher
On Thu, Jan 15, 2009 at 05:30:51PM +0800, Huang Ying wrote:
>
> > > Why do we need this check? Someone else may register cryptd template?
> > > Which error number should be return? -EINVAL?
> >
> > -ENOMEM for example.
>
> You mean something as follow:
>
> if (crypto_ablkcipher_tfm(tfm)->__crt_alg->cra_module != THIS_MODULE)
> return ERR_PTR(-ENOMEM);
No I meant that crypto_alloc_ablkcipher can return -ENOMEM.
If the check fails you should return -EINVAL.
Cheers,
--
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@...dor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists