svm_migrate_vram_to_ram(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– NAME πŸ’–

okay bestie, this is svm_migrate_vram_to_ram(9), straight from the Kernel API Manual ✨ β€” and its whole main character job is to migrate svm range from device to system. That's the assignment, no cap. 🫢


✨ SYNOPSIS ✨

       int svm_migrate_vram_to_ram (struct svm_range *prange , struct mm_struct
       *mm , unsigned long start_mgr , unsigned long last_mgr , uint32_t
       trigger , struct page *fault_page );

That's the exact signature, so keep it character for character if you're typing it out, fr fr. πŸ’…


🧚 ARGUMENTS 🧚

  • prange β€” the range structure, aka the thing getting migrated. main character energy πŸ’œ
  • mm β€” the process mm; if it's NULL, use current->mm. easy enough πŸŒ€
  • start_mgr β€” the start page that needs to be migrated to sys ram. πŸ“Œ
  • last_mgr β€” the last page that needs to be migrated to sys ram. 🏁
  • trigger β€” the reason of migration. iykyk πŸ‘€
  • fault_page β€” comes from vmf->page, svm_migrate_to_ram; this is the CPU page fault callback. very demure, very mindful 😭

🌸 CONTEXT 🌸

Process context, bestie β€” the caller holds the mmap read lock and prange->migrate_mutex. do not forget either one, fr fr. 😀


πŸŽ€ RETURN πŸŽ€

0 β€” OK, otherwise error code. That's it. slay ✨


πŸ¦‹ SEE ALSO πŸ¦‹

go read these too, bestie β€” the lore is real. πŸ“šπŸ’…


okay bye bestie 🫢 β€” source/version: ./drivers/gpu/drm/amd/amdkfd; date: October 2026. that's the whole svm_migrate_vram_to_ram(9) moment. mwah πŸ’‹

πŸ“¦ where this page comes from