ip: show min and max mtu

Add min/max MTU to the link details

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: David Ahern <dsahern@gmail.com>
This commit is contained in:
Stephen Hemminger 2018-07-27 13:43:50 -07:00 committed by David Ahern
parent 74eb09ad56
commit d97e266e5d
1 changed files with 10 additions and 0 deletions

View File

@ -1012,6 +1012,16 @@ int print_linkinfo(const struct sockaddr_nl *who,
" promiscuity %u ",
rta_getattr_u32(tb[IFLA_PROMISCUITY]));
if (tb[IFLA_MIN_MTU])
print_uint(PRINT_ANY,
"min_mtu", "minmtu %u ",
rta_getattr_u32(tb[IFLA_MIN_MTU]));
if (tb[IFLA_MAX_MTU])
print_uint(PRINT_ANY,
"max_mtu", "maxmtu %u ",
rta_getattr_u32(tb[IFLA_MAX_MTU]));
if (tb[IFLA_LINKINFO])
print_linktype(fp, tb[IFLA_LINKINFO]);