Skip to content

RTX 5060 Ti eGPU (OCuLink) hard locks system on CUDA allocation (Ollama/llama.cpp) - Blackwell GSP firmware bug #1247

Open

Description

@budionqc

NVIDIA Open GPU Kernel Modules Version

580

Please confirm this issue does not happen with the proprietary driver (of the same version). This issue tracker is only for bugs specific to the open kernel driver.

  • I confirm that this does not happen with the proprietary driver package.

Operating System and Version

Ubuntu Server 26.04 LTS (Resolute Raccoon)

Kernel Release

7.0.0-28-generic

Please confirm you are running a stable release kernel (e.g. not a -rc). We do not accept bug reports for unreleased kernels.

  • I am running on a stable kernel release.

Hardware: GPU

NVIDIA GeForce RTX 5060 Ti (16GB VRAM, eGPU connected via OCuLink)

Describe the bug

Description of the bug

On an AMD Ryzen 7 Mini-PC running Ubuntu with an eGPU (NVIDIA GeForce RTX 5060 Ti connected via OCuLink), any sustained CUDA memory allocation (such as running Ollama / llama.cpp inference) instantly hard-locks the host system.
The crash is a silent, complete system freeze requiring a hard power cycle. No Xid error or kernel panic is logged before the freeze.

  • Pure compute workloads like gpu_burn run fine at 100% load for several minutes without issues.
  • The hard-lock happens immediately when the model begins to load into VRAM/bootstrap CUDA.
  • Disabling the GSP Firmware (NVreg_EnableGpuFirmware=0) did not resolve the issue (system still freezes).

This issue is highly consistent with reports on Blackwell GPUs in external enclosures (OCuLink/Thunderbolt) experiencing GSP bootstrap or PCIe state sync crashes during dynamic memory allocation.

Hardware & Software Environment

  • CPU: AMD Ryzen 7
  • GPU: NVIDIA GeForce RTX 5060 Ti (16GB VRAM)
  • Interface: OCuLink (PCIe external)
  • OS: Ubuntu Server 26.04 LTS (Resolute Raccoon)
  • Driver Version: 595.xx / 580.xx
  • Container Environment: Podman (Rootless) running Ollama

Attached Logs

I am attaching the nvidia-bug-report.log.gz generated right after a clean boot.

To Reproduce

  1. Connect RTX 5060 Ti eGPU via OCuLink.
  2. Start Ollama container (Podman).
  3. Run a model: podman exec -it ollama ollama run llama3.2
  4. System hard-locks instantly when the model begins loading.

Bug Incidence

Always

nvidia-bug-report.log.gz

nvidia-bug-report.log.gz

More Info

No response

Activity

  1. added
    bug
    on Jul 17, 2026
  2. kreggencor-crypto commented on Aug 24, 2026

    @kreggencor-crypto

    TL;DR — pcie_ports=native eliminates this fault class on a Blackwell RTX 5060 Ti attached over OCuLink to an AMD Strix Halo host. FAIL → PASS with a single variable changed, confirmed across a 150–198 W power sweep with zero PCIe AER errors. It is not in this issue's tried-mitigations list.

    Searchable, because this took two weeks to find and I would like the next person to find it in five minutes: Xid 13 · Xid 79 · Xid 154 · GPU has fallen off the bus · NV_ERR_GPU_IN_FULLCHIP_RESET · NV_ERR_GPU_IS_LOST · rpcSendMessage failed with status 0x0000000f · kbifInitLtr · RmInitAdapter failed 0x22:0x56:897 · pcie_ports=native · OCuLink · eGPU · Strix Halo · Ryzen AI Max+ 395 · Radeon 8060S · gfx1151 · GB206 · driver 580.173.02 open kernel modules · Minisforum DEG1 · CORSAIR AI WORKSTATION 300.

    Provenance — what is and is not mine

    The parameter is not my discovery. pcie_ports=native appears in a community gist as one of several untried suggestions for mixed-GPU eGPU hosts, alongside softdep nvidia pre: thunderbolt and disabling ReBAR. What is new here is that nobody had tested it against this failure, and now it has been: controlled A/B with one variable, a power sweep, per-second telemetry, and continuous production use since.

    Environment

    System CORSAIR AI WORKSTATION 300 — a stock retail SKU, not a custom build
    Board / BIOS Sixunited AXB35-02, AMI 3.07 (2025-10-16)
    APU AMD Ryzen AI Max+ 395 "Strix Halo", Radeon 8060S iGPU (1002:1586, gfx1151) — drives the display
    GPU ASUS RTX 5060 Ti 16 GB, Blackwell GB206, 10de:2d04, subsystem 1043:8a06
    Driver 580.173.02, open kernel modules (nvidia-driver-580-open + dkms)
    Kernel 7.0.0-30-generic, Ubuntu 24.04 base
    Enclosure Minisforum DEG1 — OCuLink only. No USB4/Thunderbolt controller anywhere in the path; nothing is tunnelled
    Link PCIe 4.0 x4, 16 GT/s under load, AMD root port 0000:00:02.5
    Prior cmdline iommu=pt pci=realloc pcie_aspm=off

    The GPU is compute-only — nvidia_drm is blocked, so it exposes no DRM node and never drives a display. The AMD iGPU owns the display.

    The faults, before the change

    A — sustained CUDA load → Xid 13. One SDXL render usually passes; five back-to-back do not:

    CUDA error: unspecified launch failure  (cudaErrorLaunchFailure)
    NVRM: Xid (PCI:0000:c4:00): 13, Graphics Exception: Class 0xffff Subchannel 0x0 Mismatch
    NVRM: Xid (PCI:0000:c4:00): 13, pid=<py>, name=python, ... Data deaddead
    

    B — concurrent AMD-iGPU LLM + NVIDIA-eGPU render → GSP hang. The PCIe link stays up throughout (config space readable, 16 GT/s x4, D0):

    NVRM: _issueRpcAndWait: rpcSendMessage failed with status 0x0000000f
    NVRM: nvAssertFailedNoLog: ... (status == NV_ERR_GPU_IN_FULLCHIP_RESET)
    nvidia-smi: "Unable to determine the device handle for GPU0 ... Unknown Error"  [GPU requires reset]
    

    What did not help

    • NVreg_EnableGpuFirmware=0 — no-op on Blackwell (the open module requires GSP). Independent confirmation of what is already reported in this thread.
    • 150 W power cap (nvidia-smi -pl 150); NVreg_DynamicPowerManagement=0.
    • Disabling Resizable BAR (it clears the VF BAR assignment warnings and raises link speed — it does not stop the fault).

    The change

    GRUB_CMDLINE_LINUX_DEFAULT="... iommu=pt pci=realloc pcie_aspm=off pcie_ports=native"
    

    Identical test, one variable:

    Test Before After
    SDXL 1024 sustained ×5 FAIL — Xid 13 PASS — 11.1 s/img
    Soak ×10, 1536, 1080p — PASS
    AMD iGPU LLM + NVIDIA eGPU render, concurrent GSP wedge, reboot required PASS — 70.7 tok/s alongside renders, 0 Xid
    Power sweep 150 → 198 W — All PASS · 0 Xid · 0 AER

    Per-second telemetry across the sweep:

    Cap W Avg draw Peak Peak SM clk Max temp AER corr AER fatal
    150 140.9 W 153 W 2857 MHz 61 °C 0 0
    170 157.9 W 171 W 2865 MHz 62 °C 0 0
    180 167.8 W 181 W 2857 MHz 64 °C 0 0
    198 171.8 W 186 W 2865 MHz 64 °C 0 0

    PCIe AER counters — correctable, non-fatal and fatal — stayed at exactly zero at every power level. The link is electrically clean. The failure was in error handling, not in the link, and not in the card.

    Where the defect appears to live — the AMD/NVIDIA seam

    These faults look like PCIe error-recovery and power-state handling, not compute. With firmware-owned port services (the default), a transient on this link under sustained or concurrent load is not recovered — surfacing either as a GSP RPC timeout (fault B) or a graphics-engine exception (fault A). Hand AER/PME/hotplug to the kernel and the kernel rides it out; the AER counters staying at zero afterwards says there was never anything wrong with the link itself.

    The question worth asking on the NVIDIA side: does the GSP's PCIe link-state and PME recovery path assume firmware ownership of the port services on AMD root ports? Note there is no tunnel in this path at all — OCuLink is a direct PCIe cable — so none of this can be attributed to Thunderbolt/USB4 tunnelling behaviour, which is how similar reports usually get closed.

    The AMD-side question is the mirror of it: whether the AXB35-02/Strix Halo platform firmware's handling of these port services differs from what the GSP expects. I have no visibility into that half and would happily run tests for anyone who does.

    Related reports — same family, different transports

    I have a separate Thunderbolt 4 / USB4 investigation on this same host and card — host hard-locks at driver attach, no panic, no Xid, no journal entry, isolated with an fsync-per-step log that survives the power cut, pointing at attach-time capability negotiation (kbifInitLtr_GB202: LTR is disabled in the hierarchy, and pci_enable_atomic_ops_to_root requesting 128-bit CAS the root port does not advertise). That belongs on #979, not here — I will post it there rather than mix two failure modes in one thread.

    Two honest caveats

    1. This is a mitigation, not a cure. Pushed deliberately past normal load — batched CUDA inference at concurrency 6 with no idle gap while the AMD iGPU ran continuous renders — the card still threw Xid 79: GPU has fallen off the bus after 2 min 35 s, then Xid 154 → Node Reboot Required and ~580 follow-on NVRM lines (NV_ERR_GPU_IS_LOST, GPU_IN_FULLCHIP_RESET, API_GPU_ATTACHED_SANITY_CHECK failed). Package temperature was 85.4 °C at that instant against ~50 °C idle — correlation, not proof. So: pcie_ports=native clears the fault class in normal operation and does not make the card immune under sustained saturation of both engines. I would rather publish the boundary than have someone hit it and conclude the mitigation is worthless.
    2. Throughput gave no warning. The card sustained 233–275 aggregate tok/s right up to the instant it left the bus, and afterwards the inference server stayed "up" and returned zero tokens. An HTTP health check is not a health check.

    Suggestions

    1. Add pcie_ports=native to the tried-mitigations list here, and to eGPU guidance for AMD root ports generally. One line; it turned an unusable card into a production one.
    2. Surface allocation failures to the requesting process instead of only as a bare kernel NVRM ... NV_ERR_NO_MEMORY line. With a resident tenant this is routine, and it currently reads like hardware failure.
    3. Consider a supported way to mark a GPU compute-only. Where the discrete GPU is not the display device, six separate host-side pins are currently needed to stop the display stack, audio stack, encoder and Vulkan loader from claiming it. One driver-level flag replaces all six, on every machine with this topology.

    Full write-up — raw per-second dmon captures, the wide telemetry CSV, the exact benchmark prompts and seeds, every configuration pin, and the incident timeline: https://kreggencor-crypto.github.io/egpu-strixhalo-oculink/

    Happy to run further tests on this hardware, including anything that would confirm or rule out the port-service hypothesis on either the NVIDIA or the AMD side.

  3. happy-HHH commented on Sep 10, 2026

    @happy-HHH

    Same failure class on an Intel PCH host, with a different resolution — and five negative results that may save someone a day.

    Adding a data point because this thread's existing mitigation (pcie_ports=native, on AMD Strix Halo) is inert on my Intel platform, and because my AER counters behave the opposite way to @kreggencor-crypto's, which turns out to be a useful discriminator.

    Full data, logs and per-run numbers: https://gist.github.com/happy-HHH/82d5879843cafc592523d20383687e11

    Environment

    RTX 5070 Ti (GB203) external via OCuLink into an AOOSTAR AG02 (own 800 W PSU), host port 0000:00:1b.0 — Intel H570 PCH, gen3 x4, nothing else on that port. i7-11700, Ubuntu 24.04, kernel 7.0.0-31, driver 595.84 open modules, CUDA 13.2. A second 5070 Ti sits on the CPU's gen4 x16 and has never faulted. Workload is llama.cpp serving Qwen3.8-27B split across both GPUs.

    Signature

    pcieport 0000:00:1b.0: PCIe Bus Error: severity=Correctable,
      type=Physical Layer, (Receiver ID)  [ 0] RxErr (First)
    NVRM: Xid (PCI:0000:03:00): 79, GPU has fallen off the bus.
    NVRM: Xid: 154, GPU recovery action changed to 0x2 (Node Reboot Required)
    
    CUDA error: unspecified launch failure
      at ggml_backend_cuda_buffer_set_tensor      (host->device tensor copy)
    

    Config space then reads all ff. The rest of the system stays up — I kept working for over an hour after a drop, twice. Only a reboot recovers GPU1.

    Why gpu_burn passes while inference dies — measured

    @budionqc noted gpu_burn runs fine for minutes while Ollama hard-locks instantly. I can put numbers on that distinction, and I think it is the key to the whole failure class:

    test conditions result
    on-device cuBLAS GEMM loop 257 W, 78 C, 10 min, near-zero PCIe survived
    cudaMemcpy H2D/D2H, 512 MB blocks gen3 x4 saturated, 2,110 GB moved, 10 min survived
    actual inference 93–289 W, bursty dies in 1.6–57 s

    The link test moved two terabytes without one error. But nvidia-smi dmon showed rx and tx alternating, never concurrent — it was unidirectional bulk DMA. Inference issues small transfers bidirectionally and simultaneously, interleaved with compute, and that is what kills it.

    Unidirectional PCIe stress gives a false negative for this fault. Worth knowing before anyone concludes their link is healthy.

    Five things that did NOT fix it

    1. Power and temperature. It survived 257 W / 78 C for 10 minutes, then died at 93 W / 77 C during inference. Same card, same temperature, one third the power. Not thermal, not PSU capacity.
    2. A shorter cable. 0.5 m died at 4.2 s; 1.0 m died at 1.6 s and 4.7 s. Indistinguishable.
    3. Chassis bonding. Both PSUs float on one ungrounded 2-pin outlet, so difference current returns through the cable ground. Bonding the chassis: died at 4.4 s. (Continuity not meter-verified.)
    4. pcie_ports=native. The kernel logs _OSC: OS now controls [AER PCIeCapability LTR DPC] with or without the parameter on this host — verified across four boots with journalctl --list-boots. The firmware already grants those services. Two runs survived 54 s and 57 s with it set, which looked like success until the third died at 3.0 s.
    5. Memory config. 4×32 GB dual-rank at 3200 Gear 1 (beyond Intel's conservative spec). stressapptest, 16 threads, 100 GB, 15 min: zero errors, zero MCE.

    A possible discriminator: @kreggencor-crypto reported AER counters at exactly zero and concluded the link was electrically clean, with the fault in error handling — and pcie_ports=native fixed it. My AER counters do move: a Physical-Layer RxErr immediately precedes each drop. Different root cause, same Xid. If your counters stay at zero, try pcie_ports=native; if you see RxErr, it is margin, and lowering the link generation is the lever.

    What did work

    Back-to-back 78,338-token prompts, no idle gap. Time to Xid 79:

    configuration survival
    gen3, no power cap 1.6 – 57 s (6 of 6 failed)
    gen2, no power cap 3 min 34 s / 5 min 12 s
    gen3 + GPU1 capped at 250 W 7 min 30 s
    gen2 + GPU1 capped at 250 W 30 min, 18 iterations, Xid 0, AER 0

    Neither half survives sustained load alone; together they do. gen2 halves the signalling rate, the cap flattens the current swing — opposite sides of the same margin.

    The counterintuitive part: locking the SM clock to 1000 MHz (→ ~90 W, a 65% cut) passed 3/3 at gen3 but at PP 701 / TG 21 t/s. Capping at 250 W — only 17% — with clocks left free also passed 3/3, at PP 1465 / TG 43 t/s, twice the throughput. Magnitude is not the mechanism: a cap pins the GPU at the ceiling instead of letting it swing to 300 W and back. It died repeatedly at 265–273 W / 79–81 C and then ran 30 minutes clean at 256 W / 79 C.

    Caveats

    This is a mitigation, not a cure, and I want to be explicit because I got this wrong three times in one day: gen2 alone looked solved after five short runs, then died at 3–5 min under continuous load. pcie_ports=native looked solved after two runs, then died on the third. 30 minutes clean is 30 minutes clean. The fault is probabilistic and tracks prefill bursts, not elapsed time — interactive use is far safer than eval batches or long-document passes.

    One machine, and the host-side OCuLink adapter was never swapped — it is the only component in the path I have not tested.

    One suggestion

    A correctable PCIe error means the link recovered; on a marginal external link these are expected. One second later the driver takes the GPU off the bus and requires a node reboot — no retrain, no speed step-down, no graceful degradation. An automatic link-speed step-down on repeated Physical-Layer errors would turn a total loss into a slowdown, and would have saved most of this investigation. Happy to run tests on this hardware for anyone working on that path.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions