public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Chris Mason <chris.mason@oracle.com>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: dwmw2@infradead.org, austin_zhang@linux.intel.com,
	davem@davemloft.net, linux-kernel@vger.kernel.org,
	linux-crypto@vger.kernel.org
Subject: Re: [PATCH] Using Intel CRC32 instruction to accelerate CRC32c	algorithm by new crypto API.
Date: Mon, 04 Aug 2008 12:14:56 -0400	[thread overview]
Message-ID: <1217866496.29139.75.camel@think.oraclecorp.com> (raw)
In-Reply-To: <E1KQ2D2-0003Fn-00@gondolin.me.apana.org.au>

On Mon, 2008-08-04 at 23:42 +0800, Herbert Xu wrote:
> Chris Mason <chris.mason@oracle.com> wrote:
> >
> >>From a performance point of view I'm probably reading the crypto API
> > code wrong, but it looks like my choices are to either have a long
> > standing context and use locking around the digest/hash calls to protect
> > internal crypto state, or create a new context every time and take a
> > perf hit while crypto looks up the right module.
> 
> You're looking at the old hash interface.  New users should use the
> ahash interface which was only recently added to the kernel.  It
> lets you store the state in the request object which you pass to
> the algorithm on every call.  This means that you only need one
> tfm in the entire system for crc32c.
> 

Great to hear, that solves my main concern then.  There is still the
embedded argument against needing all of crypto api just for libcrc32c.

It does make sense to me to have a libcrc32c that does the HW detection
and uses HW assist when present, and just have the cypto api call that.

-chris



  reply	other threads:[~2008-08-04 16:16 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-04  9:35 [PATCH] Using Intel CRC32 instruction to accelerate CRC32c algorithm by new crypto API Austin Zhang
2008-08-04 10:12 ` David Woodhouse
2008-08-04 10:25   ` Sebastian Siewior
2008-08-04 10:27     ` David Woodhouse
2008-08-04 10:48     ` Herbert Xu
2008-08-04 10:35   ` Austin Zhang
2008-08-04 10:45     ` David Woodhouse
2008-08-04 10:58       ` Austin Zhang
2008-08-04 11:25         ` David Woodhouse
2008-08-04 13:45       ` Chris Mason
2008-08-04 15:42         ` Herbert Xu
2008-08-04 16:14           ` Chris Mason [this message]
2008-08-04 16:45             ` Herbert Xu
2008-08-04 17:06               ` Arjan van de Ven
2008-08-04 17:10                 ` Herbert Xu
2008-08-04 17:13                   ` Herbert Xu
2008-08-05 11:10                     ` Helge Hafting
2008-08-05 14:04                       ` Herbert Xu
2008-08-04 18:02           ` Benoit Boissinot
2008-08-05  2:08             ` Herbert Xu
2008-08-04 14:04       ` Herbert Xu
2008-08-04 14:20         ` Arjan van de Ven
2008-08-04 14:49           ` David Woodhouse
2008-08-04 14:54             ` Herbert Xu
2008-08-04 15:12           ` Herbert Xu
2008-08-04 14:13 ` David Woodhouse
2008-08-04 14:17   ` Herbert Xu
2008-08-05  9:51   ` Austin Zhang
2008-08-04 14:18 ` Herbert Xu
2008-08-04 14:19 ` Herbert Xu
2008-08-05  9:59   ` Austin Zhang
2008-08-05 10:44     ` Herbert Xu
2008-08-04 17:27 ` Randy Dunlap
2008-08-05 10:12   ` Austin Zhang

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=1217866496.29139.75.camel@think.oraclecorp.com \
    --to=chris.mason@oracle.com \
    --cc=austin_zhang@linux.intel.com \
    --cc=davem@davemloft.net \
    --cc=dwmw2@infradead.org \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@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