a card's PCI address in sysfs's spelling
| 51 | #if !FNX_HOSTRING && !defined(_WIN32) |
| 52 | // a card's PCI address in sysfs's spelling |
| 53 | std::string card_bdf(int dev) { |
| 54 | char bus[32]; |
| 55 | ck(cudaDeviceGetPCIBusId(bus, sizeof bus, dev), "cudaDeviceGetPCIBusId"); |
| 56 | try { |
| 57 | return sysfs_bdf(bus); |
| 58 | } catch (const std::exception& e) { |
| 59 | throw std::runtime_error("card " + std::to_string(dev) + ": " + e.what()); |
| 60 | } |
| 61 | } |
| 62 | // the ring stores straight into the next card's memory: with translated IOMMU domains every such write faults |
| 63 | // (dmesg: "DMAR: ... PTE Write access is not set") and the first window ends in a ring timeout that names nothing. |
| 64 | // Each card's IOMMU group must be identity (boot with iommu=pt); a card whose iommu_group link is absent has no IOMMU |
no test coverage detected