B.A.T.M.A.N Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Sven Eckelmann <sven@narfation.org>
To: noahbpeterson1997@gmail.com
Cc: b.a.t.m.a.n@lists.open-mesh.org
Subject: Re: [PATCH] batctl: neighbor: Fix print neighbors table header
Date: Sun, 08 Sep 2024 20:12:39 +0200	[thread overview]
Message-ID: <2343687.ElGaqSPkdT@sven-l14> (raw)
In-Reply-To: <172581746841.965.10559798237378220086@diktynna.open-mesh.org>

[-- Attachment #1: Type: text/plain, Size: 1626 bytes --]

On Sunday, 8 September 2024 19:44:28 CEST noahbpeterson1997@gmail.com wrote:
> netlink_print_neighbors() now prints the correct header to match what
> batman-advanced currently outputs.

This is wrong, this is not what it outputs for the default B.A.T.M.A.N. IV:

    $ batctl n
    [B.A.T.M.A.N. adv 2024.0-openwrt-2, MainIF/MAC: primary0/ae:1b:bf:52:25:5b (bat0/52:54:00:ec:00:01 BATMAN_IV)]
    IF             Neighbor              last-seen
            vxlan     16:7b:3c:c2:bf:bc    2.880s
         mesh-vpn     02:12:7b:00:04:01    0.830s

[...]
>  Example::
>  
> -  IF             Neighbor              last-seen
> -         enp0s1     16:7b:3c:c2:bf:b8    4.612s
> -         enp0s1     ae:1b:bf:52:25:58    0.740s
> +           Neighbor   last-seen      speed           IF
> +  16:7b:3c:c2:bf:b8    4.612s (     1000.0) [     enp0s1]
> +  ae:1b:bf:52:25:58    0.740s (     1000.0) [     enp0s1]
>  
>  
>  batctl originators
> diff --git a/neighbors.c b/neighbors.c
> index 3102b0e..9dcdb81 100644
> --- a/neighbors.c
> +++ b/neighbors.c
> @@ -121,7 +121,7 @@ static int netlink_print_neighbors(struct state *state, char *orig_iface,
>  {
>         return netlink_print_common(state, orig_iface, read_opts,
>                                     orig_timeout, watch_interval,
> -                                   "IF             Neighbor              last-seen\n",
> +                                       "         Neighbor   last-seen      speed           IF\n",
>                                     BATADV_CMD_GET_NEIGHBORS,
>                                     neighbors_callback);
>  }
> 

Kind regards,
	Sven

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

  reply	other threads:[~2024-09-08 18:13 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-08 17:44 [PATCH] batctl: neighbor: Fix print neighbors table header noahbpeterson1997
2024-09-08 18:12 ` Sven Eckelmann [this message]
2024-09-08 19:47   ` noahbpeterson1997
2024-09-09  9:29     ` Sven Eckelmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2343687.ElGaqSPkdT@sven-l14 \
    --to=sven@narfation.org \
    --cc=b.a.t.m.a.n@lists.open-mesh.org \
    --cc=noahbpeterson1997@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox