From 5c925e8b10a5f43f220755aceb9d5f14b2f4e2c5 Mon Sep 17 00:00:00 2001 From: Eric Biggers Date: Mon, 30 Dec 2019 21:19:35 -0600 Subject: crypto: remove CRYPTO_TFM_RES_BAD_BLOCK_LEN The flag CRYPTO_TFM_RES_BAD_BLOCK_LEN is never checked for, and it's only set by one driver. And even that single driver's use is wrong because the driver is setting the flag from ->encrypt() and ->decrypt() with no locking, which is unsafe because ->encrypt() and ->decrypt() can be executed by many threads in parallel on the same tfm. Just remove this flag. Signed-off-by: Eric Biggers Signed-off-by: Herbert Xu --- include/linux/crypto.h | 1 - 1 file changed, 1 deletion(-) (limited to 'include') diff --git a/include/linux/crypto.h b/include/linux/crypto.h index 950b592947b2..719a301af3f2 100644 --- a/include/linux/crypto.h +++ b/include/linux/crypto.h @@ -114,7 +114,6 @@ #define CRYPTO_TFM_REQ_MAY_BACKLOG 0x00000400 #define CRYPTO_TFM_RES_WEAK_KEY 0x00100000 #define CRYPTO_TFM_RES_BAD_KEY_LEN 0x00200000 -#define CRYPTO_TFM_RES_BAD_BLOCK_LEN 0x00800000 /* * Miscellaneous stuff. -- cgit v1.2.3-59-g8ed1b