]> git.ipfire.org Git - thirdparty/iproute2.git/commitdiff
ss: mptcp: subflow: display seq counters as decimal
authorMatthieu Baerts (NGI0) <matttbe@kernel.org>
Wed, 26 Feb 2025 11:08:44 +0000 (12:08 +0100)
committerStephen Hemminger <stephen@networkplumber.org>
Mon, 10 Mar 2025 16:12:45 +0000 (09:12 -0700)
This is similar to commit cfa70237 ("ss: mptcp: display seq related
counters as decimal") but for the subflow info this time. This is also
aligned with what is printed for TCP sockets.

That looks better to do the same with the subflow info (ss -ti), to
compare with the MPTCP info (ss -Mi), or for those who want to easily
count how many bytes have been exchanged between two runs without having
to think in hexa.

Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
misc/ss.c

index aef1a714b130900d6f3061c150639235c1eb13ca..6d5976501467842b1681d7dfc1ca56cc1b4a98d5 100644 (file)
--- a/misc/ss.c
+++ b/misc/ss.c
@@ -3055,16 +3055,16 @@ static void mptcp_subflow_info(struct rtattr *tb[])
                    rta_getattr_u32(tb[MPTCP_SUBFLOW_ATTR_TOKEN_LOC]),
                    rta_getattr_u8(tb[MPTCP_SUBFLOW_ATTR_ID_LOC]));
        if (tb[MPTCP_SUBFLOW_ATTR_MAP_SEQ])
-               out(" seq:%llx",
+               out(" seq:%llu",
                    rta_getattr_u64(tb[MPTCP_SUBFLOW_ATTR_MAP_SEQ]));
        if (tb[MPTCP_SUBFLOW_ATTR_MAP_SFSEQ])
-               out(" sfseq:%x",
+               out(" sfseq:%u",
                    rta_getattr_u32(tb[MPTCP_SUBFLOW_ATTR_MAP_SFSEQ]));
        if (tb[MPTCP_SUBFLOW_ATTR_SSN_OFFSET])
-               out(" ssnoff:%x",
+               out(" ssnoff:%u",
                    rta_getattr_u32(tb[MPTCP_SUBFLOW_ATTR_SSN_OFFSET]));
        if (tb[MPTCP_SUBFLOW_ATTR_MAP_DATALEN])
-               out(" maplen:%x",
+               out(" maplen:%u",
                    rta_getattr_u32(tb[MPTCP_SUBFLOW_ATTR_MAP_DATALEN]));
 }