__end_cred_crit_section(9)
π
__end_cred_crit_section β Kernel API Manual, section 9, bestie
okay so picture this: you're in the kernel, you opened a crit section, and now you gotta close it. that's literally her whole job. she's the closing bracket energy of the AppArmor cred world π
β¨ NAME β¨
__end_cred_crit_section β bestie, this is the one that ends the crit section that __begin_... started. that's it, that's the vibe. π¦
β¨ SYNOPSIS β¨
void __end_cred_crit_section (struct aa_label *label , bool needput );
look at her. two arguments. no notes. iconic. π
β¨ ARGUMENTS β¨
labelβ the label you got from__begin_cred_crit_section. like, the same one. don't be out here inventing labels, okay? π«Άneedputβ this is an output: aboolthat gets set by__begin_cred_crit_section. so__beginhands you this lil truthy flag and you pass it right back in here. it's giving "you dropped this π" energy.
β¨ DESCRIPTION β¨
okay so the cred you passed to __begin is guaranteed to not change β that part's locked in, no cap. π₯
and like, sure, technically the cred and the label could both be passed here instead of needput. but here's the thing β using needput with a local var makes it so much easier for the compiler and the processor to optimize and speculatively execute the comparison than chasing a pointer around inside the cred struct. π§
so it's not just quirky, it's fast. it's giving "she's pretty AND she's efficient." π β¨
β¨ SEE ALSO β¨
- Kernel file
./security/apparmor/include/cred.hβ go read it, iykyk π aa_get_newest_cred_label(9)aa_current_raw_label(9)aa_get_current_label(9)__begin_cred_crit_section(9)β the other half of this duo π«Ά__end_current_label_crit_section(9)end_current_label_crit_section(9)__begin_current_label_crit_section(9)begin_current_label_crit_section(9)
fr fr, this is a begin/end pair. if you call__endwithout the matching__begin, that's a you problem and not a cute one. π
mwah π that's all from the ./security/apparmor/include girlies β this page was dated October 2026, in the Kernel API Manual, and she's __end_cred_crit_section(9) if you need her again. periodt. ππ
π¦ 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