Fixing PCI passthrough Windows 10 VM boot issues

Windows 10 booting, showing only the Windows 10 logo and no spinners or any other loading indication

Over time, I’ve encountered various issues with booting my Windows 10 VM that’s accelerated using PCI-passthrough, VirtIO etc. I believe some of the boot issues to be unique to that kind of setup, and have not always easily found solutions to these problems online, so I wanted to document my experiences for the benefit of others.

OS switcher

Black plastic project enclosure with a 3-state toggle switch on the side, with 3 positions: Linux, ?, and Win.

My latest hack is for dual-booters: The OS switcher lets you select the operating system (OS) you wish to boot at the flick of a switch, anytime. Booting the OS of your choice no longer requires you to sit in front of your computer, wait for a boot selection screen to show up, and then press some buttons at just the right time.