PCILeechGen icon indicating copy to clipboard operation
PCILeechGen copied to clipboard

VFIO_GROUP_SET_CONTAINER: invalid argument

Open sthgi opened this issue 8 months ago • 2 comments

Description

Not sure what I am missing iommu is enabled?

root@beelink:~/PCILeechGen# dmesg | grep -i iommu
[    0.000000] Command line: BOOT_IMAGE=/boot/vmlinuz-6.17.0-14-generic root=UUID=128880ca-544e-40de-9b66-b195c9127758 ro rtc_mode=local amd_iommu=on crashkernel=2G-4G:320M,4G-32G:512M,32G-64G:1024M,64G-128G:2048M,128G-:4096M
[    0.062444] Kernel command line: BOOT_IMAGE=/boot/vmlinuz-6.17.0-14-generic root=UUID=128880ca-544e-40de-9b66-b195c9127758 ro rtc_mode=local amd_iommu=on crashkernel=2G-4G:320M,4G-32G:512M,32G-64G:1024M,64G-128G:2048M,128G-:4096M
[    0.385848] iommu: Default domain type: Translated
[    0.385848] iommu: DMA domain TLB invalidation policy: lazy mode
[    0.417292] pci 0000:00:00.2: AMD-Vi: IOMMU performance counters supported
[    0.417331] platform MSFT0201:00: Adding to iommu group 0
[    0.417477] pci 0000:00:01.0: Adding to iommu group 1
[    0.417486] pci 0000:00:01.1: Adding to iommu group 2
[    0.417494] pci 0000:00:01.2: Adding to iommu group 3
[    0.417506] pci 0000:00:02.0: Adding to iommu group 4
[    0.417513] pci 0000:00:02.2: Adding to iommu group 5
[    0.417521] pci 0000:00:02.5: Adding to iommu group 6
[    0.417532] pci 0000:00:03.0: Adding to iommu group 7
[    0.417540] pci 0000:00:03.1: Adding to iommu group 8
[    0.417548] pci 0000:00:03.2: Adding to iommu group 9
[    0.417565] pci 0000:00:08.0: Adding to iommu group 10
[    0.417572] pci 0000:00:08.1: Adding to iommu group 11
[    0.417580] pci 0000:00:08.2: Adding to iommu group 12
[    0.417586] pci 0000:00:08.3: Adding to iommu group 13
[    0.417598] pci 0000:00:14.0: Adding to iommu group 14
[    0.417604] pci 0000:00:14.3: Adding to iommu group 14
[    0.417632] pci 0000:00:18.0: Adding to iommu group 15
[    0.417639] pci 0000:00:18.1: Adding to iommu group 15
[    0.417646] pci 0000:00:18.2: Adding to iommu group 15
[    0.417653] pci 0000:00:18.3: Adding to iommu group 15
[    0.417660] pci 0000:00:18.4: Adding to iommu group 15
[    0.417667] pci 0000:00:18.5: Adding to iommu group 15
[    0.417674] pci 0000:00:18.6: Adding to iommu group 15
[    0.417681] pci 0000:00:18.7: Adding to iommu group 15
[    0.417694] pci 0000:c1:00.0: Adding to iommu group 16
[    0.417702] pci 0000:c2:00.0: Adding to iommu group 17
[    0.417710] pci 0000:c3:00.0: Adding to iommu group 18
[    0.417726] pci 0000:c4:00.0: Adding to iommu group 19
[    0.417735] pci 0000:c4:00.1: Adding to iommu group 20
[    0.417766] pci 0000:c6:00.0: Adding to iommu group 21
[    0.417775] pci 0000:c6:00.2: Adding to iommu group 22
[    0.417785] pci 0000:c6:00.4: Adding to iommu group 23
[    0.417794] pci 0000:c6:00.5: Adding to iommu group 24
[    0.417803] pci 0000:c6:00.6: Adding to iommu group 25
[    0.417813] pci 0000:c7:00.0: Adding to iommu group 26
[    0.417823] pci 0000:c7:00.1: Adding to iommu group 27
[    0.417832] pci 0000:c8:00.0: Adding to iommu group 28
[    0.417842] pci 0000:c8:00.3: Adding to iommu group 29
[    0.417851] pci 0000:c8:00.4: Adding to iommu group 30
[    0.417860] pci 0000:c8:00.5: Adding to iommu group 31
[    0.417869] pci 0000:c8:00.6: Adding to iommu group 32
[    0.421537] perf/amd_iommu: Detected AMD IOMMU #0 (2 banks, 4 counters/bank).
[   20.637873] vfio: unknown parameter 'vfio_iommu_type1' ignored
root@beelink:/etc/modprobe.d# fwupdmgr security
WARNING: UEFI capsule updates not available or enabled in firmware setup
See https://github.com/fwupd/fwupd/wiki/PluginFlag:capsules-unsupported for more information.
Host Security ID: HSI:0! (v2.0.17)

HSI-1
✔ SMM locked down:               Locked
✔ Fused platform:                Locked
✔ Supported CPU:                 Valid
✔ UEFI bootservice variables:    Locked
✘ BIOS firmware updates:         Disabled
✘ TPM v2.0:                      Not found
✘ UEFI platform key:             Invalid

HSI-2
✔ SPI write protection:          Enabled
✔ IOMMU:                         Enabled
✔ Platform debugging:            Locked

HSI-3
✔ CET Platform:                  Supported
✔ Pre-boot DMA protection:       Enabled
✔ Suspend-to-idle:               Enabled
✔ Suspend-to-ram:                Disabled
✘ SPI replay protection:         Not supported

HSI-4
✔ SMAP:                          Enabled
✘ Processor rollback protection: Disabled
✘ Encrypted RAM:                 Not supported

Runtime Suffix -!
✔ CET OS Support:                Supported
✔ fwupd plugins:                 Untainted
✔ Linux kernel:                  Untainted
✔ UEFI db:                       Valid
✘ Linux kernel lockdown:         Disabled
✘ Linux swap:                    Unencrypted
✘ UEFI secure boot:              Disabled

Error Type

Code 10 (device cannot start)

Device Context File

NA

Windows Event Log


Device Manager Error Details

No response

Terminal Output


sthgi avatar Mar 11 '26 02:03 sthgi

seems like every device i pick is not working what devices do you recommend for your script to work?

sthgi avatar Mar 11 '26 02:03 sthgi

checked your dmesg and fwupdmgr output. iommu is working perfectly fine on your end. amd iommu is active, groups are created, pre-boot dma protection is enabled. that side is all good.

there's one warning about vfio: unknown parameter 'vfio_iommu_type1' ignored but it's harmless. in linux 6.17 this module was merged into the main vfio module, so it no longer exists as a separate one. you probably have an old config line in /etc/modprobe.d/. you can find and remove it like this:

grep -r "vfio_iommu_type1" /etc/modprobe.d/

just delete that line from whatever file it shows up in. but this is not what's causing code 10.

for code 10 deeper into this i need a few things from you:

  • what device are you cloning? (nvme, ethernet etc, what's the vid/did?)
  • which fpga board are you using?
  • are you on the latest version of pcileechgen?
  • do you see any "overwriting previous definition" warnings in your vivado build log?
  • any more detailed error messages in windows event viewer?

share these and we can narrow down the actual issue. from now on all your issuers that do not contain enough information and do not follow the issue opening rules will be closed unconditionally.

sercanarga avatar Mar 11 '26 02:03 sercanarga