vswitchd: Do not choose generated MAC address for local port.
ovs-vswitchd needs to choose a sensible MAC address for the local port of
a bridge. Until now, the algorithm has ignored certain interfaces, in
particular internal interfaces and those with the MAC addresses that
indicate that they are probably Xen VIFs. The goal is to choose a physical
interface's MAC address because this is more stable and more likely to
be meaningful to the outside world. Stability, in turn, is important
because the MAC address of the local port is used as the default datapath
ID for OpenFlow connections.
This existing algorithm was too specialized to work well with the new
kinds of ports that we have been introducing in OVS. In particular,
GRE ports could be chosen as the MAC address. This commit changes the
algorithm for choosing the local port MAC address. Now it ignores any
interface that has the "local" bit set in its MAC address, which
catches GRE ports. The new rule also catches the VIF and internal
port cases, so this commit also deletes those special cases.
This commit deleted the only user of eth_addr_is_vif(), so it deletes
that function also.
Jesse Gross suggested this revised heuristic.
CC: Jeremy Stribling <strib@nicira.com>