kcalloc(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ kcalloc ✨

okay so bestie, welcome to the kcalloc(9) page β€” it's the allocate memory for an array girlie, and the memory is set to zero. the way that's literally in the NAME section. iconic. πŸ’…


🌸 NAME 🌸

kcalloc β€” allocate memory for an array. The memory is set to zero. no cap, that's the whole vibe: you get an array's worth of bytes, and every single one of them is a zero. clean slate energy. 🫢


πŸŽ€ SYNOPSIS πŸŽ€

kcalloc (n , size , flags );

πŸ’– ARGUMENTS πŸ’–

  • n β€” number of elements. how many things are we putting in this array, bestie? that count. πŸ”’
  • size β€” element size. how big is each one of those things. πŸ“
  • flags β€” the type of memory to allocate (see kmalloc). this is where you tell it what kind of memory behaviour you want, and the deets live over on the kmalloc page, iykyk. 🚩

πŸ¦‹ SEE ALSO πŸ¦‹

Kernel file ./include/linux/slab.h β€” and while you're there, go visit the whole friend group:


and that's the page, bestie, you ate. πŸ“ the source/version situation is ./include/linux, and the date on this one is October 2026 β€” mwah, see u in the kernel tree πŸ‘‘πŸŒˆβ­

πŸ“¦ where this page comes from