STRUCT TTM_GLOBAL(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

🌸 struct ttm_global(9) 🌸

okay so bestie, welcome to the Kernel API Manual β€” yes, that's the manual name, and yes, we're literally reading kernel docs together, this is our thing now πŸ’…


✨ NAME ✨

struct ttm_global β€” the buffer object driver's global data, like the group chat settings for the whole driver, no cap 🫢


πŸ¦‹ SYNOPSIS πŸ¦‹

struct ttm_global {
    struct page *dummy_read_page;
    struct list_head device_list;
    atomic_t bo_count;
};

three members, all iconic in their own way, let's get into it ⭐


πŸŽ€ Members πŸŽ€

  • dummy_read_page β€” a struct page *, i.e. a pointer to a dummy page that gets used when somebody maps requests for pages that are unpopulated (empty, no vibes, nothing home). and here's the key part bestie: it's constant after init β€” set it once at init and then leave it alone, periodt πŸ™ˆ
  • device_list β€” a struct list_head holding the list of buffer object devices. it is protected by ttm_global_mutex πŸ”₯ so like, respect the lock or it's giving chaos, fr fr
  • bo_count β€” an atomic_t with the number of buffer objects allocated by devices. literally just a count, but make it atomic πŸ’€

🌈 SEE ALSO 🌈

  • Kernel file ./include/drm/ttm/ttm_device.h
  • struct ttm_device(9)

πŸ’– reminder bestie: dummy_read_page stays constant after init, and device_list lives and dies by ttm_global_mutex. no shortcuts 🫢

and that's the whole page! this little gem lives in ./include/drm/ttm and the docs are dated October 2026, filed under struct ttm_global(9) β€” mwah, go read your kernel headers, ily, bye πŸ‘‘βœ¨πŸ“

πŸ“¦ where this page comes from