Repository navigation
vfio-pci: keep option ROMs that list the device unmodified - #7184
Draft
eriknordmark wants to merge 6 commits into
Draft
eriknordmark wants to merge 6 commits into
eriknordmark wants to merge 6 commits into
Conversation
github-actions
Bot
requested review from
andrewd-zededa,
christoph-zededa,
naiming-zededa,
rene,
rucoder and
shjala
November 21, 2026 04:55
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #7184 +/- ##
==========================================
+ Coverage 30.78% 31.25% +0.46%
==========================================
Files 562 573 +11
Lines 101223 102818 +1595
==========================================
+ Hits 31166 32132 +966
- Misses 67638 68313 +675
+ Partials 2419 2373 -46 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
With a 6.14 or later kernel, a SeaBIOS app VM with a passed-through NIC that has no option ROM of its own, such as the Intel I210 on a Supermicro X10SDV-TP8F, stops at boot with a KVM internal error. The kernel exposes the platform firmware's copy of the ROM, and QEMU rewrites its device ID and checksum in a way that corrupts the image, although the ROM's own device list already names the device. OVMF guests are unaffected. EVE-k cannot work around it with rombar=0, since KubeVirt has no ROM setting for host devices. Add a QEMU patch that leaves such a ROM untouched. Signed-off-by: eriknordmark <erik@zededa.com> Co-Authored-By: Claude Code <noreply@anthropic.com>
On EVE-k, app VMs run in KubeVirt's virt-launcher, whose qemu-kvm is CentOS Stream 9's rather than EVE's pkg/qemu. A SeaBIOS VM with an assigned NIC that has no ROM of its own, such as the I210 on a Supermicro X10SDV, therefore still stops with a KVM internal error on a 6.14+ kernel, since QEMU corrupts the platform ROM the kernel exposes. Add pkg/virt-launcher, which rebuilds the launcher's qemu-kvm RPM from its source package with the vfio ROM patch, ported to QEMU 9.1. pkg/kube bundles it as docker.io/lfedge/eve-virt-launcher:v1.7.3-eve1, kube-init imports it, and virt-operator uses it through VIRT_LAUNCHER_IMAGE. Signed-off-by: eriknordmark <erik@zededa.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VyjigXVFZhuUg5LiRSVwsj
linuxkit runs RUN steps without network unless build.yml asks for it, and dnf has to fetch the QEMU build dependencies. Signed-off-by: eriknordmark <erik@zededa.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VyjigXVFZhuUg5LiRSVwsj
The full launcher image is 531 MB uncompressed and pushes the EVE-k rootfs past the 512 MB device limit. Nodes now pull it on first use via virt-operator's VIRT_LAUNCHER_IMAGE, like the stock quay image. Signed-off-by: eriknordmark <erik@zededa.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VyjigXVFZhuUg5LiRSVwsj
Points VIRT_LAUNCHER_IMAGE at a personal Docker Hub copy of pkg/virt-launcher until lfedge/eve-virt-launcher is published. Signed-off-by: eriknordmark <erik@zededa.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VyjigXVFZhuUg5LiRSVwsj
Builds EVE-k with the core kernel flavor and the kvm firmware list so the amd64 EVE-k rootfs fits under 512 MiB for a ZEDCloud upload. Loses the hwe kernel's broader driver and firmware coverage. Do not merge. Signed-off-by: eriknordmark <erik@zededa.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
eriknordmark
force-pushed
the
vfio-rom-device-list
branch
from
November 23, 2026 21:43
3371662 to
87a20d8
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Since Linux 6.14, vfio-pci exposes the firmware's shadow copy of a device's
option ROM when the device has no ROM BAR of its own. On Intel I210 NICs that
copy is the Boot Agent ROM. QEMU's ROM loader then rewrites the PCIR device ID
to the passed-through device's ID (1521 to 1533) and writes the checksum fix
into byte 6, which is the
lretending the ROM's init entry. A SeaBIOS guestwith the NIC assigned crashes about 2.5 s after boot and never gets an IP.
The fix leaves a ROM unmodified when its PCIR device list already names the
device. It applies to both QEMUs EVE runs:
pkg/qemu(EVE-kvm): new patch on EVE's QEMU.pkg/virt-launcher(EVE-k): KubeVirt v1.7.3's launcher rebuilt with the samepatch ported to CentOS Stream 9
qemu-kvm-9.1.0-20.el9, and selected throughvirt-operator's
VIRT_LAUNCHER_IMAGE. The launcher image is pulled, notbundled, since it would push the EVE-k rootfs past 512 MB.
Draft because:
TEST ONLYcommits get dropped: one pointsVIRT_LAUNCHER_IMAGEata personal Docker Hub copy, the other builds EVE-k with the core kernel and
kvm firmware so the test image fits a 512 MB device.
lfedge/eve-virt-launcherneeds publishing under a fixed tag.kubevirt-operator.yamlonly on first install, so anupgraded node keeps the stock launcher. That needs handling.
PR dependencies
None. lf-edge/eve-kernel#337 fixes the same crash on the kernel side by
limiting the firmware ROM fallback to display devices; either fix alone is
sufficient.
How to test and validate this PR
On an EVE-k device with an Intel I210 (or another NIC whose firmware carries a
Boot Agent ROM listing the device), running a 6.14+ kernel, assign the NIC to
a VM app booting with SeaBIOS. Without the fix the domain goes to
suspended pausedshortly after start and the app gets no IP; with it the appboots and gets an address. Confirm the launcher pod runs the patched image
(
kubectl get pods -A -l kubevirt.io=virt-launcher -o jsonpath='{..image}').Tested with ztest
test_app_assigned_ethon a Supermicro E300 with I210 NICs:3/3 passed (726–782 s) on a 6.18 kernel without eve-kernel#337.
Changelog notes
Fixed VMs with a passed-through Intel I210 (or similar) NIC crashing at boot
on EVE-k.
PR Backports
Checklist
I've provided a proper description
I've added the proper documentation
I've tested my PR on amd64 device
I've tested my PR on arm64 device
I've written the test verification instructions
I've set the proper labels to this PR
I've checked the boxes above, or I've provided a good reason why I didn't
check them.
🤖 Generated with Claude Code
https://claude.ai/code/session_01VyjigXVFZhuUg5LiRSVwsj