mempool_free(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

mempool_free(9) 🫢

okay so this is mempool_free(9), straight from the Kernel API Manual β€” and it’s literally the β€œgive the element back” bestie of the mempool family. ✨


🌸 NAME 🌸

mempool_free β€” return an element to the pool. πŸ’…

✨ SYNOPSIS ✨

void mempool_free (void *element , struct mempool *pool );

πŸŽ€ ARGUMENTS πŸŽ€

  • element β€” the element to return, bestie. 🫢
  • pool β€” pointer to the memory pool. πŸ‘‘

πŸ’– DESCRIPTION πŸ’–

So here’s the tea: mempool_free returns element to pool if the pool needs replenishing. If it doesn’t, it frees the element using the free_fn callback in pool. no cap. πŸ”₯

And the sleep vibe check: this function only sleeps if the free_fn callback sleeps. πŸ˜΄πŸ’€

πŸ¦‹ SEE ALSO πŸ¦‹

Kernel file ./mm/mempool.c, plus all these iconic references:


mwah πŸ’‹ cute little sign-off: this page’s source/version is ./mm, dated October 2026 β€” mempool_free(9) out! πŸŽ€

πŸ“¦ where this page comes from