ofproto: Consistently use netdev's name instead of ofp_phy_port name.
authorBen Pfaff <blp@nicira.com>
Wed, 20 Apr 2011 20:03:45 +0000 (13:03 -0700)
committerBen Pfaff <blp@nicira.com>
Fri, 29 Apr 2011 21:32:00 +0000 (14:32 -0700)
commitf64503041d96729427b8d882e3b7fd3552b43a6a
tree2ed1c27da13a740b8915ee0aae7b6114c9a1e089
parent66105f0e2cbd40d64bb80d77fff9c65014577050
ofproto: Consistently use netdev's name instead of ofp_phy_port name.

There are at least two ways to get an ofport's name: from the netdev using
netdev_get_name() or from the ofp_phy_port's 'name' member.  Some code used
one, some used the other.  This switches all relevant code to use only
netdev_get_name(), because the 'name' member in ofp_phy_port is
fixed-length and thus a long name could be truncated.

This isn't a problem under Linux since the maximum length of a network
device's name under Linux is the same as the field width in ofp_phy_port.
ofproto/ofproto.c