[PATCH] qemu-ga: document vsock-listen in the man page

Stefan Hajnoczi posted 1 patch 4 years, 1 month ago
Test docker-mingw@fedora passed
Test docker-quick@centos7 passed
Test checkpatch passed
Test FreeBSD passed
Test asan passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20200323110408.309111-1-stefanha@redhat.com
docs/interop/qemu-ga.rst | 5 +++--
qga/main.c               | 4 +++-
2 files changed, 6 insertions(+), 3 deletions(-)
[PATCH] qemu-ga: document vsock-listen in the man page
Posted by Stefan Hajnoczi 4 years, 1 month ago
Although qemu-ga has supported vsock since 2016 it was not documented on
the man page.

Also add the socket address representation to the qga --help output.

Fixes: 586ef5dee77180fc32e33bc08051600030630239
       ("qga: add vsock-listen method")
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
---
 docs/interop/qemu-ga.rst | 5 +++--
 qga/main.c               | 4 +++-
 2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/docs/interop/qemu-ga.rst b/docs/interop/qemu-ga.rst
index 1313a4ae1c..3063357bb5 100644
--- a/docs/interop/qemu-ga.rst
+++ b/docs/interop/qemu-ga.rst
@@ -36,13 +36,14 @@ Options
 .. option:: -m, --method=METHOD
 
   Transport method: one of ``unix-listen``, ``virtio-serial``, or
-  ``isa-serial`` (``virtio-serial`` is the default).
+  ``isa-serial``, or ``vsock-listen`` (``virtio-serial`` is the default).
 
 .. option:: -p, --path=PATH
 
   Device/socket path (the default for virtio-serial is
   ``/dev/virtio-ports/org.qemu.guest_agent.0``,
-  the default for isa-serial is ``/dev/ttyS0``)
+  the default for isa-serial is ``/dev/ttyS0``). Socket addresses for
+  vsock-listen are written as ``<cid>:<port>``.
 
 .. option:: -l, --logfile=PATH
 
diff --git a/qga/main.c b/qga/main.c
index 8ee2736f8e..f0e454f28d 100644
--- a/qga/main.c
+++ b/qga/main.c
@@ -234,7 +234,9 @@ QEMU_COPYRIGHT "\n"
 "  -p, --path        device/socket path (the default for virtio-serial is:\n"
 "                    %s,\n"
 "                    the default for isa-serial is:\n"
-"                    %s)\n"
+"                    %s).\n"
+"                    Socket addresses for vsock-listen are written as\n"
+"                    <cid>:<port>.\n"
 "  -l, --logfile     set logfile path, logs to stderr by default\n"
 "  -f, --pidfile     specify pidfile (default is %s)\n"
 #ifdef CONFIG_FSFREEZE
-- 
2.24.1

Re: [PATCH] qemu-ga: document vsock-listen in the man page
Posted by Marc-André Lureau 4 years, 1 month ago
Hi

On Mon, Mar 23, 2020 at 12:04 PM Stefan Hajnoczi <stefanha@redhat.com> wrote:
>
> Although qemu-ga has supported vsock since 2016 it was not documented on
> the man page.
>
> Also add the socket address representation to the qga --help output.
>
> Fixes: 586ef5dee77180fc32e33bc08051600030630239
>        ("qga: add vsock-listen method")
> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>

Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>


> ---
>  docs/interop/qemu-ga.rst | 5 +++--
>  qga/main.c               | 4 +++-
>  2 files changed, 6 insertions(+), 3 deletions(-)
>
> diff --git a/docs/interop/qemu-ga.rst b/docs/interop/qemu-ga.rst
> index 1313a4ae1c..3063357bb5 100644
> --- a/docs/interop/qemu-ga.rst
> +++ b/docs/interop/qemu-ga.rst
> @@ -36,13 +36,14 @@ Options
>  .. option:: -m, --method=METHOD
>
>    Transport method: one of ``unix-listen``, ``virtio-serial``, or
> -  ``isa-serial`` (``virtio-serial`` is the default).
> +  ``isa-serial``, or ``vsock-listen`` (``virtio-serial`` is the default).
>
>  .. option:: -p, --path=PATH
>
>    Device/socket path (the default for virtio-serial is
>    ``/dev/virtio-ports/org.qemu.guest_agent.0``,
> -  the default for isa-serial is ``/dev/ttyS0``)
> +  the default for isa-serial is ``/dev/ttyS0``). Socket addresses for
> +  vsock-listen are written as ``<cid>:<port>``.
>
>  .. option:: -l, --logfile=PATH
>
> diff --git a/qga/main.c b/qga/main.c
> index 8ee2736f8e..f0e454f28d 100644
> --- a/qga/main.c
> +++ b/qga/main.c
> @@ -234,7 +234,9 @@ QEMU_COPYRIGHT "\n"
>  "  -p, --path        device/socket path (the default for virtio-serial is:\n"
>  "                    %s,\n"
>  "                    the default for isa-serial is:\n"
> -"                    %s)\n"
> +"                    %s).\n"
> +"                    Socket addresses for vsock-listen are written as\n"
> +"                    <cid>:<port>.\n"
>  "  -l, --logfile     set logfile path, logs to stderr by default\n"
>  "  -f, --pidfile     specify pidfile (default is %s)\n"
>  #ifdef CONFIG_FSFREEZE
> --
> 2.24.1
>


-- 
Marc-André Lureau

Re: [PATCH] qemu-ga: document vsock-listen in the man page
Posted by Stefano Garzarella 4 years, 1 month ago
On Mon, Mar 23, 2020 at 11:04:08AM +0000, Stefan Hajnoczi wrote:
> Although qemu-ga has supported vsock since 2016 it was not documented on
> the man page.
> 
> Also add the socket address representation to the qga --help output.
> 
> Fixes: 586ef5dee77180fc32e33bc08051600030630239
>        ("qga: add vsock-listen method")
> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
> ---
>  docs/interop/qemu-ga.rst | 5 +++--
>  qga/main.c               | 4 +++-
>  2 files changed, 6 insertions(+), 3 deletions(-)
> 
> diff --git a/docs/interop/qemu-ga.rst b/docs/interop/qemu-ga.rst
> index 1313a4ae1c..3063357bb5 100644
> --- a/docs/interop/qemu-ga.rst
> +++ b/docs/interop/qemu-ga.rst
> @@ -36,13 +36,14 @@ Options
>  .. option:: -m, --method=METHOD
>  
>    Transport method: one of ``unix-listen``, ``virtio-serial``, or
> -  ``isa-serial`` (``virtio-serial`` is the default).
> +  ``isa-serial``, or ``vsock-listen`` (``virtio-serial`` is the default).
>  
>  .. option:: -p, --path=PATH
>  
>    Device/socket path (the default for virtio-serial is
>    ``/dev/virtio-ports/org.qemu.guest_agent.0``,
> -  the default for isa-serial is ``/dev/ttyS0``)
> +  the default for isa-serial is ``/dev/ttyS0``). Socket addresses for
> +  vsock-listen are written as ``<cid>:<port>``.
>  
>  .. option:: -l, --logfile=PATH
>  
> diff --git a/qga/main.c b/qga/main.c
> index 8ee2736f8e..f0e454f28d 100644
> --- a/qga/main.c
> +++ b/qga/main.c
> @@ -234,7 +234,9 @@ QEMU_COPYRIGHT "\n"
>  "  -p, --path        device/socket path (the default for virtio-serial is:\n"
>  "                    %s,\n"
>  "                    the default for isa-serial is:\n"
> -"                    %s)\n"
> +"                    %s).\n"
> +"                    Socket addresses for vsock-listen are written as\n"
> +"                    <cid>:<port>.\n"
>  "  -l, --logfile     set logfile path, logs to stderr by default\n"
>  "  -f, --pidfile     specify pidfile (default is %s)\n"
>  #ifdef CONFIG_FSFREEZE
> -- 
> 2.24.1
> 

Thanks to update it!
I updated the wiki page some months ago, adding an example, but I forgot to
check the most important man page and --help output.

Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>