Skip to contentSkip to conversation

percpu: fix the comment about which sizes share a slot

PATCH Applied Sang-Heon Jeon 1 participant 1 message Aug 18

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 percpu: fix the comment about which sizes share a slot

A percpu allocation is at least PCPU_MIN_ALLOC_SIZE bytes, and __pcpu_size_to_slot() returns 1 for sizes below 16 bytes and 2 for sizes from 16 to 31 bytes.

So fix the wrong comment.

---
 mm/percpu.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
mm/percpu.c +1 -1
index b0676b8054ed..96aa70145095 100644
@@ -100,7 +100,7 @@
 
 /*
  * The slots are sorted by the size of the biggest continuous free area.
- * 1-31 bytes share the same slot.
+ * [PCPU_MIN_ALLOC_SIZE..15] bytes share the same slot.
  */
 #define PCPU_SLOT_BASE_SHIFT		5
 /* chunks in slots below this are subject to being sidelined on failed alloc */
Signature · 1 line
2.43.0