Le 24/04/2014 01:58, Kim Phillips a écrit :
On Wed, 23 Apr 2014 10:20:16 +0200
leroy christophe christophe.le...@c-s.fr wrote:
I'm altering the Freescale Talitos Driver in order to support the SEC1
security engine, and I have a big issue with the DES test vectors in
testmgr.h:
The Sec Engine
In the Talitos driver, there is a TALITOS_FTR_HMAC_OK flag which is set
only for SEC2.1
Is there any reason for that ?
According to the doc, SEC2 and SEC1 all seems to support HMAC.
However I have tried it on SEC1 and it seems that it doesn't work
properly when wanting to perform a
I'm progressing well on the SEC1 implementation. I now have HASH (non
HMAC) , DES and AES working properly.
So it is now time to look at AEAD.
I don't know much yet about crypto algorithm so forgive me if I ask
stupid questions.
The SEC1 doesn't have the IPSEC descriptor that SEC2 has.
Clean this function up and rework it into sensible shape. This function
now contains one single dev_err() instead of the previous insanity full
of memory allocation, chaotic string handling and use of SPRINTFCAT().
Signed-off-by: Marek Vasut ma...@denx.de
Cc: Herbert Xu
Just dissolve this function so it's not in the way of applying
further white magic cleanup down the line.
Signed-off-by: Marek Vasut ma...@denx.de
Cc: Herbert Xu herb...@gondor.apana.org.au
Cc: Horia Geanta horia.gea...@freescale.com
---
drivers/crypto/caam/error.c | 32
Pass the error type string into the functions, so they can handle
the printing of the string. This is now still using the very unsafe
sprintf(), but we will fix that.
While at this, pass the device pointer too, so we can dev_err()
functions readily when we start fixing this proper.
First stab at reworking the error.c thing in Freescale CAAM.
This patchset cleans it up so it's not doing any too insane
string messing anymore.
NOTE: Can someone please test this on real hardware? I have
none at hand, so THIS IS COMPILE-TESTED ONLY!
Marek Vasut (11):
crypto: caam:
Implement fast-path error code printout for errors with no associated
handler function. This reduces calls to this kmalloc() nonsense in
SPRINTFCAT() already.
Note that the format of output is compatible with the old code, even
if -- exposed like this -- it looks a bit weird. Checkpatch complains
Pull the error code - error string mapping tables out of the function
so the code becomes readable. This lets me see the real flesh of the
functions, without all that flab clouding the view.
Note: There is a checkpatch issue with quoted strings across multiple
lines. I will fix that in a
Clean up the remnants from the rework. Constify function arguments.
Note that checkpatch again complains about this space before newline,
but this is the original code behavior, so I'm keeping it.
Signed-off-by: Marek Vasut ma...@denx.de
Cc: Herbert Xu herb...@gondor.apana.org.au
Cc: Horia
This macro is just like an encyclopedia of string handling done wrong.
This must die. This is so wrong on so many levels.
Signed-off-by: Marek Vasut ma...@denx.de
Cc: Herbert Xu herb...@gondor.apana.org.au
Cc: Horia Geanta horia.gea...@freescale.com
---
drivers/crypto/caam/error.c | 10
The tentacles of this function were firmly attached to various
places in the CAAM code. Just cut them, or this cthulhu function
will sprout them anew.
Signed-off-by: Marek Vasut ma...@denx.de
Cc: Herbert Xu herb...@gondor.apana.org.au
Cc: Horia Geanta horia.gea...@freescale.com
---
Clean this function up and rework it into sensible shape. This function
now contains one single dev_err() instead of the previous insanity full
of memory allocation, possible stack overwriting, chaotic string handling
and use of SPRINTFCAT().
Signed-off-by: Marek Vasut ma...@denx.de
Cc: Herbert
Fix the checkpatch warnings that the strings were split across
multiple lines. Checkpatch now complains about lines over 80,
but this is better, since we can actually grep the source code
for these strings now.
Signed-off-by: Marek Vasut ma...@denx.de
Cc: Herbert Xu herb...@gondor.apana.org.au
CRYPTO_USER requires CAP_NET_ADMIN for all operations. Most information
provided by CRYPTO_MSG_GETALG is also accessible through /proc/modules
and AF_ALG. CRYPTO_MSG_GETALG should not require CAP_NET_ADMIN so that
processes without CAP_NET_ADMIN can use CRYPTO_MSG_GETALG to get cipher
details,
15 matches
Mail list logo