From: Nikolay Aleksandrov Date: Wed, 12 Aug 2015 16:11:30 +0000 (-0700) Subject: iplink: add ageing_time, stp_state and priority for bridge X-Git-Tag: v4.2.0~24 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fdba05155c7008d18b5760624c99978ba0d369d4;p=thirdparty%2Fiproute2.git iplink: add ageing_time, stp_state and priority for bridge When showing bridge attributes, show also ageing_time, stp_state and priority if available. Signed-off-by: Nikolay Aleksandrov --- diff --git a/ip/iplink_bridge.c b/ip/iplink_bridge.c index 1e699601f..e704e290c 100644 --- a/ip/iplink_bridge.c +++ b/ip/iplink_bridge.c @@ -114,6 +114,18 @@ static void bridge_print_opt(struct link_util *lu, FILE *f, struct rtattr *tb[]) if (tb[IFLA_BR_MAX_AGE]) fprintf(f, "max_age %u ", rta_getattr_u32(tb[IFLA_BR_MAX_AGE])); + + if (tb[IFLA_BR_AGEING_TIME]) + fprintf(f, "ageing_time %u ", + rta_getattr_u32(tb[IFLA_BR_AGEING_TIME])); + + if (tb[IFLA_BR_STP_STATE]) + fprintf(f, "stp_state %u ", + rta_getattr_u32(tb[IFLA_BR_STP_STATE])); + + if (tb[IFLA_BR_PRIORITY]) + fprintf(f, "priority %u ", + rta_getattr_u16(tb[IFLA_BR_PRIORITY])); } static void bridge_print_help(struct link_util *lu, int argc, char **argv,