Blame 0040-virtiofsd-add-vhost-user.json-file.patch

1d442b
From: Stefan Hajnoczi <stefanha@redhat.com>
1d442b
Date: Mon, 27 Jan 2020 19:01:09 +0000
1d442b
Subject: [PATCH] virtiofsd: add vhost-user.json file
1d442b
MIME-Version: 1.0
1d442b
Content-Type: text/plain; charset=UTF-8
1d442b
Content-Transfer-Encoding: 8bit
1d442b
1d442b
Install a vhost-user.json file describing virtiofsd.  This allows
1d442b
libvirt and other management tools to enumerate vhost-user backend
1d442b
programs.
1d442b
1d442b
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
1d442b
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
1d442b
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
1d442b
(cherry picked from commit 315616ed50ba15a5d7236ade8a402a93898202de)
1d442b
---
1d442b
 .gitignore                                | 1 +
1d442b
 Makefile                                  | 1 +
1d442b
 tools/virtiofsd/50-qemu-virtiofsd.json.in | 5 +++++
1d442b
 3 files changed, 7 insertions(+)
1d442b
 create mode 100644 tools/virtiofsd/50-qemu-virtiofsd.json.in
1d442b
1d442b
diff --git a/.gitignore b/.gitignore
1d442b
index 7de868d1ea..c56ec1d122 100644
1d442b
--- a/.gitignore
1d442b
+++ b/.gitignore
1d442b
@@ -6,6 +6,7 @@
1d442b
 /config-target.*
1d442b
 /config.status
1d442b
 /config-temp
1d442b
+/tools/virtiofsd/50-qemu-virtiofsd.json
1d442b
 /elf2dmp
1d442b
 /trace-events-all
1d442b
 /trace/generated-events.h
1d442b
diff --git a/Makefile b/Makefile
1d442b
index 10fd31e705..aebb57aed8 100644
1d442b
--- a/Makefile
1d442b
+++ b/Makefile
1d442b
@@ -332,6 +332,7 @@ endif
1d442b
 
1d442b
 ifdef CONFIG_LINUX
1d442b
 HELPERS-y += virtiofsd$(EXESUF)
1d442b
+vhost-user-json-y += tools/virtiofsd/50-qemu-virtiofsd.json
1d442b
 endif
1d442b
 
1d442b
 # Sphinx does not allow building manuals into the same directory as
1d442b
diff --git a/tools/virtiofsd/50-qemu-virtiofsd.json.in b/tools/virtiofsd/50-qemu-virtiofsd.json.in
1d442b
new file mode 100644
1d442b
index 0000000000..9bcd86f8dc
1d442b
--- /dev/null
1d442b
+++ b/tools/virtiofsd/50-qemu-virtiofsd.json.in
1d442b
@@ -0,0 +1,5 @@
1d442b
+{
1d442b
+  "description": "QEMU virtiofsd vhost-user-fs",
1d442b
+  "type": "fs",
1d442b
+  "binary": "@libexecdir@/virtiofsd"
1d442b
+}