]> git.pld-linux.org Git - packages/kernel.git/blobdiff - kernel-regressions.patch
- 4.14.240
[packages/kernel.git] / kernel-regressions.patch
index 8fa69d1a1846f0013b2e9b428ab929972fcc1935..835b02eaf80d3ce939cc44a8969f837c295dece0 100644 (file)
-rom ae060e0b7bc071bd73dd5319b93c3344d9e10212 Mon Sep 17 00:00:00 2001
-From: Manfred Spraul <manfred@colorfullife.com>
-To: torvalds@linux-foundation.org
-Cc: linux-kernel@vger.kernel.org
-Cc: cebbert@redhat.com
-Cc: airlied@gmail.com
-Cc: akpm@linux-foundation.org
-Bcc: manfred@colorfullife.com
-Date: Wed, 10 Dec 2008 18:17:06 +0100
-Subject: [PATCH] lib/idr.c: Fix bug introduced by RCU fix
-
-The last patch to lib/idr.c caused a bug if idr_get_new_above() was
-called on an empty idr:
-Usually, nodes stay on the same layer. New layers are added to the top
-of the tree.
-The exception is idr_get_new_above() on an empty tree: In this case,
-the new root node is first added on layer 0, then moved upwards.
-p->layer was not updated.
-
-As usual: You shall never rely on the source code comments, they
-will only mislead you.
-
-Signed-off-by: Manfred Spraul <manfred@colorfullife.com>
----
- lib/idr.c |    8 +++++++-
- 1 files changed, 7 insertions(+), 1 deletions(-)
-
-diff --git a/lib/idr.c b/lib/idr.c
-index 7a785a0..1c4f928 100644
---- a/lib/idr.c
-+++ b/lib/idr.c
-@@ -220,8 +220,14 @@ build_up:
-        */
-       while ((layers < (MAX_LEVEL - 1)) && (id >= (1 << (layers*IDR_BITS)))) {
-               layers++;
--              if (!p->count)
-+              if (!p->count) {
-+                      /* special case: if the tree is currently empty,
-+                       * then we grow the tree by moving the top node
-+                       * upwards.
-+                       */
-+                      p->layer++;
-                       continue;
-+              }
-               if (!(new = get_from_free_list(idp))) {
-                       /*
-                        * The allocation failed.  If we built part of
--- 
-1.5.6.5
-
-From: Trond Myklebust <Trond.Myklebust@netapp.com>
-Date: Thu, 20 Nov 2008 21:06:21 +0000 (-0500)
-Subject: SUNRPC: Fix a performance regression in the RPC authentication code
-X-Git-Tag: v2.6.28-rc6~4
-X-Git-Url: http://git.kernel.org/?p=linux%2Fkernel%2Fgit%2Ftorvalds%2Flinux-2.6.git;a=commitdiff_plain;h=23918b03060f6e572168fdde1798a905679d2e06
-
-SUNRPC: Fix a performance regression in the RPC authentication code
-
-Fix a regression reported by Max Kellermann whereby kernel profiling
-showed that his clients were spending 45% of their time in
-rpcauth_lookup_credcache.
-
-It turns out that although his processes had identical uid/gid/groups,
-generic_match() was failing to detect this, because the task->group_info
-pointers were not shared. This again lead to the creation of a huge number
-of identical credentials at the RPC layer.
-
-The regression is fixed by comparing the contents of task->group_info
-if the actual pointers are not identical.
-
-Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
-Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
----
-
-diff --git a/net/sunrpc/auth_generic.c b/net/sunrpc/auth_generic.c
-index 744b79f..4028502 100644
---- a/net/sunrpc/auth_generic.c
-+++ b/net/sunrpc/auth_generic.c
-@@ -133,13 +133,29 @@ static int
- generic_match(struct auth_cred *acred, struct rpc_cred *cred, int flags)
- {
-       struct generic_cred *gcred = container_of(cred, struct generic_cred, gc_base);
-+      int i;
+--- linux-4.14/scripts/gcc-plugin.sh.orig      2017-11-12 19:46:13.000000000 +0100
++++ linux-4.14/scripts/gcc-plugin.sh   2021-07-08 09:52:23.460059564 +0200
+@@ -43,7 +43,7 @@
+ esac
  
-       if (gcred->acred.uid != acred->uid ||
-           gcred->acred.gid != acred->gid ||
--          gcred->acred.group_info != acred->group_info ||
-           gcred->acred.machine_cred != acred->machine_cred)
--              return 0;
-+              goto out_nomatch;
-+
-+      /* Optimisation in the case where pointers are identical... */
-+      if (gcred->acred.group_info == acred->group_info)
-+              goto out_match;
-+
-+      /* Slow path... */
-+      if (gcred->acred.group_info->ngroups != acred->group_info->ngroups)
-+              goto out_nomatch;
-+      for (i = 0; i < gcred->acred.group_info->ngroups; i++) {
-+              if (GROUP_AT(gcred->acred.group_info, i) !=
-+                              GROUP_AT(acred->group_info, i))
-+                      goto out_nomatch;
-+      }
-+out_match:
-       return 1;
-+out_nomatch:
-+      return 0;
- }
- void __init rpc_init_generic_auth(void)
+ # we need a c++ compiler that supports the designated initializer GNU extension
+-plugincc=$($2 -c -x c++ -std=gnu++98 - -fsyntax-only -I"${srctree}"/gcc-plugins -I"${gccplugins_dir}"/include 2>&1 <<EOF
++plugincc=$($2 -c -x c++ -std=gnu++11 - -fsyntax-only -I"${srctree}"/gcc-plugins -I"${gccplugins_dir}"/include 2>&1 <<EOF
+ #include "gcc-common.h"
+ class test {
+ public:
+--- linux-4.14/scripts/gcc-plugins/Makefile~   2021-07-08 09:24:22.000000000 +0200
++++ linux-4.14/scripts/gcc-plugins/Makefile    2021-07-08 09:53:18.585669320 +0200
+@@ -7,7 +7,7 @@
+   export HOST_EXTRACFLAGS
+ else
+   HOSTLIBS := hostcxxlibs
+-  HOST_EXTRACXXFLAGS += -I$(GCC_PLUGINS_DIR)/include -I$(src) -std=gnu++98 -fno-rtti
++  HOST_EXTRACXXFLAGS += -I$(GCC_PLUGINS_DIR)/include -I$(src) -std=gnu++11 -fno-rtti
+   HOST_EXTRACXXFLAGS += -fno-exceptions -fasynchronous-unwind-tables -ggdb
+   HOST_EXTRACXXFLAGS += -Wno-narrowing -Wno-unused-variable
+   HOST_EXTRACXXFLAGS += -Wno-format-diag
This page took 0.029176 seconds and 4 git commands to generate.