Date: Mon, 20 Jun 2022 10:41:17 -0600 From: John Nielsen <lists@jnielsen.net> To: =?utf-8?Q?Corvin_K=C3=B6hne?= <C.Koehne@beckhoff.com> Cc: freebsd-virtualization@freebsd.org Subject: Re: bhyve GPU passthrough + romfile Message-ID: <6EA38DA2-37FC-40E7-99D5-FFA600B65276@jnielsen.net> In-Reply-To: <e12e35fd3e73429a9cb65cb3ec74d002@beckhoff.com> References: <e12e35fd3e73429a9cb65cb3ec74d002@beckhoff.com>
next in thread | previous in thread | raw e-mail | index | archive | help
> On Jun 20, 2022, at 12:08 AM, Corvin K=C3=B6hne <C.Koehne@beckhoff.com> wr= ote: >=20 > first of all, the ROM is only required for Linux/BSD amdgpu driver. Window= s works without a ROM file. Additionally, the ROM is required for pre-OS gra= phics (e.g. EFI boot, bootloader, etc.). >=20 > Currently, OVMF doesn't processes the ROM file. Processing the ROM would i= nclude: > - executing the ROM > - shadowing the ROM >=20 > The amdgpu driver searches for the shadowed ROM. So, for Linux/BSD guest, a= patched OVMF is required. If you like to try a patched OVMF, please apply f= ollowing commits to BhyveX64.dsc: > https://github.com/Beckhoff/edk2/commit/bed77d4bb374fa6450fa2781eeddfbc360= 4edf6a > https://github.com/Beckhoff/edk2/commit/aeaa9c4c1d1222723cbf9c1c7dd7f5ff39= 11deac > https://github.com/Beckhoff/edk2/commit/a7b01394682874508d65c6f4b5815cdbb6= c6eb6c Thank you for the detailed response. I will try these for my own curiosity. I= s there a reason these patches aren=E2=80=99t in the upstream project or oth= erwise available as a FreeBSD port/package? > As said, Windows requires no ROM. So, that's not the issue. For many years= AMD GPUs have issues to reset themselves. It's a well known hardware bug. Y= ou didn't mention which AMD GPU your using so I can't check if your GPU is a= ffected too. A possible workaround is descripted at: > https://curtisshoward.com/post/fixing-amd-gpu-passthrough-reset-issues-in-= windows/ I have a Radeon RX 580 FWIW. Disabling the card in Windows for every boot i= s a pretty ugly hack but I might play around with it. Too bad Windows Update= is so heavy handed in the consumer editions of Windows. > Btw: On Linux there's some work to solve the GPU reset bug by hardware spe= cific reset routines (https://github.com/gnif/vendor-reset) but I don't thin= k that such kind of work will be merged soon into FreeBSD. >=20 >> PS: Is there a known/supported way to get a GPU ROM file from FreeBSD? Th= e one I have I obtained from a Linux host where this GPU was secondary. >=20 > No, there's no known/supported way yet. The best way is to boot another OS= .
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?6EA38DA2-37FC-40E7-99D5-FFA600B65276>