Skip to content

[linux-nvidia-6.18-next] PCI: mirror PI7C9X3G606GPC Port 4 BAR0#447

Open
nirmoy wants to merge 1 commit into
NVIDIA:linux-nvidia-6.18-nextfrom
nirmoy:codex/pericom-msix-bar-war-6.18
Open

[linux-nvidia-6.18-next] PCI: mirror PI7C9X3G606GPC Port 4 BAR0#447
nirmoy wants to merge 1 commit into
NVIDIA:linux-nvidia-6.18-nextfrom
nirmoy:codex/pericom-msix-bar-war-6.18

Conversation

@nirmoy
Copy link
Copy Markdown
Collaborator

@nirmoy nirmoy commented May 28, 2026

Summary

  • Add a PCI final/resume quirk for the Diodes/Pericom PI7C9X3G606GPC switch.
  • Mirror the immediate upstream port BAR0 value into downstream Port 4 BAR0 after Linux PCI resource assignment and after resume.
  • Scope the WAR to the Diodes-confirmed OS-visible Tile0/P4 mapping: upstream bus + 1, device 04, function 0.
  • Port 4 BAR0 can read back as zero through normal PCI config space even after a successful write, so the quirk rewrites BAR0 whenever it runs.

Validation

  • Local patch checks at head 8654dc24d9b6bcad10b527cb9c11e64c7aab48c9 passed:
    • scripts/checkpatch.pl --strict --ignore GERRIT_CHANGE_ID --git HEAD
    • git diff --check HEAD~1..HEAD
  • Built arm64 packages on the GB200 build host with make bindeb-pkg and installed image/headers on the Quark DUT.
  • The current PR head 8654dc24d9b6bcad10b527cb9c11e64c7aab48c9 is a message-only respin from the tested package commit 7f1b4f6fd0544b30133c956da5022f49c8fe8b71; git diff 7f1b4f6fd0544b30133c956da5022f49c8fe8b71..8654dc24d9b6bcad10b527cb9c11e64c7aab48c9 --stat is empty.
  • Booted the DUT on the PR kernel:
Linux localhost-right 6.18.33-pr447-pericom+ #pr447 SMP PREEMPT_DYNAMIC Thu May 28 20:46:09 UTC 2026 aarch64
/dev/nvme0n1p2[/@root/versions/v-diagos-snapshot-20260421] btrfs rw,relatime,ssd,discard=async,space_cache=v2,subvolid=264,subvol=/@root/versions/v-diagos-snapshot-20260421
  • Confirmed the affected topology and quirk application from the boot journal:
pci 0002:a1:00.0: BAR 0 [mem 0x10300000-0x1037ffff]
pci 0002:a2:04.0: [12d8:c008] type 01 class 0x060400 PCIe Switch Downstream Port
pci 0002:a3:00.0: [1344:51c3] type 00 class 0x010802 PCIe Endpoint
pci 0002:a1:00.0: BAR 0 [mem 0x10300000-0x1037ffff]: assigned
pci 0002:a2:04.0: wrote upstream BAR 0 0x10300000 to Port 4 BAR 0 for PI7C9X3G606GPC BAR0 mirror workaround
  • Ran a 300 second NVMe-backed rootfs fio smoke test:
pr447-rootfs-smoke: err= 0
READ: bw=251MiB/s, io=73.6GiB, run=300001msec
WRITE: bw=108MiB/s, io=31.6GiB, run=300001msec
  • Post-fio journalctl -b -k scan for BTRFS error|I/O error|nvme.*timeout|device inaccessible|read-only|blk_update_request|Buffer I/O error returned no matches.
  • Did not use the Diodes BMC/I2C BAR0 readback helper in this validation run. That helper uses special CPED/CDEP programming and is not a supported production validation path on this platform.

References

Launchpad: https://bugs.launchpad.net/ubuntu/+source/linux-nvidia-6.17/+bug/2154457

6.17 PR: #442
BOS PR: #443
NVBug: https://nvbugspro.nvidia.com/bug/6205517
NVBug: https://nvbugspro.nvidia.com/bug/6134331

@nirmoy nirmoy added the help wanted Extra attention is needed label May 28, 2026
@nirmoy
Copy link
Copy Markdown
Collaborator Author

nirmoy commented May 28, 2026

Boro review

Summary

No issues found across the reviewed commits.

Findings: no problems found

Latest watcher review: open review

Kernel deb build: successful (download debs, 4 files)

Head: 8654dc24d9b6

This comment is maintained by nv-pr-bot. It is updated when the GitHub watcher publishes a newer review.

@nirmoy nirmoy removed the help wanted Extra attention is needed label May 28, 2026
@nirmoy nirmoy force-pushed the codex/pericom-msix-bar-war-6.18 branch 2 times, most recently from 55587b6 to 7f1b4f6 Compare May 28, 2026 20:42
@nirmoy nirmoy marked this pull request as ready for review May 28, 2026 21:01
@nirmoy nirmoy added the help wanted Extra attention is needed label May 28, 2026
Some Pericom/Diodes PI7C9X3G606GPC switches require downstream Port 4
BAR0 to mirror BAR0 of the immediate upstream port. Firmware may apply
this during boot, but Linux PCI resource assignment can move the
upstream BAR0 and leave Port 4 without the required mirror.

Diodes confirmed that Tile0/P4 is OS-visible as device 04, function 0
on the bus below the upstream port. Add a final and resume quirk for
that downstream function. The quirk verifies that the immediate upstream
bridge is the same switch, then writes Port 4 BAR0 from the upstream
BAR0 after resource assignment and after resume. Port 4 BAR0 may read
back as zero even after a successful write, so the write must be
validated by platform-specific means.

Signed-off-by: Nirmoy Das <nirmoyd@nvidia.com>
@nirmoy nirmoy force-pushed the codex/pericom-msix-bar-war-6.18 branch from 7f1b4f6 to 8654dc2 Compare May 29, 2026 13:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

help wanted Extra attention is needed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant