amdgpu_vm_make_compute(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… amdgpu_vm_make_compute β€” the "glow-up your GFX VM into a compute VM" glow-up ✨

okay so this is page amdgpu_vm_make_compute(9) from the Kernel API Manual, and bestie, it's giving kernel-internals realness πŸŽ€


🌸 NAME 🌸

amdgpu_vm_make_compute β€” Turn a GFX VM into a compute VM πŸ¦‹


✨ SYNOPSIS ✨

int amdgpu_vm_make_compute (struct amdgpu_device *adev , struct
amdgpu_vm *vm );

πŸŽ€ ARGUMENTS πŸŽ€

  • adev β€” an amdgpu_device pointer, aka the GPU's whole entire vibe πŸ‘‘
  • vm β€” the requested vm, like the one you want to ✨transform✨

πŸ’– DESCRIPTION πŸ’–

So here's the tea, and it's kind of a big deal: this only works on GFX VMs that don't have any BOs added and no page tables allocated yet 😭 Like, it has to be a fresh-faced VM with nothing going on β€” no cap, if you've already loaded it up, this is not the move.

What it actually does is change these VM parameters:

  • use_cpu_for_update
  • pte_supports_ats

Then it reinitializes the page directory so it reflects the changed ATS setting. slay πŸ’… That's it, that's the whole function, but it's lowkey doing important work.


πŸ”₯ RETURN πŸ”₯

0 for success, -errno for errors. periodt πŸ’€


🌈 SEE ALSO 🌈

Kernel file ./drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c β€” plus, and I'm not kidding, the entire friend group 🫢

GPUVM(9), struct amdgpu_prt_cb(9), struct amdgpu_vm_tlb_seq_struct(9), amdgpu_vm_assert_locked(9), amdgpu_vm_is_bo_always_valid(9), amdgpu_vm_bo_evicted(9), amdgpu_vm_bo_needs_update(9), amdgpu_vm_bo_idle(9), amdgpu_vm_bo_reset_state_machine(9), amdgpu_vm_update_shared(9), amdgpu_vm_bo_update_shared(9), amdgpu_vm_update_stats_locked(9), amdgpu_vm_update_stats(9), amdgpu_vm_bo_base_init(9), amdgpu_vm_lock_pd(9), amdgpu_vm_lock_individual(9), amdgpu_vm_move_to_lru_tail(9), amdgpu_vm_generation(9), amdgpu_vm_validate(9), amdgpu_vm_ready(9), amdgpu_vm_check_compute_bug(9), amdgpu_vm_need_pipeline_sync(9), amdgpu_vm_flush(9), amdgpu_vm_bo_find(9), amdgpu_vm_map_gart(9), amdgpu_vm_update_pdes(9), amdgpu_vm_tlb_seq_cb(9), amdgpu_vm_tlb_flush(9), amdgpu_vm_update_range(9), amdgpu_vm_bo_update(9), amdgpu_vm_update_prt_state(9), amdgpu_vm_prt_get(9), amdgpu_vm_prt_put(9), amdgpu_vm_prt_cb(9), amdgpu_vm_add_prt_cb(9), amdgpu_vm_free_mapping(9), amdgpu_vm_prt_fini(9), amdgpu_vm_clear_freed(9), amdgpu_vm_handle_moved(9), amdgpu_vm_flush_compute_tlb(9), amdgpu_vm_bo_add(9), amdgpu_vm_bo_insert_map(9), amdgpu_vm_bo_map(9), amdgpu_vm_bo_replace_map(9), amdgpu_vm_bo_unmap(9), amdgpu_vm_bo_clear_mappings(9), amdgpu_vm_bo_lookup_mapping(9), amdgpu_vm_bo_trace_cs(9), amdgpu_vm_bo_del(9), amdgpu_vm_evictable(9), amdgpu_vm_bo_invalidate(9), amdgpu_vm_bo_move(9), amdgpu_vm_get_block_size(9), amdgpu_vm_adjust_size(9), amdgpu_vm_wait_idle(9), amdgpu_vm_put_task_info(9), amdgpu_vm_get_task_info_vm(9), amdgpu_vm_get_task_info_pasid(9), amdgpu_vm_set_task_info(9), amdgpu_vm_init(9), amdgpu_vm_fini(9), amdgpu_vm_manager_init(9), amdgpu_vm_manager_fini(9), amdgpu_vm_ioctl(9), amdgpu_vm_lock_by_pasid(9), amdgpu_vm_handle_fault(9), amdgpu_debugfs_vm_bo_info(9), amdgpu_vm_update_fault_cache(9)


ngl that's a lot of cross-references, but that's literally the whole amdgpu_vm squad and they all ate πŸ’… don't skip them, iykyk

mwa πŸ’‹ this page lives in ./drivers/gpu/drm/amd/amdgpu, dated October 2026, and it's the amdgpu_vm_make_compute(9) manual page β€” take care of her, she's iconic πŸ‘‘

πŸ“¦ where this page comes from