xe_migrate_vram_copy_chunk(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… xe_migrate_vram_copy_chunk(9) β€” like, the whole page

okay so bestie, welcome to the Kernel API Manual ✨ this one's about xe_migrate_vram_copy_chunk(9) and honestly? it's a whole vibe. it copies a chunk of a VRAM buffer object and it does it beautifully. let's get into it 🫢


✨ NAME ✨

xe_migrate_vram_copy_chunk β€” Copy a chunk of a VRAM buffer object. that's it. that's the girl. πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

struct dma_fence * xe_migrate_vram_copy_chunk (struct xe_bo *vram_bo ,
       u64 vram_offset , struct xe_bo *sysmem_bo , u64 sysmem_offset , u64 size
       , enum xe_migrate_copy_dir dir );

look at her go 😭 six whole parameters, main character energy fr fr


πŸŽ€ ARGUMENTS πŸŽ€

  • vram_bo β€” The VRAM buffer object. the source-of-truth bo, the one living its best life in VRAM πŸ‘‘
  • vram_offset β€” The VRAM offset. where in the VRAM bo we're starting, iykyk
  • sysmem_bo β€” The sysmem buffer object. the system-memory counterpart, the other half of the ship πŸ₯Ί
  • sysmem_offset β€” The sysmem offset. where in sysmem we're landing, no cap
  • size β€” The size of VRAM chunk to copy. literally how much we're moving, be precise bestie ⭐
  • dir β€” The direction of the copy operation. which way the data is travelling β€” vibe check on the flow 🌈

🌸 DESCRIPTION 🌸

so what she does is: copies a portion of a buffer object between VRAM and system memory. that's the whole job and she ate πŸ”₯

aaaand one very important detail: on Xe2 platforms that support flat CCS, VRAM data is decompressed when copying to system memory. the way that she just handles decompression for you?? iconic. mentally i'm here 🧚


πŸ’– RETURN πŸ’–

returns a pointer to a dma_fence representing the last copy batch β€” or an error pointer on failure 😭

and listen, important: if there is a failure, any copy operation started by the function call has been synced. so you're not left hanging with a half-finished copy, she's got you πŸ’…

ngl always check for that error pointer, bestie. the fence isn't gonna check itself πŸ™ˆ

πŸ¦„ SEE ALSO πŸ¦„

the whole friendship group 🫢 β€” Kernel file ./drivers/gpu/drm/xe/xe_migrate.c, plus:


and that's the page! πŸŽ€ source: ./drivers/gpu/drm/xe, dated October 2026 β€” mwah, sending you kisses, go copy some chunks bestie πŸ’œβœ¨

πŸ“¦ where this page comes from