From 8852e1688327d973800a5f52eea4f85448f40c2e Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Thu, 23 Sep 2021 10:24:46 +0200 Subject: [PATCH] 4.14-stable patches added patches: apparmor-remove-duplicate-macro-list_entry_is_head.patch crypto-talitos-fix-max-key-size-for-sha384-and-sha512.patch --- ...e-duplicate-macro-list_entry_is_head.patch | 40 +++++++++++++++++++ ...x-max-key-size-for-sha384-and-sha512.patch | 38 ++++++++++++++++++ queue-4.14/series | 2 + 3 files changed, 80 insertions(+) create mode 100644 queue-4.14/apparmor-remove-duplicate-macro-list_entry_is_head.patch create mode 100644 queue-4.14/crypto-talitos-fix-max-key-size-for-sha384-and-sha512.patch diff --git a/queue-4.14/apparmor-remove-duplicate-macro-list_entry_is_head.patch b/queue-4.14/apparmor-remove-duplicate-macro-list_entry_is_head.patch new file mode 100644 index 00000000000..674355ab955 --- /dev/null +++ b/queue-4.14/apparmor-remove-duplicate-macro-list_entry_is_head.patch @@ -0,0 +1,40 @@ +From 9801ca279ad37f72f71234fa81722afd95a3f997 Mon Sep 17 00:00:00 2001 +From: Andy Shevchenko +Date: Tue, 15 Dec 2020 20:47:16 -0800 +Subject: apparmor: remove duplicate macro list_entry_is_head() + +From: Andy Shevchenko + +commit 9801ca279ad37f72f71234fa81722afd95a3f997 upstream. + +Strangely I hadn't had noticed the existence of the list_entry_is_head() +in apparmor code when added the same one in the list.h. Luckily it's +fully identical and didn't break builds. In any case we don't need a +duplicate anymore, thus remove it from apparmor code. + +Link: https://lkml.kernel.org/r/20201208100639.88182-1-andriy.shevchenko@linux.intel.com +Fixes: e130816164e244 ("include/linux/list.h: add a macro to test if entry is pointing to the head") +Signed-off-by: Andy Shevchenko +Acked-by: John Johansen +Cc: James Morris +Cc: "Serge E . Hallyn " +Signed-off-by: Andrew Morton +Signed-off-by: Linus Torvalds +Signed-off-by: Nobuhiro Iwamatsu (CIP) +Signed-off-by: Greg Kroah-Hartman +--- + security/apparmor/apparmorfs.c | 3 --- + 1 file changed, 3 deletions(-) + +--- a/security/apparmor/apparmorfs.c ++++ b/security/apparmor/apparmorfs.c +@@ -1900,9 +1900,6 @@ fail2: + return error; + } + +- +-#define list_entry_is_head(pos, head, member) (&pos->member == (head)) +- + /** + * __next_ns - find the next namespace to list + * @root: root namespace to stop search at (NOT NULL) diff --git a/queue-4.14/crypto-talitos-fix-max-key-size-for-sha384-and-sha512.patch b/queue-4.14/crypto-talitos-fix-max-key-size-for-sha384-and-sha512.patch new file mode 100644 index 00000000000..fecccc464ed --- /dev/null +++ b/queue-4.14/crypto-talitos-fix-max-key-size-for-sha384-and-sha512.patch @@ -0,0 +1,38 @@ +From 192125ed5ce62afba24312d8e7a0314577565b4a Mon Sep 17 00:00:00 2001 +From: Christophe Leroy +Date: Wed, 12 Jun 2019 05:49:50 +0000 +Subject: crypto: talitos - fix max key size for sha384 and sha512 +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +From: Christophe Leroy + +commit 192125ed5ce62afba24312d8e7a0314577565b4a upstream. + +Below commit came with a typo in the CONFIG_ symbol, leading +to a permanently reduced max key size regarless of the driver +capabilities. + +Reported-by: Horia Geantă +Fixes: b8fbdc2bc4e7 ("crypto: talitos - reduce max key size for SEC1") +Signed-off-by: Christophe Leroy +Reviewed-by: Horia Geantă +Signed-off-by: Herbert Xu +Signed-off-by: Nobuhiro Iwamatsu (CIP) +Signed-off-by: Greg Kroah-Hartman +--- + drivers/crypto/talitos.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/drivers/crypto/talitos.c ++++ b/drivers/crypto/talitos.c +@@ -816,7 +816,7 @@ static void talitos_unregister_rng(struc + * HMAC_SNOOP_NO_AFEA (HSNA) instead of type IPSEC_ESP + */ + #define TALITOS_CRA_PRIORITY_AEAD_HSNA (TALITOS_CRA_PRIORITY - 1) +-#ifdef CONFIG_CRYPTO_DEV_TALITOS_SEC2 ++#ifdef CONFIG_CRYPTO_DEV_TALITOS2 + #define TALITOS_MAX_KEY_SIZE (AES_MAX_KEY_SIZE + SHA512_BLOCK_SIZE) + #else + #define TALITOS_MAX_KEY_SIZE (AES_MAX_KEY_SIZE + SHA256_BLOCK_SIZE) diff --git a/queue-4.14/series b/queue-4.14/series index b42a07ad2c1..62f992f9f04 100644 --- a/queue-4.14/series +++ b/queue-4.14/series @@ -1,2 +1,4 @@ s390-bpf-fix-optimizing-out-zero-extensions.patch rcu-fix-missed-wakeup-of-exp_wq-waiters.patch +apparmor-remove-duplicate-macro-list_entry_is_head.patch +crypto-talitos-fix-max-key-size-for-sha384-and-sha512.patch -- 2.47.3