From a098673511d75a0d50f4c1ac98d793124067fcae Mon Sep 17 00:00:00 2001 From: Chet Nichols III Date: Sun, 21 Jun 2026 22:23:21 -0700 Subject: [PATCH] docs: note the full-pair requirement in fetch_host_primary_interface_mac The doc comment on fetch_host_primary_interface_mac (added with the declared-primary support) said a declared primary wins "when this report has that NIC", but the actual gate -- find_interface_id_for_mac -- needs a full pair: the MAC present on a system ethernet interface AND a non-empty Redfish interface id. A declared NIC whose id this report has not resolved yet falls back to the automatic DPU-PF pick, alongside the no-declaration case. Spell that out so a reader of the doc alone does not expect any in-report MAC to win. Behavior is unchanged. Part of #2662 (epic #2660). Signed-off-by: Chet Nichols III --- crates/api-model/src/site_explorer/mod.rs | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/crates/api-model/src/site_explorer/mod.rs b/crates/api-model/src/site_explorer/mod.rs index 438b18e3bb..f40daf3a20 100644 --- a/crates/api-model/src/site_explorer/mod.rs +++ b/crates/api-model/src/site_explorer/mod.rs @@ -310,11 +310,14 @@ impl EndpointExplorationReport { /// The boot interface MAC for this endpoint's explored default -- the boot /// interface site-explorer records before any machine owns the endpoint. /// - /// A declared `ExpectedHostNic.primary` wins when this report has that NIC, - /// whatever its type (an integrated NIC as readily as a DPU host-PF), so the - /// explored default agrees with the managed store's declared primary across - /// the ownership handoff. Absent a declaration, it falls back to the - /// automatic pick: the lowest-PCI DPU host-PF interface. + /// A declared `ExpectedHostNic.primary` wins when this report has that NIC + /// as a full pair -- its MAC present on a system ethernet interface with a + /// non-empty Redfish interface id -- whatever its type (an integrated NIC as + /// readily as a DPU host-PF), so the explored default agrees with the managed + /// store's declared primary across the ownership handoff. A declared NIC + /// whose id this report has not resolved yet falls back, alongside the + /// no-declaration case, to the automatic pick: the lowest-PCI DPU host-PF + /// interface. pub fn fetch_host_primary_interface_mac( &self, explored_dpus: &[ExploredDpu],