debug_dump(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… debug_dump(9) β€” the Kernel API Manual page, but make it make sense 🫢

okay so bestie, we're in debug_dump(9) territory, which lives in the Kernel API Manual and is honestly kind of a vibe. it's the little function that hands you a textual representation of your debug info β€” or at least as much of it as actually fits in your buffer 😭


✨ SYNOPSIS ✨

ssize_t debug_dump (debug_info_t *id , struct debug_view *view , char
*buf , size_t buf_size , bool reverse );

that's the whole signature, no cap. five arguments, one return value, zero drama (well, mostly).


πŸŽ€ ARGUMENTS πŸŽ€

  • id β€” the debug information you wanna use. the main character of this whole operation πŸ’–
  • view β€” the view you're dumping that debug info with. think of it as the filter/lens situation.
  • buf β€” the buffer where the textual debug data representation gets written. this is where the magic lands ✨
  • buf_size β€” how big that buffer is, including the trailing ' ' byte. yes, including it. count it. πŸ‘‘
  • reverse β€” go backwards from the last written entry. little reverse-chronological moment, we love to see it πŸ¦‹

🌸 DESCRIPTION 🌸

so here's the tea: use this function whenever you need a textual representation of the debug information without touching an s390dbf file. like, no filesystem, no file, just vibes and a buffer. iconic honestly.


🌈 NOTE 🌈

bestie, it's your job β€” the caller's responsibility β€” to supply a view that's compatible with the debug information data. don't come for this function if you hand it a mismatched view, fr fr πŸ™ˆ

⭐ RETURN ⭐

  • on success: you get the number of bytes written to the buffer β€” and that count does not include the trailing ' ' byte. sneaky but fair πŸ’…
  • if bug_size == 0, the function returns 0. (yes, it's written bug_size right there in the manual β€” we do not edit the sacred text 🫢)
  • on failure: you get an error code less than 0. sad girl hours 😭

🧚 SEE ALSO 🧚

the kernel file ./arch/s390/kernel/debug.c, plus the whole friend group:


and that's the page!! mwah πŸ’‹ it ships out of ./arch/s390/kernel, dated October 2026, and it's filed under debug_dump(9) β€” go forth and dump your debug info responsibly, queen πŸ‘‘πŸ’œ

πŸ“¦ where this page comes from