From: "Horia Geantă" <horia.geanta@freescale.com>
To: David Miller <davem@davemloft.net>, <herbert@gondor.apana.org.au>
Cc: <linux-crypto@vger.kernel.org>, <netdev@vger.kernel.org>,
<kim.phillips@freescale.com>
Subject: Re: [PATCH 2/4] net: esp: check CRYPTO_TFM_REQ_DMA flag when allocating crypto request
Date: Sat, 14 Mar 2015 14:16:37 +0200 [thread overview]
Message-ID: <550426A5.4090603@freescale.com> (raw)
In-Reply-To: <20150313.154608.548532696978553073.davem@davemloft.net>
On 3/13/2015 9:46 PM, David Miller wrote:
> From: Horia Geanta <horia.geanta@freescale.com>
> Date: Fri, 13 Mar 2015 19:15:22 +0200
>
>> Some crypto backends might require the requests' private contexts
>> to be allocated in DMA-able memory.
>>
>> Signed-off-by: Horia Geanta <horia.geanta@freescale.com>
>
> No way.
>
> Upper layers should be absolutely not required to know about such
> requirements.
>
> Such details _must_ be hidden inside of the crypto layer and drivers
> and not leak out into the users of the crypto interfaces.
If you look at patch 1/4:
http://www.mail-archive.com/linux-crypto@vger.kernel.org/msg13428.html
that's what's done for {aead,ablkcipher,ahash}_request_alloc().
Thus users (upper layers) that allocate the crypto requests using the
crypto API are unaware of the requirement.
However, ESP is not using aead_request_alloc(). This breaks the
interface and thus some crypto implementation details are not transparent.
next prev parent reply other threads:[~2015-03-14 12:16 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-13 17:14 [PATCH 1/4] crypto: add CRYPTO_TFM_REQ_DMA flag Horia Geanta
2015-03-13 17:15 ` [PATCH 2/4] net: esp: check CRYPTO_TFM_REQ_DMA flag when allocating crypto request Horia Geanta
2015-03-13 19:46 ` David Miller
2015-03-14 12:16 ` Horia Geantă [this message]
2015-03-14 18:27 ` David Miller
2015-03-13 17:16 ` [PATCH 3/4] crypto: talitos - move talitos_{edesc,request} to request private ctx Horia Geanta
2015-03-13 17:16 ` [PATCH 4/4] crypto: talitos - add software backlog queue handling Horia Geanta
2015-03-13 18:37 ` Tom Lendacky
2015-03-14 17:16 ` Horia Geantă
2015-03-16 12:58 ` Martin Hicks
2015-03-13 17:27 ` [PATCH 1/4] crypto: add CRYPTO_TFM_REQ_DMA flag Horia Geantă
Reply instructions:
You may reply publicly 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=550426A5.4090603@freescale.com \
--to=horia.geanta@freescale.com \
--cc=davem@davemloft.net \
--cc=herbert@gondor.apana.org.au \
--cc=kim.phillips@freescale.com \
--cc=linux-crypto@vger.kernel.org \
--cc=netdev@vger.kernel.org \
/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
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.