Proxmox Gen2 passthrough
More actions
Under Proxmox (QEMU/KVM with VFIO) an unlocked CMP 170HX gets its 64 GB inside a VM, but the PCIe Gen2 link does not come up by itself. The guest cannot retrain the physical root port the card hangs off, and QEMU intercepts the bus resets the bare-metal Gen2 patch uses. Every method that worked has the Proxmox host retrain the root port to Gen2 at the right moment: from a VM hookscript, from a host daemon the guest asks, or from a host watcher that fires once during guest driver init. This page is the dated history of those methods and the two published tools. Where to run the unlock and the general VM setup are on Virtual machines and passthrough; the bare-metal retrain is on Gen2 link retrain. All reports here are 8 GB cards or do not say.
Dated history
July 2026: no Gen2 in a passthrough VM, Booter error 0x15 behind a Thunderbolt 3 eGPU
gym ran the PCIe 2.0 build of the unlock in a passthrough VM, with the card in a Thunderbolt 3 eGPU enclosure (2026-07-24). nvidia-smi said "No devices were found" and the retrain script did not help. dmesg showed "Booter failed with non-zero error code: 0x15", "Max GSP-RM boot attempts exceeded 4/4" and "RmInitAdapter failed! (0x62:0xffff:2119)". Thanos and xPatrik could not get Gen2 working in VMs either. Amogh said VMs were probably not supported yet and that he would get bare metal working first.
Proven
Source: @jimtjames, 2026-07-24
Source: @_j3ns, 2026-07-24
Source: @thanos8912, 2026-07-24
Source: @._.patrik, 2026-07-24
2026-08-10: first report of Gen2 under VFIO
Toffles reported Gen2 working with the card passed through by VFIO on 2026-08-10, with a screenshot and no settings. He later said he had posted how to do it a week before 丁薇's vfio-linkd post (below).
Reported
Source: @toffles3179, 2026-08-10
QEMU intercepts the bus resets the Gen2 unlock uses: with two cards the second fails (NvKmsKapiDevice)
prometasfw passed two cards to an Ubuntu 24.04.5 VM on Proxmox (2026-08-10). After the unlock and a reboot the guest logged "Failed to allocate NvKmsKapiDevice" from nvidia-drm, and nvidia-smi showed only one card (at 64 GB). His diagnosis: the Gen2 patch forces a bus reset to retrain the link, QEMU intercepts those resets, and with two cards the second reset was blocked, so the second card did not initialize. With the Gen2 part enabled one card retrained to Gen2 and the other dropped off the bus entirely, so he disabled it (2026-08-16).
- Workaround: once the VM has fully booted, remove the missing card from the PCI bus and rescan; it comes back.
- He also had to tune the guest kernel command line so the VM could initialize 128 GB of VRAM on the PCIe bus. His settings were not posted.
- A delay between the two cards' initialization might fix it at boot (untested).
- He suggested running the retrain on the bare-metal host and the patched driver in the VM, since Proxmox brings the hardware up under the hypervisor and hands it to the VM at launch. Every later method in this history retrains from the host.
Other reports from the same weeks: on Proxmox 9.2.1 with an Ubuntu VM, passthrough, the driver install and cmpunlocker all reported success, but after a reboot the VM no longer detected the GPU although lspci still listed it (2026-08-16). Bagster could not get the Gen2 unlock working in a VM, xPatrik saw passthrough work and Gen2 not, and fiiireface had Proxmox hang after the unlock (2026-09-01). Humvee55 said it works fine on bare metal or via vfio passthrough; Josh suggested unlocking on the host and using LXC instead.
Reported 8 GB
Source: @prometasfw, 2026-08-10
Source: @scallion_9883, 2026-08-10
Source: @_____josh_____, 2026-08-10
Source: @mountains1605, 2026-08-10
Source: @confident_lamb_62706, 2026-08-16
Source: @bagstah, 2026-08-16
Source: @prometasfw, 2026-08-16
Source: @._.patrik, 2026-09-01
Source: @_studebaker_, 2026-09-01
Source: @giaki3003, 2026-09-01
Source: @fiiireface, 2026-09-01
2026-08-19: a host hookscript runs the Gen2 activation at VM start
Dimon got Gen2 working with Proxmox passthrough (screenshot, 2026-08-19). He keeps the original patch's Gen2 speed activation script on the Proxmox host and attaches a VM hookscript that runs it in parallel with VM startup. It is the third and last step, after the cards are unlocked. Conditions he gave:
- the patched driver must be running;
- it works only with the VM in which the unlock was performed;
- it needs access to the Proxmox host;
- as with the original script on bare metal, it only works correctly after the host has been fully powered off and on again (cold boot).
He posted the write-up again on 2026-09-01 and called the activation reliable. Amogh invited a pull request to add Proxmox support.
Reported
Source: @dimon_91153, 2026-08-19
Source: @_j3ns, 2026-08-19
Source: @shudza, 2026-08-19
Pointer: a longer write-up by @dimon_91153 (Gen2_cmp_170_hx_proxmox.md, the hookscript method step by step) exists; see Discord. The guide waits for the author.
2026-08-20: vfio-linkd, a host daemon that retrains the root port when the guest asks
丁薇 explained the design on 2026-08-20. The guest can change GPU-side state but cannot retrain the physical upstream root port, so a host daemon, with a separate root helper, does it. The guest's patched driver advertises Gen2 and asks the host over AF_VSOCK or virtio-serial; the host checks the VFIO device, its PCI IDs and its topology against a fixed policy, then sets the root port's target link speed to Gen2, retrains the link and polls the result. A passed-through card went from Gen1 x4 to a stable Gen2 x4 (5.0 GT/s) inside the VM. In reply to RonnyFish it was confirmed to apply to x16 cap-modded cards too, at Gen2 x16 (see PCIe x16 capacitor mod). Toffles had reported Gen2 under VFIO ten days earlier (above), and Studebaker pointed Proxmox users to the tool on 2026-09-01.
The published tool is danvei233/170hx-pve-gen2-controller (vfio-linkd v0.2.0, Apache-2.0, two commits on 2026-08-20). The extract identifies 丁薇 as GitHub user danvei233, but that link is not confirmed. Before running it:
- Build it from source with Go 1.25 or newer as the README describes. The repo also commits prebuilt binaries (the README says, in Chinese, roughly "I'm lazy, so I uploaded the binary too"); build your own rather than running those.
- A new host installs in dry-run mode, and the daemon refuses live writes until two explicit opt-in settings are both set. Keep dry-run on until its policy matches your card and root port.
- A live retrain of a root port can drop the device.
- It does nothing for Gen3.
Proven
Source: @toffles3179, 2026-08-10
Source: @dingwei0049, 2026-08-20
Source: @ronnyfish, 2026-08-20
Source: @_studebaker_, 2026-09-01
Source: repo github.com/danvei233/170hx-pve-gen2-controller by danvei233 on GitHub (vfio-linkd v0.2.0, Apache-2.0, commit dfd0c8e 2026-08-20; posted in Discord by @_studebaker_ and @dingwei0049)
Pointer: a longer write-up by @dingwei0049 (the vfio-linkd design with its example policy values, link-control writes and error codes) exists; see Discord and the repository on GitHub. The details wait for the author.
August to September 2026: Gen2 under Proxmox still unstable for some owners
From 2026-08-22 NikhilR posted logs of Gen2 instability with the card passed through in Proxmox. 丁薇 linked danvei233/170hx-pve-gen2-controller as a tool for it, and Amogh acknowledged it as an issue to fix later. On 2026-09-26 Logy still got kernel hangs and Gen2 failures passing an 8 GB card through Proxmox at cmpunlocker commit 6c442ee. cibernox's cards finally reported Gen2 after he installed a PEX88096-based PCIe switch (2026-09-27; see PCIe switch boards (PEX88096, PEX88064, PEX8747, PLX8749)).
Proven
Source: @nikhilr1696, 2026-08-22
Source: @dingwei0049, 2026-08-24
Source: @_j3ns, 2026-08-26
Source: @logy0, 2026-09-26
Source: @cibernox, 2026-09-27
2026-09-06: Gen2 x4 and Gen2 x16 cards in separate Proxmox VMs, two weeks without lockups
Ikyo had read that the Gen2 unlock fails under Proxmox because the VM locks up. SeriousRising runs Gen2 x4 and Gen2 x16 cards (bought pre-modded) in separate Proxmox VMs, about two weeks without lockups at that point, on an X99 board without Resizable BAR (2026-09-06). gym explained that the VM cannot physically retrain the link, so several members wrote a small shim that makes the host retrain it. Amogh said hypervisor support was next on his list, and aaron pointed to the PixelML club-170hx installation guide (docs/INSTALLATION.md) as a Proxmox starting point.
SeriousRising built his setup before the VFIO merge into cmpunlocker, from a mix of other members' working setups and on a different repo than mainline cmpunlocker. It covers VFIO setup, a Proxmox hookscript and a serial console for the display. He warned that no part of it is plug and play and recommended starting from a fresh VM. Ikyo hit errors with the hookscript, and its ReBAR script failed on his Dell; nightdays said such a script is only needed to force Gen2, not for the 64 GB unlock.
Reported
Source: @sh.ad, 2026-09-06
Source: @aaron0010, 2026-09-06
Source: @ikyo, 2026-09-06
Source: @seriousrising, 2026-09-06
Source: @_j3ns, 2026-09-06
Source: @jimtjames, 2026-09-06
Source: @.nightdays, 2026-09-09
Pointer: a longer write-up by @seriousrising (PROXMOX-GEN2-PASSTHROUGH.md, his setup step by step) exists; see Discord. The guide waits for the author.
2026-09-29: one timed root-port retrain during guest driver init (one-card experiment)
mazzanfar posted cmp170hx-proxmox-pcie-gen2 on 2026-09-29 as a guide and config that worked for Proxmox users with Gen2 problems. Tested setup: Dell PowerEdge R730 (2x Xeon E5-2695 v4), Proxmox VE 9.1.1 on kernel 6.17.2-1-pve, an Ubuntu 24.04.4 guest on 6.8.0-142-generic with Q35 and SeaBIOS, one 8 GB card unlocked to 65,536 MiB on a physical x4 link, a modified nvidia-open 610.43.03 and a 150 W power limit.
- How it works: a host watcher polls the GPU's PCIe config space. When the guest driver raises the card's target link speed from Gen1 to Gen2 during init, the watcher retrains the root port exactly once. The next poll, about 104 ms later, showed Gen2 x4 at both ends. The watcher runs a read-only preflight by default; starting the VM through it is an explicit option.
- Guest side: a patched build of amoghmunikote/cmpunlocker at 6c442eeb that applies the Gen2 setup later in driver init and leaves out two steps of the mainline unlock (the SM reconfiguration and an ECC override).
- Result: with 256 MiB pinned buffers, host-to-device copies went from about 0.8 to 1.6 GB/s and device-to-host about the same (median, about 2x). No inference speedup was measured.
- Caveats from the repo: Gen2 x4 survived one VM stop and start, but a host reboot and an AC power cycle were not tested. The packaged watcher never ran on hardware as packaged. It accepts only 10de:20c2, needs the root port already targeting Gen2, and targets driver 610.43.03 rather than current mainline. It names luannanxian/cmp170hx-gen2, cmpunlocker PR #35 and anoane/01-proxmox-dual-gpu-passthrough as related reports it did not reproduce.
- Licence GPL-2.0-only; the patched NVIDIA files keep their MIT notices.
cibernox replied that he had the same Gen2 problem until he started using a PCIe switch.
Reported 8 GB
Source: repo github.com/mazzanfar/cmp170hx-proxmox-pcie-gen2 by mazzanfar on GitHub, posted by @mazzanfar7661, 2026-09-29 (GPL-2.0-only, last commit cb8d757 2026-09-29)
Source: @cibernox, 2026-09-29
2026-10-03: Gen2 under Proxmox has several independent reports
Asked by Ikyo about Gen2 under Proxmox on 2026-10-03, ElectroHobo said he thought the unlocker's "v.4" fixed it and that he now runs Proxmox passthrough at PCIe Gen2. By then Gen2 under Proxmox had several independent reports: Toffles, Dimon, 丁薇, SeriousRising and ElectroHobo (entries above). Ikyo, whose Dell server lacks Gen2 and ReBAR support, asked whether it is worth using there; nobody answered.
Proven
Source: @ikyo, 2026-10-03
Source: @nathang6866, 2026-10-03
Source: @seriousrising, 2026-10-03
P2P between two cards inside a Proxmox VM: one report, no configuration posted
SeriousRising said on 2026-10-03 that dual cards with P2P working in a Proxmox VM had been running for a while, set up largely with an AI agent. No configuration or numbers were posted, and nobody else had reproduced it. It would be the first verified CMP P2P inside a VM; see P2P for P2P on bare metal.
Reported
Source: @seriousrising, 2026-10-03
The two published tools
| Tool | Licence | What it does | Tested on | Caveats |
|---|---|---|---|---|
| danvei233/170hx-pve-gen2-controller (vfio-linkd v0.2.0) | Apache-2.0 | Host daemon: retrains the root port to Gen2 when the guest's driver asks over vsock or virtio-serial | Gen1 x4 to a stable Gen2 x4 in a VM; Gen2 x16 on cap-modded cards | Build from source (Go 1.25 or newer), not the committed binaries; dry-run by default, live writes need two opt-in settings; a live retrain can drop the device; no Gen3 |
| mazzanfar/cmp170hx-proxmox-pcie-gen2 | GPL-2.0-only | Host watcher: one root-port retrain when the guest driver sets Gen2 during init, plus a guest driver patch | One 8 GB card on a Dell PowerEdge R730, Proxmox VE 9.1.1, Gen2 x4, about 2x copy bandwidth | One-card experiment; packaged watcher never run on hardware; 10de:20c2 only; driver 610.43.03; host reboot and AC power cycle not tested |
Neither tool has a report from a second host and board yet; a test of both, including recovery after a host reboot and an AC power cycle, is an open task.
Reported
Source: repo github.com/danvei233/170hx-pve-gen2-controller by danvei233 on GitHub (vfio-linkd v0.2.0, Apache-2.0, commit dfd0c8e 2026-08-20; posted in Discord by @_studebaker_ and @dingwei0049)
Source: repo github.com/mazzanfar/cmp170hx-proxmox-pcie-gen2 by mazzanfar on GitHub, posted by @mazzanfar7661, 2026-09-29 (GPL-2.0-only, last commit cb8d757 2026-09-29)