From eed74d8f509bda634bb310dcf054da09319a308b Mon Sep 17 00:00:00 2001
From: Phil Sutter <psutter@redhat.com>
Date: Wed, 24 Feb 2016 10:49:05 +0100
Subject: [PATCH] iplink: add ageing_time, stp_state and priority for bridge
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1270759
Upstream Status: iproute2.git commit fdba05155c700
commit fdba05155c7008d18b5760624c99978ba0d369d4
Author: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
Date: Wed Aug 12 09:11:30 2015 -0700
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 <nikolay@cumulusnetworks.com>
---
ip/iplink_bridge.c | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/ip/iplink_bridge.c b/ip/iplink_bridge.c
index 1e69960..e704e29 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,
--
1.8.3.1