From 7b5255083b7965b427052b5a0b911e51556139ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= Date: Sun, 12 Feb 2017 15:21:18 +0400 Subject: spice: allow to specify drm rendernode MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When multiple GPU are available, picking the first one isn't always the best choice. Learn to specify a device rendernode. Signed-off-by: Marc-André Lureau Message-id: 20170212112118.16044-1-marcandre.lureau@redhat.com Signed-off-by: Gerd Hoffmann --- ui/spice-core.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'ui/spice-core.c') diff --git a/ui/spice-core.c b/ui/spice-core.c index 1452e77fd1..39ccab7561 100644 --- a/ui/spice-core.c +++ b/ui/spice-core.c @@ -501,6 +501,9 @@ static QemuOptsList qemu_spice_opts = { },{ .name = "gl", .type = QEMU_OPT_BOOL, + },{ + .name = "rendernode", + .type = QEMU_OPT_STRING, #endif }, { /* end of list */ } @@ -833,7 +836,7 @@ void qemu_spice_init(void) "incompatible with -spice port/tls-port"); exit(1); } - if (egl_rendernode_init() != 0) { + if (egl_rendernode_init(qemu_opt_get(opts, "rendernode")) != 0) { error_report("Failed to initialize EGL render node for SPICE GL"); exit(1); } -- cgit v1.2.1