netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
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.

  reply	other threads:[~2015-03-14 12:16 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1426266882-31626-1-git-send-email-horia.geanta@freescale.com>
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

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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).