android_kernel_xiaomi_sm8350/crypto
Jesper Juhl a61cc44812 [CRYPTO] Add null short circuit to crypto_free_tfm
As far as I'm aware there's a general concensus that functions that are
responsible for freeing resources should be able to cope with being passed
a NULL pointer. This makes sense as it removes the need for all callers to
check for NULL, thus elliminating the bugs that happen when some forget
(safer to just check centrally in the freeing function) and it also makes
for smaller code all over due to the lack of all those NULL checks.
This patch makes it safe to pass the crypto_free_tfm() function a NULL
pointer. Once this patch is applied we can start removing the NULL checks
from the callers.

Signed-off-by: Jesper Juhl <juhl-lkml@dif.dk>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
2005-07-06 13:54:31 -07:00
..
aes.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
anubis.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
api.c [CRYPTO] Add null short circuit to crypto_free_tfm 2005-07-06 13:54:31 -07:00
arc4.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
blowfish.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
cast5.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
cast6.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
cipher.c [CRYPTO] Handle unaligned iv from encrypt_iv/decrypt_iv 2005-07-06 13:53:47 -07:00
compress.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
crc32c.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
crypto_null.c [PATCH] crypto: fix null encryption/compression 2005-05-17 07:59:18 -07:00
deflate.c [PATCH] crypto: call zlib end functions on deflate exit path 2005-04-16 15:23:58 -07:00
des.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
digest.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
hmac.c [CRYPTO] Don't check for NULL before kfree() 2005-07-06 13:51:00 -07:00
internal.h [CRYPTO] Ensure cit_iv is aligned correctly 2005-07-06 13:53:29 -07:00
Kconfig [PATCH] uml: support AES i586 crypto driver 2005-05-01 08:58:54 -07:00
khazad.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
Makefile Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
md4.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
md5.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
michael_mic.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
proc.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
scatterwalk.c [CRYPTO] Add plumbing for multi-block operations 2005-07-06 13:51:31 -07:00
scatterwalk.h [CRYPTO] Add alignmask for low-level cipher implementations 2005-07-06 13:52:09 -07:00
serpent.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sha1.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sha256.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sha512.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
tcrypt.c [CRYPTO]: Use CPU cycle counters in tcrypt 2005-06-22 13:29:03 -07:00
tcrypt.h [CRYPTO]: Add cipher speed tests 2005-06-22 13:27:23 -07:00
tea.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
tgr192.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
twofish.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
wp512.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00