Linux cryptographic layer development
 help / color / mirror / Atom feed
From: Phil Sutter <phil@nwl.cc>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: linux-crypto@vger.kernel.org, Chuck Ebbert <cebbert@redhat.com>,
	Nico Erfurth <ne@erfurth.eu>,
	Harald Welte <HaraldWelte@viatech.com>,
	Michal Ludvig <michal@logix.cz>
Subject: Re: [PATCH] crypto: padlock: fix for non-64byte aligned data
Date: Tue, 7 Dec 2010 11:41:41 +0100	[thread overview]
Message-ID: <20101207104141.GA24946@orbit.nwl.cc> (raw)
In-Reply-To: <20101202061441.GA22378@gondor.apana.org.au>

Hi,

On Thu, Dec 02, 2010 at 02:14:41PM +0800, Herbert Xu wrote:
> > Yes, it does, but triggering the bug is not really trivial. I've had
> > best results with a speed testing tool using the asynchronous interface,
> > memory corruption occured in each run. The same tool operating
> > synchronously doesn't crash as soon, but having three or more instances
> > running in parallel yields the same result.
> > 
> > This problem is so racey, a simple printk statement at the beginning of
> > padlock_xcrypt_ecb() fixes it. Enclosing the same function's content in
> > lock_kernel()/unlock_kernel() statements helps as well.
> 
> Interesting.  Do you have preemption enabled?

Yes, CONFIG_PREEMPT is active in my test system's kernel.

> Can you share the test program with us?

You can get it along with the actual cryptodev-implementation at
http://repo.or.cz/w/cryptodev-linux.git. I've been testing with speed.c
and async_speed.c, both can be found inside the examples directory.

Greetings, Phil

  reply	other threads:[~2010-12-07 10:41 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-04 17:50 [PATCH] crypto: padlock: fix for non-64byte aligned data Phil Sutter
2010-11-04 18:46 ` Herbert Xu
2010-11-05 14:12   ` Phil Sutter
2010-12-02  6:14     ` Herbert Xu
2010-12-07 10:41       ` Phil Sutter [this message]
2010-12-07 11:39         ` Herbert Xu
2010-12-07 13:40           ` Phil Sutter
2010-12-08  0:08             ` Harald Welte
2010-12-08  1:52               ` Herbert Xu

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=20101207104141.GA24946@orbit.nwl.cc \
    --to=phil@nwl.cc \
    --cc=HaraldWelte@viatech.com \
    --cc=cebbert@redhat.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-crypto@vger.kernel.org \
    --cc=michal@logix.cz \
    --cc=ne@erfurth.eu \
    /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