← Back to Pull requests

platform: report the generation of direct NVSwitches #58

Closed
unknown closed this pull request without merging on Dec 03, 2026 20:31 UTC
View on GitHub
unknown unknown commented on Dec 01, 2026 21:15 UTC
Author

The library says that an NVSwitch has no distinguishing PCI device ID. It says that only BAR0 gives its generation. NVIDIA's driver selects its LR10 or LS10 HAL from the device ID (_nvswitch_setup_hal in open-gpu-kernel-modules src/common/nvswitch/kernel/nvswitch.c). gpu-admin-tools keeps a device ID table for switches beside its BOOT0 table. A consumer that needs the generation before a driver is loaded has to read <bdf>/device from sysfs itself. It also has to keep its own ID table. NVIDIA/nvrc#250 needs the generation to choose a Fabric Manager configuration for HGX A100.

A switch with an unlisted device ID stays in Topology::switches and in fabric(). Dropping it would remove a switch from the fabric. On a node whose switches all have unlisted IDs, fabric_interface() would report no fabric. is_nvswitch keeps the condition main has. The condition is vendor NVIDIA and class 0x0680 with any programming interface. nvidia.ko matches class 0x068000 exactly. nvswitch_probe returns -EINVAL for a device ID in neither of its lists. Neither restriction is copied. Fabric membership does not change.

API changes: Topology::switches is Vec<SwitchFunction> instead of Vec<String>. discover_topology fails when the device attribute of a switch is missing or is not a 16-bit hex value. cc::Switch has a new field, generation.

NVIDIA/nvrc main, kata-device-provisioner c15a2ac and krab preflight c5df786 build against this branch without source changes. Their tests pass.

pci.ids names only 0x1af1 (A100) and 0x22a3 (H100). The other IDs come from the driver lists. The driver source names 0x22a8 to 0x22af as bridge functions of the LS10. The driver selects the LS10 HAL for them. The library reports LS10 for them.

Diff: 219 lines (+164 / -55) across 2 files Reviewer: zvonkok Review duration: 2835m
All Vouch review confidence checks passed
Residual risk 0.14 = Change Risk (0.37) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.37 · 219 lines diff across 2 files
0.37
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
0.17
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
60%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size diff_size
0.323
Shallow Review Depth shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #58"
general weight: 0.35
Reviewers
Assignees
Unassigned
Labels
risk: low confidence: 60.5% reviewed
Vouch Risk Breakdown
AI-powered review risk analysis
Change Risk
Change Risk · Model 1 (XGBoost)
Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
Score: 36.7% (MEDIUM) · Higher = larger blast radius
36.7%
Review Confidence
Review Confidence · Models 2 & 3
Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
Score: 60.5% · Lower = rushed or shallow review
60.5%
Residual Risk
Residual Risk · Core Equation
Residual = Change × (1 − Confidence)
Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
Score: 14.5% · Safe to merge
14.5%