Uploaded image for project: 'vpp'
  1. vpp
  2. VPP-2095

Mac API needs a type update and is generally a bit inconsistent

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Low Low
    • None
    • None
    • None
    • None

      sw_interface_add_del_mac_address() is the one remaining place in interface.api that uses a u32 for the sw_if_index instead of the strong interface index type.

      Aside from that, we have a primary MAC (this appears to be the l2_address of sw_interface_details, the response to sw_interface_get_mac_address, and set by sw_interface_set_mac_address) and also a list of secondaries (sw_interface_add_del_mac_address).

      I would suggest that add_del_mac_address should be add_del_secondary{_}mac_address to make clear what it does, and we're missing a dumper for this information - it doesn't appear to be possible to list mac addresses, or at least it's not clear how you might do that.  Going a step further, we're inconsistent on object property names (l2_address, mac_address and mac).

            Unassigned Unassigned
            ijw Ian Wells
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: