The relevant piece of code seems to be src/sys/net/if.c lines 2912-2966: "add a group to an interface". This code is for the initiated, as expected. The title is counterintuitive, because an interface is a physical interface, to be added to a logical group like egress. So, I am not sure this is the right piece of code anyway. What I am trying to do is to pinpoint where, in the code, the interface is selected for membership to egress.
On Wednesday, April 2nd, 2025 at 12:31 PM, otto.cooper <otto.cooper@proton.me> wrote:
> On all OpenBSD systems around here, the interface with index 1 is the only one in group egress. It seems that OpenBSD blindly does so, based on what interface comes first at boot time (and its live connection), which depends on its position on the PCI bus, which ultimately defines its ifconfig "index".
>
> From /var/run/dmesg.boot:
>
> ix0 at pci5 dev 0 function 0 "Intel X552 SFP+" rev 0x00, msix, 4 queues, address ac:1f:6b:6d:1e:f4
> ix1 at pci5 dev 0 function 1 "Intel X552 SFP+" rev 0x00, msix, 4 queues, address ac:1f:6b:6d:1e:f5
> em0 at pci10 dev 0 function 0 "Intel I210" rev 0x03: msi, address ac:1f:6b:6d:1d:64
> em1 at pci11 dev 0 function 0 "Intel I210" rev 0x03: msi, address ac:1f:6b:6d:1d:65
>
> ifconfig(8) does not mention the possibility of changing the index.
>
> Changing priority did not help.
>
> I am not going to read the source code to understand why this is failing.
No comments:
Post a Comment