[PATCH 1/3] kfifo: Fix the description of kfifo_alloc()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The 'size' parameter of kfifo_alloc() does not need to be a power of 2. If
it is not, it will be rounded up to the next power of 2 automatically, as
already correctly explained a few lines below.

Signed-off-by: Christophe JAILLET <christophe.jaillet@xxxxxxxxxx>
---
 include/linux/kfifo.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/linux/kfifo.h b/include/linux/kfifo.h
index fd743d4c4b4b..54fbe2ae6fbd 100644
--- a/include/linux/kfifo.h
+++ b/include/linux/kfifo.h
@@ -349,7 +349,7 @@ __kfifo_uint_must_check_helper( \
 /**
  * kfifo_alloc - dynamically allocates a new fifo buffer
  * @fifo: pointer to the fifo
- * @size: the number of elements in the fifo, this must be a power of 2
+ * @size: the number of elements in the fifo
  * @gfp_mask: get_free_pages mask, passed to kmalloc()
  *
  * This macro dynamically allocates a new fifo buffer.
-- 
2.49.0





[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux