From: Markus Armbruster <armbru@redhat.com>
To: Mitsuru Kariya <Mitsuru.Kariya@oss.nttdata.com>
Cc: qemu-devel@nongnu.org, "Daniel P. Berrangé" <berrange@redhat.com>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Marc-André Lureau" <marcandre.lureau@redhat.com>,
"Philippe Mathieu-Daudé" <philmd@linaro.org>,
"Pierrick Bouvier" <pierrick.bouvier@oss.qualcomm.com>,
"Eric Blake" <eblake@redhat.com>,
"Fabiano Rosas" <farosas@suse.de>,
"Laurent Vivier" <lvivier@redhat.com>,
"Peter Xu" <peterx@redhat.com>,
"Jason Wang" <jasowang@redhat.com>
Subject: Re: [PATCH 2/5] qemu-options: document keep-alive-count/idle/interval for -netdev stream
Date: Tue, 02 Jun 2026 06:38:22 +0200 [thread overview]
Message-ID: <87y0gx8sld.fsf@pond.sub.org> (raw)
In-Reply-To: <20260524073442.435408-3-Mitsuru.Kariya@oss.nttdata.com> (Mitsuru Kariya's message of "Sun, 24 May 2026 16:34:39 +0900")
Mitsuru Kariya <Mitsuru.Kariya@oss.nttdata.com> writes:
> The keep-alive-count, keep-alive-idle and keep-alive-interval members of
> InetSocketAddress have been available for -netdev stream (and every
> other QAPI SocketAddress consumer) since the qemu-sockets keep-alive
> options were extended in 10.1, but were never documented in
> qemu-options.hx.
>
> Add their descriptions, and drop the "Not supported for passive sockets"
> remark from addr.keep-alive=on|off: as of 10.1 keep-alive on listening
> sockets is also supported (see the SocketAddress @keep-alive QAPI doc
> comment, which records "(Since 4.2, not supported for listening sockets
> until 10.1)").
>
> Signed-off-by: Mitsuru Kariya <Mitsuru.Kariya@oss.nttdata.com>
> ---
> qemu-options.hx | 18 +++++++++++++++---
> 1 file changed, 15 insertions(+), 3 deletions(-)
>
> diff --git a/qemu-options.hx b/qemu-options.hx
> index 527fc12494..7432b77571 100644
> --- a/qemu-options.hx
> +++ b/qemu-options.hx
> @@ -3034,7 +3034,7 @@ DEF("netdev", HAS_ARG, QEMU_OPTION_netdev,
> "-netdev socket,id=str[,fd=h][,udp=host:port][,localaddr=host:port]\n"
> " configure a network backend to connect to another network\n"
> " using an UDP tunnel\n"
> - "-netdev stream,id=str[,server=on|off],addr.type=inet,addr.host=host,addr.port=port[,addr.to=maxport][,addr.numeric=on|off][,addr.keep-alive=on|off][,addr.mptcp=on|off][,addr.ipv4=on|off][,addr.ipv6=on|off][,reconnect-ms=milliseconds]\n"
> + "-netdev stream,id=str[,server=on|off],addr.type=inet,addr.host=host,addr.port=port[,addr.to=maxport][,addr.numeric=on|off][,addr.keep-alive=on|off][,addr.keep-alive-count=count][,addr.keep-alive-idle=idle][,addr.keep-alive-interval=interval][,addr.mptcp=on|off][,addr.ipv4=on|off][,addr.ipv6=on|off][,reconnect-ms=milliseconds]\n"
> "-netdev stream,id=str[,server=on|off],addr.type=unix,addr.path=path[,addr.abstract=on|off][,addr.tight=on|off][,reconnect-ms=milliseconds]\n"
> "-netdev stream,id=str[,server=on|off],addr.type=fd,addr.str=file-descriptor[,reconnect-ms=milliseconds]\n"
> " configure a network backend to connect to another network\n"
> @@ -3640,7 +3640,7 @@ SRST
> -device e1000,netdev=n1,mac=52:54:00:12:34:56 \\
> -netdev socket,id=n1,mcast=239.192.168.1:1102,localaddr=1.2.3.4
>
> -``-netdev stream,id=str[,server=on|off],addr.type=inet,addr.host=host,addr.port=port[,addr.to=maxport][,addr.numeric=on|off][,addr.keep-alive=on|off][,addr.mptcp=on|off][,addr.ipv4=on|off][,addr.ipv6=on|off][,reconnect-ms=milliseconds]``
> +``-netdev stream,id=str[,server=on|off],addr.type=inet,addr.host=host,addr.port=port[,addr.to=maxport][,addr.numeric=on|off][,addr.keep-alive=on|off][,addr.keep-alive-count=count][,addr.keep-alive-idle=idle][,addr.keep-alive-interval=interval][,addr.mptcp=on|off][,addr.ipv4=on|off][,addr.ipv6=on|off][,reconnect-ms=milliseconds]``
> Configure a network backend to connect to another QEMU virtual machine or a proxy using a TCP/IP socket.
>
> ``server=on|off``
> @@ -3656,7 +3656,19 @@ SRST
> if ``on`` ``host`` and ``port`` are guaranteed to be numeric, otherwise a name resolution should be attempted (default: ``off``)
>
> ``addr.keep-alive=on|off``
> - enable keep-alive when connecting to this socket. Not supported for passive sockets.
> + enable keep-alive when connecting to this socket.
> +
> + ``addr.keep-alive-count=count``
> + number of keep-alive packets to send before dropping the connection.
> + Set to 0 to use the system default. (default: 0)
> +
> + ``addr.keep-alive-idle=idle``
> + time in seconds the connection needs to be idle before sending keep-alive packets.
> + Set to 0 to use the system default. (default: 0)
> +
> + ``addr.keep-alive-interval=interval``
> + time in seconds between individual keep-alive packets.
> + Set to 0 to use the system default. (default: 0)
>
> ``addr.mptcp=on|off``
> enable multipath TCP
You document these options only for -netdev stream. They also work for
-netdev dgram, possibly more (didn't check). Shouldn't we document them
every where they work?
next prev parent reply other threads:[~2026-06-02 4:38 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-24 7:34 [PATCH 0/5] socket: add TCP_USER_TIMEOUT, fix -netdev stream option docs Mitsuru Kariya
2026-05-24 7:34 ` [PATCH 1/5] qemu-options: fix missing addr. prefix on -netdev stream inet/unix options Mitsuru Kariya
2026-06-02 4:33 ` Markus Armbruster
2026-05-24 7:34 ` [PATCH 2/5] qemu-options: document keep-alive-count/idle/interval for -netdev stream Mitsuru Kariya
2026-06-02 4:38 ` Markus Armbruster [this message]
2026-05-24 7:34 ` [PATCH 3/5] qemu-options: document keep-alive*/numeric/mptcp for -incoming tcp: Mitsuru Kariya
2026-05-24 7:34 ` [PATCH 4/5] util/qemu-sockets: add TCP_USER_TIMEOUT support Mitsuru Kariya
2026-06-02 4:54 ` Markus Armbruster
2026-05-24 7:34 ` [PATCH 5/5] tests/qtest/netdev-socket: smoke test -netdev stream inet option set Mitsuru Kariya
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=87y0gx8sld.fsf@pond.sub.org \
--to=armbru@redhat.com \
--cc=Mitsuru.Kariya@oss.nttdata.com \
--cc=berrange@redhat.com \
--cc=eblake@redhat.com \
--cc=farosas@suse.de \
--cc=jasowang@redhat.com \
--cc=lvivier@redhat.com \
--cc=marcandre.lureau@redhat.com \
--cc=pbonzini@redhat.com \
--cc=peterx@redhat.com \
--cc=philmd@linaro.org \
--cc=pierrick.bouvier@oss.qualcomm.com \
--cc=qemu-devel@nongnu.org \
/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.