aboutsummaryrefslogtreecommitdiff
path: root/mm/percpu.c
diff options
context:
space:
mode:
authorRoman Gushchin2021-04-07 20:57:31 -0700
committerDennis Zhou2021-04-16 20:57:49 +0000
commitac9380f6b8a6a908a9df023bf8a2bcdaf9d2d6cb (patch)
tree58e23211f36e988ac5662a949c4ed4db5fd00163 /mm/percpu.c
parentd434405aaab7d0ebc516b68a8fc4100922d7f5ef (diff)
percpu: fix a comment about the chunks ordering
Since the commit 3e54097beb22 ("percpu: manage chunks based on contig_bits instead of free_bytes") chunks are sorted based on the size of the biggest continuous free area instead of the total number of free bytes. Update the corresponding comment to reflect this. Signed-off-by: Roman Gushchin <guro@fb.com> Signed-off-by: Dennis Zhou <dennis@kernel.org>
Diffstat (limited to 'mm/percpu.c')
-rw-r--r--mm/percpu.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/mm/percpu.c b/mm/percpu.c
index 23308113a5ff..2c459a0ee5e6 100644
--- a/mm/percpu.c
+++ b/mm/percpu.c
@@ -99,7 +99,10 @@
#include "percpu-internal.h"
-/* the slots are sorted by free bytes left, 1-31 bytes share the same slot */
+/*
+ * The slots are sorted by the size of the biggest continuous free area.
+ * 1-31 bytes share the same slot.
+ */
#define PCPU_SLOT_BASE_SHIFT 5
/* chunks in slots below this are subject to being sidelined on failed alloc */
#define PCPU_SLOT_FAIL_THRESHOLD 3