Re: bhyve: GPU passthrough for Nvidia cards

From: Corvin Köhne <corvink_at_FreeBSD.org>
Date: Fri, 27 Jun 2025 06:38:37 UTC
On Thu, 2025-06-26 at 16:49 +0200, Stephan Althaus wrote:
> On 6/26/25 15:07, Corvin Köhne wrote:
> > Hi,
> > 
> > I'm currently experimenting with GPU passthrough for Nvidia cards. All I
> > have to
> > do to make it work with Ubuntu guests, is setting the INTPIN register to any
> > value instead of just 0x00. Unfortunately, I'm unfamiliar with PCI legacy
> > interrupts and how they work. The INTLINE register is set to 0xFF
> > (unconnected).
> > So, is it safe to set the INTPIN register or what has to be done for it to
> > work
> > as expected?
> > 
> > Any help would be appreciated.
> > 
> > 
> Hi!
> 
> You surely mean 'newer' NVidia cards, as my GT1030 works with FreeBSD 
> 14.2 Host and ubuntu guest, NVIdia driver 570, (and Win guest btw)
> out-of-the-box, no kernel/driver modding...
> 
> Regards,
> 
> Stephan
> 
> 

FYI, I'm working on a desktop system with an RTX A500 on 15.0-CURRENT.

Ubuntu dmesg reports "NVRM: Can't find an IRQ for your NVIDIA card!" by default.
Setting the INTPIN register solve this issue and the card can be detected by the
nvidia-smi command. However, as mentioned in my initial post, I'm not sure what
has to be emulated to be able to set the INTPIN in a sane way.


-- 
Kind regards,
Corvin