kexec_add_buffer(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– kexec_add_buffer(9) πŸ’–

okay so bestie, this page is from the Kernel API Manual, and it's literally about putting a buffer into a kexec segment. lowkey iconic kernel business. no cap.


🌸 NAME 🌸

kexec_add_buffer β€” place a buffer in a kexec segment. that's the whole vibe.


✨ SYNOPSIS ✨

int kexec_add_buffer (struct kexec_buf *kbuf );

🫢 ARGUMENTS 🫢

  • kbuf β€” buffer contents and memory parameters. it's giving "everything you need to describe the buffer and where it goes" energy.

πŸ¦‹ DESCRIPTION πŸ¦‹

so here's the tea: this function assumes that kexec_lock is held. like, it's not out here grabbing the lock itself, bestie. that's on you. πŸ”₯

on successful return, kbuf->mem will have the physical address of the buffer in memory. so after it slays, you can peek at kbuf->mem and that's where the buffer physically lives. periodt.


πŸŽ€ RETURN πŸŽ€

  • 0 on success β€” ate, no notes. πŸ’…
  • negative errno on error β€” it's giving "something went wrong" and you should check that errno. 😭

πŸ‘‘ SEE ALSO πŸ‘‘


this little manual page is from ./kernel, dated October 2026 β€” mwah, stay hydrated and hold your locks correctly πŸ’‹βœ¨

πŸ“¦ where this page comes from