As /sys/class/net/<iface>/speed indicates a value in Mbits/sec, the
conversion is necessary to create the correct limits.
This guarantees the same result for the following commands in an
1000Mbit/sec device:
tc class add ... htb rate 500Mbit
tc class add ... htb rate 50%
Fixes: 927e3cfb52b5 ("tc: B.W limits can now be specified in %.") Signed-off-by: Marcos Antonio Moraes <marcos.antonio@digirati.com.br> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>