ofproto: Convert units correctly in ofport_open().
authorBen Pfaff <blp@nicira.com>
Wed, 4 Sep 2013 20:37:56 +0000 (13:37 -0700)
committerBen Pfaff <blp@nicira.com>
Wed, 4 Sep 2013 20:40:22 +0000 (13:40 -0700)
commitb53d1713ad7ce865c47e3fb8421f27c6a0dcbb9c
tree78da1fd16c7992812ad67aa8e41e6fbe478f8fac
parent08b8ef975633777b47638029ead16a1af90a7f7a
ofproto: Convert units correctly in ofport_open().

netdev_features_to_bps() returns a speed in bps, but struct
ofputil_phy_port's curr_speed and max_speed are in kbps, so a conversion
is necessary.  This commit fixes the problem.

Reported-by: Benjamin Lunsky <benjamin.lunsky@netronome.com>
Tested-by: Benjamin Lunsky <benjamin.lunsky@netronome.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
ofproto/ofproto.c