Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
how does gpu passthrough work exacly?
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
picarica
Guru
Guru


Joined: 11 Aug 2018
Posts: 357

PostPosted: Mon Apr 07, 2025 11:13 am    Post subject: how does gpu passthrough work exacly? Reply with quote

so i know proton is well and all but i still would like to try out VM GPU passthrough, i have one amd 6500 xt card which i would use for my gentoo display output and intel arc b580 that i would passthrought.
but i wonder if the card is unplugged (doesnt have any hdmi or DP plugged in) can i still use it in gentoo without VM ? like running SD, LLMs etc? is it still usable even in IOMMU group? or how does it work exacly, does it just completly disables it from my system?
and also is this guide a good one to follow to set it up?
and also do i need drivers for both my amd and intel gpu? in my linux system, if i want to sometimes use second gpu ?
Back to top
View user's profile Send private message
yaslam
Tux's lil' helper
Tux's lil' helper


Joined: 08 May 2024
Posts: 80
Location: Scotland, UK

PostPosted: Thu Apr 17, 2025 11:13 am    Post subject: Re: how does gpu passthrough work exacly? Reply with quote

picarica wrote:
so i know proton is well and all but i still would like to try out VM GPU passthrough, i have one amd 6500 xt card which i would use for my gentoo display output and intel arc b580 that i would passthrought.
but i wonder if the card is unplugged (doesnt have any hdmi or DP plugged in) can i still use it in gentoo without VM ? like running SD, LLMs etc? is it still usable even in IOMMU group? or how does it work exacly, does it just completly disables it from my system?
and also is this guide a good one to follow to set it up?
and also do i need drivers for both my amd and intel gpu? in my linux system, if i want to sometimes use second gpu ?


To answer your question, yes it does completely disable it from your host system. If you are passing through the Intel GPU, you do not need Intel GPU drivers on the host system but you would need them inside the guest. If you are using the AMD GPU for the host, you need drivers for it on the host system.

Once the Intel GPU is passed through to a VM, you can only use it inside the VM, you cannot use it on the host system.

Also, yes that guide is the one you should follow as it covers the entire process of passing through a GPU to a guest VM.
Back to top
View user's profile Send private message
Ralphred
l33t
l33t


Joined: 31 Dec 2013
Posts: 789

PostPosted: Thu Apr 17, 2025 4:55 pm    Post subject: Re: how does gpu passthrough work exacly? Reply with quote

yaslam wrote:
yes it does completely disable it from your host system.
Although this is the easiest way to think about it, it isn't strictly true: You can use modprobe and rmmod to switch between the vfio-pci driver and the "correct" driver for your passthrough card, but gracefully tearing down everything that sits on top of either driver can be self-defeating from a convenience point of view. This is how "passthrough with a single GPU" works though, despite my never finding a valid use case for it that isn't better served by dual booting (it's literally quicker to dual boot and much less faff, but YMMV as use cases are personal).
Back to top
View user's profile Send private message
yaslam
Tux's lil' helper
Tux's lil' helper


Joined: 08 May 2024
Posts: 80
Location: Scotland, UK

PostPosted: Fri Apr 18, 2025 9:25 am    Post subject: Re: how does gpu passthrough work exacly? Reply with quote

Ralphred wrote:
yaslam wrote:
yes it does completely disable it from your host system.
Although this is the easiest way to think about it, it isn't strictly true: You can use modprobe and rmmod to switch between the vfio-pci driver and the "correct" driver for your passthrough card, but gracefully tearing down everything that sits on top of either driver can be self-defeating from a convenience point of view. This is how "passthrough with a single GPU" works though, despite my never finding a valid use case for it that isn't better served by dual booting (it's literally quicker to dual boot and much less faff, but YMMV as use cases are personal).


I did single GPU passthrough when I was using my gaming PC as a Proxmox server, but the issues I had outweighed the benefits (RX 580 passed through to Windows on Proxmox had constant issues like the entire Proxmox host rebooting randomly, not just the VM (seemed to occur when gaming for a prolonged time); among other issues) it was too unstable to be used as a daily driver VM. It really depends on the GPU that you are passing through whether it will be stable or not.
Back to top
View user's profile Send private message
Ralphred
l33t
l33t


Joined: 31 Dec 2013
Posts: 789

PostPosted: Fri Apr 18, 2025 2:30 pm    Post subject: Re: how does gpu passthrough work exacly? Reply with quote

yaslam wrote:
It really depends on the GPU that you are passing through whether it will be stable or not.
The most "useful" set-up had was with a vega64 card switching between "native" and "vfio-pci" but it was a "second" card being enabled either in Windows or Linux to just play games on.
Single GPU passthough does feel more like a gimmick, but it is useful to learn the ins and outs of how passthrough works, as you won't find a more complicated way of making a VM work, so if you can do that you can do anything.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum