cgroupstats_build(9)
π cgroupstats_build(9) β like, the whole glow-up
okay so bestie, welcome to the Kernel API Manual page for cgroupstats_build(9) β this is the function that literally builds a cgroupstats struct and fills it in, and honestly? it's giving backend icon. let's get into it π
β¨ NAME β¨
cgroupstats_build β build and fill cgroupstats π«Ά
πΈ SYNOPSIS πΈ
int cgroupstats_build (struct cgroupstats *stats , struct dentry *dentry
);
that's the whole vibe. two args, one int coming back at you. slay. β¨
π¦ ARGUMENTS π¦
statsβ thecgroupstatsyou're filling information into. it's the main character here, the one getting all the data πdentryβ a dentry entry belonging to the cgroup for which stats have been requested. like, which cgroup are we talking about? this one. no cap. π
π DESCRIPTION π
so what does it actually do? it builds and fills cgroupstats so that taskstats can export it to user space. that's the whole mission statement, bestie β build it, fill it, hand it off so user space can see it. iconic behaviour, fr fr. π
β RETURN β
0on success π- a negative
errnocode on failure π
that's it, that's the contract. check your return value, bestie, i'm begging π
π§ SEE ALSO π§
kernel file ./kernel/cgroup/cgroup-v1.c, plus these absolute legends:
go read those too, iykyk πβ¨
lowkey reminder: always check for that negative errno, because a silently ignored failure is not the vibe. π
mwah π that's the page! brought to you by the source tree at ./kernel/cgroup, in the Kernel API Manual, dated October 2026 β same title, same function, just with way more sparkle. go build some stats, bestie π«Άβ¨π
π¦ 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