> One of the things I having a hard time understanding is: where is > hw_address allocated for vnet_hw_interface_t ? > I cannot find it anywhere.
It is allocated when registering an interface which uses a hw_address. The common case is Ethernet: ethernet_register_interface() ethernet_set_mac () vec_validate (hi->hw_address, sizeof (mac_address_t) - 1) If your question is who decide which mac address is to be used, it is driver-dependent: HW-backed drivers (eg. AVF) tends to use the NIC mac, others (eg. tap) will generate a random mac at creation time. ben
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#19095): https://lists.fd.io/g/vpp-dev/message/19095 Mute This Topic: https://lists.fd.io/mt/81796186/21656 Group Owner: vpp-dev+ow...@lists.fd.io Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-