STRUCT TTM_BO_SHRINK_FLAGS(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… struct ttm_bo_shrink_flags (Kernel API Manual, bestie edition)

okay so real talk β€” this is a page from the Kernel API Manual about struct ttm_bo_shrink_flags, and it's literally just the little flag container that governs the bo shrinking behaviour ✨ like it's the vibe-check clipboard for how a buffer object gets shrunk. no cap, that's the whole assignment.


πŸŽ€ NAME πŸŽ€

struct ttm_bo_shrink_flags β€” flags to govern the bo shrinking behaviour πŸ¦‹


✨ SYNOPSIS ✨

here's the whole struct, copy it exactly bestie:

struct ttm_bo_shrink_flags {
    u32 purge : 1;
    u32 writeback : 1;
    u32 allow_move : 1;
 };

three tiny bitfields, one big mood πŸ‘‘


🌸 Members 🌸

these are the three icons and what each one does:

  • purge β€” purge the content rather than backing it up πŸ’€ like we're NOT keeping a copy, we're just yeeting it. gone. periodt.
  • writeback β€” attempt to immediately write content to swap space πŸ”₯ "immediately" is doing a lot of work in that sentence, but that's what it says.
  • allow_move β€” allow moving to system before shrinking 🧚 this is typically not desired for zombie- or ghost objects β€” and yes, "zombie object" means objects with a zero gem object refcount πŸ’… iykyk. ghost objects get the same treatment, no moving for them.
ngl the allow_move one is the sneaky member β€” it's giving "sure, relocate me first" energy, and for zombie/ghost objects that's exactly what you don't want πŸ™ˆ

πŸ‘‘ SEE ALSO πŸ‘‘

Kernel file ./include/drm/ttm/ttm_bo.h β€” and here's the full squad of friends, all of them, in order:

like that's a whole group chat right there 😭 go read them, they ate 🌈


that's the whole page, bestie β€” go shrink some bos responsibly πŸ’–

this icon dropped from ./include/drm/ttm in October 2026, and the page itself is struct ttm_bo_shrink_flags(9). mwah, bye πŸ«ΆπŸŽ€

πŸ“¦ where this page comes from