gen_pool_create(9)
π gen_pool_create(9) π
okay so bestie, welcome to the Kernel API Manual β this is the gen_pool_create(9) page and it's literally about making a brand-new special memory pool. buckle up, it's short but it's iconic β¨
πΈ SYNOPSIS πΈ
struct gen_pool * gen_pool_create (int min_alloc_order , int nid );
that's the whole signature, no cap β it hands you back a struct gen_pool * and it takes exactly two ints. slay π«Ά
π ARGUMENTS π
min_alloc_orderβ the log base 2 of the number of bytes that each bitmap bit represents. yes, log base 2, like the exponent vibe β do the math, don't @ me πnidβ the node id of the node your pool structure should be allocated onβ¦ or-1if you're not about that node life π
π¦ DESCRIPTION π¦
okay so here's the tea: this creates a new special memory pool. and what's a special memory pool for, you ask? it manages special purpose memory β aka memory that is not managed by the regular kmalloc/kfree interface. so it's giving main character memory that kmalloc literally cannot touch. periodt πβ¨
π₯ SEE ALSO π₯
the whole gen_pool cinematic universe, bestie β go read these next π
- the kernel file
./lib/genalloc.c(yes, that's where the lore lives π) gen_pool_add_owner(9)gen_pool_virt_to_phys(9)gen_pool_destroy(9)gen_pool_alloc_algo_owner(9)gen_pool_dma_alloc(9)gen_pool_dma_alloc_algo(9)gen_pool_dma_alloc_align(9)gen_pool_dma_zalloc(9)gen_pool_dma_zalloc_algo(9)gen_pool_dma_zalloc_align(9)gen_pool_free_owner(9)gen_pool_for_each_chunk(9)gen_pool_has_addr(9)gen_pool_avail(9)gen_pool_size(9)gen_pool_set_algo(9)gen_pool_first_fit(9)gen_pool_first_fit_align(9)gen_pool_fixed_alloc(9)gen_pool_first_fit_order_align(9)gen_pool_best_fit(9)gen_pool_get(9)devm_gen_pool_create(9)of_gen_pool_get(9)
like, that's the entire friend group and they all ate π π
ngl there's not a ton of drama on this page β no warnings, no bugs section, just a clean little constructor. enjoy it while it lasts, bestie π
and that's the page!! this one came from ./lib and it's dated October 2026, filed under gen_pool_create(9) β mwah, go allocate something cute for me π§πβ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms