All of lore.kernel.org
 help / color / mirror / Atom feed
From: Philippe Gerum <rpm@xenomai.org>
To: Hannes Diethelm <hannes.diethelm@gmail.com>
Cc: xenomai@lists.linux.dev
Subject: Re: [PATCH 1/1] tidbits: net-ping: add ping tidbit using raw socket
Date: Sun, 05 Jul 2026 16:57:49 +0200	[thread overview]
Message-ID: <87y0fpmqky.fsf@xenomai.org> (raw)
In-Reply-To: <20260628153956.1435330-2-hannes.diethelm@gmail.com> (Hannes Diethelm's message of "Sun, 28 Jun 2026 17:39:56 +0200")

Hannes Diethelm <hannes.diethelm@gmail.com> writes:

> This tidbit allows to ping any host and measure the response time.
>
> Signed-off-by: Hannes Diethelm <hannes.diethelm@gmail.com>
> ---
>  tidbits/meson.build    |   6 +
>  tidbits/oob-net-ping.c | 480 +++++++++++++++++++++++++++++++++++++++++
>  2 files changed, 486 insertions(+)
>  create mode 100644 tidbits/oob-net-ping.c
>

Thanks. We need this to build on 32bit systems:

--- a/tidbits/oob-net-ping.c
+++ b/tidbits/oob-net-ping.c
@@ -215,7 +215,7 @@ static size_t build_icmp_request(uint8_t *o_frame, size_t icmplen,
 	icmphdr->checksum = cksum;
 
 	if (verbosity > 1) {
-		evl_printf("ip_len=%zd, icmp_len=%zd, ip_len=%d, datalen=%ld\n",
+		evl_printf("ip_len=%zd, icmp_len=%zd, ip_len=%d, datalen=%zu\n",
 			   sizeof(*iphdr), sizeof(struct icmphdr),
 			   ntohs(iphdr->ip_len), datalen);
 		print_ip_header(iphdr);

What about turning this code into the (currently missing) 'evl-ping'
utility? I believe it is of general interest to any user.

-- 
Philippe.

  reply	other threads:[~2026-07-05 15:10 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-28 15:39 [PATCH 0/1] tidbits: net-ping: add ping tidbit using raw socket Hannes Diethelm
2026-06-28 15:39 ` [PATCH 1/1] " Hannes Diethelm
2026-07-05 14:57   ` Philippe Gerum [this message]
2026-07-05 15:27     ` Hannes Diethelm
2026-07-05 16:52       ` Philippe Gerum
2026-07-05 15:01 ` [PATCH 0/1] " Philippe Gerum
2026-07-05 15:21   ` Hannes Diethelm
2026-07-05 16:49     ` Philippe Gerum
2026-07-05 22:17       ` Hannes Diethelm
2026-07-05 23:57         ` Hannes Diethelm

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=87y0fpmqky.fsf@xenomai.org \
    --to=rpm@xenomai.org \
    --cc=hannes.diethelm@gmail.com \
    --cc=xenomai@lists.linux.dev \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.