Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 878a2fd9 authored by Eric Biggers's avatar Eric Biggers
Browse files

FROMGIT: dm crypt: log the encryption algorithm implementation



Log the encryption algorithm's driver name when a dm-crypt target is
created.  This will help people determine whether the expected
implementation is being used.  In some cases we've seen people do
benchmarks and reject using encryption for performance reasons, when in
fact they used a much slower implementation than was possible on the
hardware.  It can make an enormous difference; e.g., AES-XTS on ARM can
be over 10x faster with the crypto extensions than without.  It can also
be useful to know if an implementation using an external crypto
accelerator is being used instead of a software implementation.

Example message:

[   29.307629] device-mapper: crypt: xts(aes) using implementation "xts-aes-ce"

We've already found the similar message in fs/crypto/keyinfo.c to be
very useful.

Signed-off-by: default avatarEric Biggers <ebiggers@google.com>
Signed-off-by: default avatarMike Snitzer <snitzer@redhat.com>

(cherry picked from commit 32bbca787931a371256ac51219a6e9c9dbc86960
 https://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm.git

 for-next)
Test: Verified that the message is logged when dm-crypt is used.
Change-Id: I20857a5350266431924e177dea50418aeb95009d
Signed-off-by: default avatarEric Biggers <ebiggers@google.com>
parent 61dd8130
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment