GLOBAL GRAPHICS TRANSLATION TABLE (GGTT)(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… Global Graphics Translation Table (GGTT) β€” from the Kernel API Manual, section 9 πŸŽ€

okay bestie, welcome to GGTT(9) β€” this is the Kernel API Manual page for the Global Graphics Translation Table, and honestly? it's giving main-character memory-management energy ✨


🌸 DESCRIPTION 🌸

So the Xe GGTT is the vibe check for a Global Virtual Address space β€” like, it's the address space that's reserved for resources that only privileged (i.e. kernel-mode) processes get to touch, and it is not tied to any specific user-level process. Lowkey exclusive. πŸ’… For example, the Graphics micro-Controller (GuC) and the Display Engine (if present) are the ones utilizing this Global address space. iykyk.

The Global GTT (GGTT) translates from the Global virtual address to a physical address that can be accessed by HW. And the GGTT itself? It's a flat, single-level table. no nesting, no drama, just vibes. πŸ¦‹

Xe implements a simplified version of the GGTT that specifically manages only a certain range of it β€” the range that goes from the Write Once Protected Content Memory (WOPCM) Layout to a predefined GUC_GGTT_TOP. We do this on purpose, fr fr, because it avoids all the complications related to the GuC (Graphics Microcontroller) hardware limitations. 🫢

Here's the tea on the GuC address space: it's limited on both ends of the GGTT, because the GuC shim HW redirects accesses to those addresses to other HW areas instead of going through the GGTT. Iconic of it, honestly.

  • On the bottom end, the GuC can't access offsets below the WOPCM size 🚫
  • On the top side, the limit is fixed at GUC_GGTT_TOP πŸ›‘

To keep things simple, instead of checking each object to see if they are accessed by GuC or not, we just exclude those areas from the allocator. efficiency queen πŸ‘‘βœ¨

Plus β€” and this is the part that ate β€” to simplify the driver load, we use the maximum WOPCM size in this logic instead of the programmed one, so we don't need to wait until the actual size to be programmed is determined (which requires FW fetch) before initializing the GGTT. Not me avoiding a whole blocking dependency πŸ˜­πŸ™ˆ

These simplifications might waste space in the GGTT (about 20-25 MBs depending on the platform) but we can live with this. πŸ’€ it's fine. we're fine.

Another benefit of this: the GuC bootrom can't access anything below the WOPCM max size, so anything the bootrom needs to access (e.g. a RSA key) needs to be placed in the GGTT above the WOPCM max size. Starting the GGTT allocations above the WOPCM max gives us the correct placement for free. slay. no cap. πŸ”₯


✨ SEE ALSO ✨

Kernel file ./drivers/gpu/drm/xe/xe_ggtt.c β€” go read the source, bestie, it's all in there 🧚


okay that's the whole page, bestie β€” you're officially GGTT-literate πŸ’œ

this lil masterpiece lives in ./drivers/gpu/drm/xe and it's dated October 2026, brought to you by the Kernel API Manual, section 9. mwah 😘 πŸŽ€πŸ¦‹πŸŒΈ

πŸ“¦ where this page comes from