* [Qemu-devel] [PULL 0/3] Fixes 31 20181116 patches
@ 2018-11-16 13:29 Gerd Hoffmann
2018-11-16 13:29 ` [Qemu-devel] [PULL 1/3] qapi: Add "rendernode" display option for egl-headless Gerd Hoffmann
` (3 more replies)
0 siblings, 4 replies; 7+ messages in thread
From: Gerd Hoffmann @ 2018-11-16 13:29 UTC (permalink / raw)
To: qemu-devel; +Cc: Eric Blake, Gerd Hoffmann, Markus Armbruster
The following changes since commit cb968d275c145467c8b385a3618a207ec111eab1:
Update version for v3.1.0-rc1 release (2018-11-13 18:16:14 +0000)
are available in the git repository at:
git://git.kraxel.org/qemu tags/fixes-31-20181116-pull-request
for you to fetch changes up to 144aaa990e0d54d08865c4d98ba2138a89689530:
help: Provide help for egl-headless (2018-11-16 11:44:22 +0100)
----------------------------------------------------------------
ui: add rendernode arg for egl-headless (fixes permission issues with libvirt)
----------------------------------------------------------------
Erik Skultety (3):
qapi: Add "rendernode" display option for egl-headless
ui: Allow specifying 'rendernode' display option for egl-headless
help: Provide help for egl-headless
ui/egl-headless.c | 2 +-
qapi/ui.json | 17 ++++++++++++++++-
qemu-options.hx | 6 +++++-
3 files changed, 22 insertions(+), 3 deletions(-)
--
2.9.3
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Qemu-devel] [PULL 1/3] qapi: Add "rendernode" display option for egl-headless
2018-11-16 13:29 [Qemu-devel] [PULL 0/3] Fixes 31 20181116 patches Gerd Hoffmann
@ 2018-11-16 13:29 ` Gerd Hoffmann
2018-11-19 13:10 ` Eric Blake
2018-11-16 13:29 ` [Qemu-devel] [PULL 2/3] ui: Allow specifying 'rendernode' " Gerd Hoffmann
` (2 subsequent siblings)
3 siblings, 1 reply; 7+ messages in thread
From: Gerd Hoffmann @ 2018-11-16 13:29 UTC (permalink / raw)
To: qemu-devel; +Cc: Eric Blake, Gerd Hoffmann, Markus Armbruster, Erik Skultety
From: Erik Skultety <eskultet@redhat.com>
Unlike SPICE, egl-headless doesn't offer a way of specifying the DRM
node used for OpenGL, hence QEMU always selecting the first one that is
available. Thus, add the 'rendernode' option for egl-headless to QAPI.
Signed-off-by: Erik Skultety <eskultet@redhat.com>
Message-id: 7658e15eca72d520e7a5fb1c2e724702d83d4f7f.1542362949.git.eskultet@redhat.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
qapi/ui.json | 17 ++++++++++++++++-
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a/qapi/ui.json b/qapi/ui.json
index bf9e157d5a..e0000248d3 100644
--- a/qapi/ui.json
+++ b/qapi/ui.json
@@ -1037,6 +1037,20 @@
'data' : { '*grab-on-hover' : 'bool',
'*zoom-to-fit' : 'bool' } }
+##
+# @DisplayEGLHeadless:
+#
+# EGL headless display options.
+#
+# @rendernode: Which DRM render node should be used. Default is the first
+# available node on the host.
+#
+# Since: 3.1
+#
+##
+{ 'struct' : 'DisplayEGLHeadless',
+ 'data' : { '*rendernode' : 'str' } }
+
##
# @DisplayGLMode:
#
@@ -1086,4 +1100,5 @@
'*window-close' : 'bool',
'*gl' : 'DisplayGLMode' },
'discriminator' : 'type',
- 'data' : { 'gtk' : 'DisplayGTK' } }
+ 'data' : { 'gtk' : 'DisplayGTK',
+ 'egl-headless' : 'DisplayEGLHeadless'} }
--
2.9.3
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [Qemu-devel] [PULL 2/3] ui: Allow specifying 'rendernode' display option for egl-headless
2018-11-16 13:29 [Qemu-devel] [PULL 0/3] Fixes 31 20181116 patches Gerd Hoffmann
2018-11-16 13:29 ` [Qemu-devel] [PULL 1/3] qapi: Add "rendernode" display option for egl-headless Gerd Hoffmann
@ 2018-11-16 13:29 ` Gerd Hoffmann
2018-11-16 13:29 ` [Qemu-devel] [PULL 3/3] help: Provide help " Gerd Hoffmann
2018-11-16 15:22 ` [Qemu-devel] [PULL 0/3] Fixes 31 20181116 patches Peter Maydell
3 siblings, 0 replies; 7+ messages in thread
From: Gerd Hoffmann @ 2018-11-16 13:29 UTC (permalink / raw)
To: qemu-devel; +Cc: Eric Blake, Gerd Hoffmann, Markus Armbruster, Erik Skultety
From: Erik Skultety <eskultet@redhat.com>
As libvirt can't predict which rendernode QEMU would pick, it
won't adjust the permissions on the device, hence QEMU getting
"Permission denied" when opening the DRI device. Therefore, enable
'rendernode' option for egl-headless display type.
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1648236
Signed-off-by: Erik Skultety <eskultet@redhat.com>
Message-id: 27f4617f19aa1072114f10f1aa9dd199735ef982.1542362949.git.eskultet@redhat.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
ui/egl-headless.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ui/egl-headless.c b/ui/egl-headless.c
index 42a41310b0..4cf3bbc0e4 100644
--- a/ui/egl-headless.c
+++ b/ui/egl-headless.c
@@ -176,7 +176,7 @@ static void egl_headless_init(DisplayState *ds, DisplayOptions *opts)
egl_dpy *edpy;
int idx;
- if (egl_rendernode_init(NULL, mode) < 0) {
+ if (egl_rendernode_init(opts->u.egl_headless.rendernode, mode) < 0) {
error_report("egl: render node init failed");
exit(1);
}
--
2.9.3
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [Qemu-devel] [PULL 3/3] help: Provide help for egl-headless
2018-11-16 13:29 [Qemu-devel] [PULL 0/3] Fixes 31 20181116 patches Gerd Hoffmann
2018-11-16 13:29 ` [Qemu-devel] [PULL 1/3] qapi: Add "rendernode" display option for egl-headless Gerd Hoffmann
2018-11-16 13:29 ` [Qemu-devel] [PULL 2/3] ui: Allow specifying 'rendernode' " Gerd Hoffmann
@ 2018-11-16 13:29 ` Gerd Hoffmann
2018-11-16 15:22 ` [Qemu-devel] [PULL 0/3] Fixes 31 20181116 patches Peter Maydell
3 siblings, 0 replies; 7+ messages in thread
From: Gerd Hoffmann @ 2018-11-16 13:29 UTC (permalink / raw)
To: qemu-devel; +Cc: Eric Blake, Gerd Hoffmann, Markus Armbruster, Erik Skultety
From: Erik Skultety <eskultet@redhat.com>
EGL headless has been missing from QEMU's help or man page, we should
mention that such a thing exists, especially since projects like libvirt
might rely on that. This patch also adds the newly introduced option for
egl-headless 'rendernode'.
Signed-off-by: Erik Skultety <eskultet@redhat.com>
Message-id: 87ef678b0934d3abba66c46c9e65b57119d29295.1542362949.git.eskultet@redhat.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
qemu-options.hx | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/qemu-options.hx b/qemu-options.hx
index ee379b32e3..f7df472f43 100644
--- a/qemu-options.hx
+++ b/qemu-options.hx
@@ -1216,7 +1216,8 @@ DEF("display", HAS_ARG, QEMU_OPTION_display,
"-display gtk[,grab_on_hover=on|off][,gl=on|off]|\n"
"-display vnc=<display>[,<optargs>]\n"
"-display curses\n"
- "-display none"
+ "-display none\n"
+ "-display egl-headless[,rendernode=<file>]"
" select display type\n"
"The default display is equivalent to\n"
#if defined(CONFIG_GTK)
@@ -1258,6 +1259,9 @@ menus and other UI elements to configure and control the VM during
runtime.
@item vnc
Start a VNC server on display <arg>
+@item egl-headless
+Offload all OpenGL operations to a local DRI device. For any graphical display,
+this display needs to be paired with either VNC or SPICE displays.
@end table
ETEXI
--
2.9.3
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] [PULL 0/3] Fixes 31 20181116 patches
2018-11-16 13:29 [Qemu-devel] [PULL 0/3] Fixes 31 20181116 patches Gerd Hoffmann
` (2 preceding siblings ...)
2018-11-16 13:29 ` [Qemu-devel] [PULL 3/3] help: Provide help " Gerd Hoffmann
@ 2018-11-16 15:22 ` Peter Maydell
3 siblings, 0 replies; 7+ messages in thread
From: Peter Maydell @ 2018-11-16 15:22 UTC (permalink / raw)
To: Gerd Hoffmann; +Cc: QEMU Developers, Markus Armbruster
On 16 November 2018 at 13:29, Gerd Hoffmann <kraxel@redhat.com> wrote:
> The following changes since commit cb968d275c145467c8b385a3618a207ec111eab1:
>
> Update version for v3.1.0-rc1 release (2018-11-13 18:16:14 +0000)
>
> are available in the git repository at:
>
> git://git.kraxel.org/qemu tags/fixes-31-20181116-pull-request
>
> for you to fetch changes up to 144aaa990e0d54d08865c4d98ba2138a89689530:
>
> help: Provide help for egl-headless (2018-11-16 11:44:22 +0100)
>
> ----------------------------------------------------------------
> ui: add rendernode arg for egl-headless (fixes permission issues with libvirt)
>
> ----------------------------------------------------------------
>
> Erik Skultety (3):
> qapi: Add "rendernode" display option for egl-headless
> ui: Allow specifying 'rendernode' display option for egl-headless
> help: Provide help for egl-headless
>
> ui/egl-headless.c | 2 +-
> qapi/ui.json | 17 ++++++++++++++++-
> qemu-options.hx | 6 +++++-
> 3 files changed, 22 insertions(+), 3 deletions(-)
Applied, thanks.
-- PMM
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] [PULL 1/3] qapi: Add "rendernode" display option for egl-headless
2018-11-16 13:29 ` [Qemu-devel] [PULL 1/3] qapi: Add "rendernode" display option for egl-headless Gerd Hoffmann
@ 2018-11-19 13:10 ` Eric Blake
2018-11-19 13:31 ` Erik Skultety
0 siblings, 1 reply; 7+ messages in thread
From: Eric Blake @ 2018-11-19 13:10 UTC (permalink / raw)
To: Gerd Hoffmann, qemu-devel; +Cc: Markus Armbruster, Erik Skultety
On 11/16/18 7:29 AM, Gerd Hoffmann wrote:
> From: Erik Skultety <eskultet@redhat.com>
>
> Unlike SPICE, egl-headless doesn't offer a way of specifying the DRM
> node used for OpenGL, hence QEMU always selecting the first one that is
> available. Thus, add the 'rendernode' option for egl-headless to QAPI.
>
> Signed-off-by: Erik Skultety <eskultet@redhat.com>
> Message-id: 7658e15eca72d520e7a5fb1c2e724702d83d4f7f.1542362949.git.eskultet@redhat.com
> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
> ---
> qapi/ui.json | 17 ++++++++++++++++-
> 1 file changed, 16 insertions(+), 1 deletion(-)
This has already landed, but I noticed via an off-list discussion that
it is not introspectible through query-qmp-schema, because
DisplayOptions is currently used only for command line handling. I don't
know off-hand whether query-command-line-options even exposes the
existence of DisplayOptions (not all of our command line options can be
queried), but even if it does, I also know that our current command line
queries are not detailed enough to readily expose the addition of a new
optional member. I think it would be appropriate for the 3.1 timeframe
to add a new QMP command that exposes the display configuration set up
at runtime, if only so that the DisplayOptions becomes visible through
query-qmp-commands as a bug fix for making this change easier to use.
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3266
Virtualization: qemu.org | libvirt.org
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] [PULL 1/3] qapi: Add "rendernode" display option for egl-headless
2018-11-19 13:10 ` Eric Blake
@ 2018-11-19 13:31 ` Erik Skultety
0 siblings, 0 replies; 7+ messages in thread
From: Erik Skultety @ 2018-11-19 13:31 UTC (permalink / raw)
To: Eric Blake; +Cc: Gerd Hoffmann, qemu-devel, Markus Armbruster
On Mon, Nov 19, 2018 at 07:10:21AM -0600, Eric Blake wrote:
> On 11/16/18 7:29 AM, Gerd Hoffmann wrote:
> > From: Erik Skultety <eskultet@redhat.com>
> >
> > Unlike SPICE, egl-headless doesn't offer a way of specifying the DRM
> > node used for OpenGL, hence QEMU always selecting the first one that is
> > available. Thus, add the 'rendernode' option for egl-headless to QAPI.
> >
> > Signed-off-by: Erik Skultety <eskultet@redhat.com>
> > Message-id: 7658e15eca72d520e7a5fb1c2e724702d83d4f7f.1542362949.git.eskultet@redhat.com
> > Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
> > ---
> > qapi/ui.json | 17 ++++++++++++++++-
> > 1 file changed, 16 insertions(+), 1 deletion(-)
>
> This has already landed, but I noticed via an off-list discussion that it is
> not introspectible through query-qmp-schema, because DisplayOptions is
> currently used only for command line handling. I don't know off-hand whether
> query-command-line-options even exposes the existence of DisplayOptions (not
It does not...
> all of our command line options can be queried), but even if it does, I also
> know that our current command line queries are not detailed enough to
> readily expose the addition of a new optional member. I think it would be
> appropriate for the 3.1 timeframe to add a new QMP command that exposes the
> display configuration set up at runtime, if only so that the DisplayOptions
> becomes visible through query-qmp-commands as a bug fix for making this
> change easier to use.
That would be awesome
Erik
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2018-11-19 13:31 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-11-16 13:29 [Qemu-devel] [PULL 0/3] Fixes 31 20181116 patches Gerd Hoffmann
2018-11-16 13:29 ` [Qemu-devel] [PULL 1/3] qapi: Add "rendernode" display option for egl-headless Gerd Hoffmann
2018-11-19 13:10 ` Eric Blake
2018-11-19 13:31 ` Erik Skultety
2018-11-16 13:29 ` [Qemu-devel] [PULL 2/3] ui: Allow specifying 'rendernode' " Gerd Hoffmann
2018-11-16 13:29 ` [Qemu-devel] [PULL 3/3] help: Provide help " Gerd Hoffmann
2018-11-16 15:22 ` [Qemu-devel] [PULL 0/3] Fixes 31 20181116 patches Peter Maydell
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.