fpstate_realloc(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– NAME πŸ’–

okay bestie, this is fpstate_realloc(9) from the Kernel API Manual β€” and it is literally here to Reallocate struct fpstate for the requested new features. iconic behavior, no cap ✨


πŸ¦‹ SYNOPSIS πŸ¦‹

int fpstate_realloc (u64 xfeatures , unsigned int ksize , unsigned int
       usize , struct fpu_guest *guest_fpu );

πŸŽ€ ARGUMENTS πŸŽ€

  • xfeatures β€” a bitmap of xstate features which extend the enabled features of that task. lowkey the feature wishlist πŸ’…
  • ksize β€” the required size for the kernel buffer. kernel-side room service 🫢
  • usize β€” the required size for user space buffers. user-side space, slay 🌸
  • guest_fpu β€” pointer to a guest FPU container. NULL for host allocations. yes, NULL is valid here, periodt πŸ’œ

🌈 DESCRIPTION 🌈

okay so real talk β€” here's the note vs. vmalloc: if the task with a vzalloc-allocated buffer terminates quickly, vfree-induced IPIs may be a concern, but tasks with large states are likely to live longer. that's the whole vibe check, bestie 🧚


⭐ RETURN ⭐

0 on success, -ENOMEM on allocation error. when it's 0 we celebrate; when it's -ENOMEM we cry a lil 😭


πŸ‘‘ SEE ALSO πŸ‘‘

go read these too, iykyk πŸ’–


and that's the page, bestie πŸŽ€ this cutie comes from ./arch/x86/kernel/fpu, dated October 2026, and it's literally fpstate_realloc(9) β€” byeee πŸ’…βœ¨

πŸ“¦ where this page comes from