From: Jiri Pirko Date: Wed, 8 Jul 2015 15:08:18 +0000 (+0200) Subject: iproute2: ipa: show switch id X-Git-Tag: v4.2.0~45 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=122f2fc5739c1ba9967775581201eefece855602;p=thirdparty%2Fiproute2.git iproute2: ipa: show switch id We forgot to include this patch somehow. So do it now. Signed-off-by: Jiri Pirko Acked-by: Andy Gospodarek --- diff --git a/ip/ipaddress.c b/ip/ipaddress.c index 85a81ba6a..b7b4e3e67 100644 --- a/ip/ipaddress.c +++ b/ip/ipaddress.c @@ -688,6 +688,14 @@ int print_linkinfo(const struct sockaddr_nl *who, b1, sizeof(b1))); } + if (tb[IFLA_PHYS_SWITCH_ID]) { + SPRINT_BUF(b1); + fprintf(fp, "switchid %s ", + hexstring_n2a(RTA_DATA(tb[IFLA_PHYS_SWITCH_ID]), + RTA_PAYLOAD(tb[IFLA_PHYS_SWITCH_ID]), + b1, sizeof(b1))); + } + if (tb[IFLA_OPERSTATE]) print_operstate(fp, rta_getattr_u8(tb[IFLA_OPERSTATE]));