from_kprojid_munged(9)
πΈ from_kprojid_munged(9) πΈ
okay so bestie, welcome to the Kernel API Manual β this page is literally all about from_kprojid_munged, and by the end you're gonna be so comfy with projids it's giving main character energy π
β¨ NAME β¨
from_kprojid_munged β Create a projiid from a kprojid user-namespace pair. π«Ά
π¦ SYNOPSIS π¦
projid_t from_kprojid_munged (struct user_namespace *targ , kprojid_t kprojid );
π ARGUMENTS π
targβ the user namespace we want a projid in. like, the destination vibe check πkprojidβ the kernel internal projid to start with. this is your raw ingredient, no cap π
π DESCRIPTION π
So what does it actually do? Map kprojid into the user-namespace specified by targ and return the resulting projid. That's the whole plot. Slay. β¨
There is always a mapping into the initial user_namespace. always. it's iconic like that π
Unlike from_kprojid, from_kprojid_munged never fails and always returns a valid projid. never ever, fr fr. This makes from_kprojid_munged appropriate for use in syscalls like stat and where failing the system call and failing to provide a valid projid are not an options. like, sometimes you just cannot come back empty-handed, and this function gets it π
heads up bestie: ifkprojidhas no mapping intarg, thenOVERFLOW_PROJIDis returned. that's your fallback value, and no, there's no error code to check β it's just the overflow projid, periodt π
π₯ SEE ALSO π₯
Kernel file ./kernel/user_namespace.c πΈ
make_kuid(9)from_kuid(9)from_kuid_munged(9)make_kgid(9)from_kgid(9)from_kgid_munged(9)make_kprojid(9)from_kprojid(9)verify_root_map(9)
go read those too, iykyk π§
k that's the whole page bestie, and here's your cute little sign-off: this one comes from ./kernel, dated October 2026, and it's filed under from_kprojid_munged(9). take care of her ππ
π¦ 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