percpu: fix a comment about the chunks ordering
authorRoman Gushchin <guro@fb.com>
Thu, 8 Apr 2021 03:57:31 +0000 (20:57 -0700)
committerDennis Zhou <dennis@kernel.org>
Fri, 16 Apr 2021 20:57:49 +0000 (20:57 +0000)
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>
mm/percpu.c

index 23308113a5ff0b72b96f49b04887d2b05f19e405..2c459a0ee5e6d56721ff4c8affa254b50947dbad 100644 (file)
 
 #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