qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 19/24] console: add and use qemu_display_find_de


From: Gerd Hoffmann
Subject: Re: [Qemu-devel] [PATCH 19/24] console: add and use qemu_display_find_default
Date: Fri, 17 Nov 2017 14:24:54 +0100
User-agent: NeoMutt/20171027

  Hi,

> > -        dpy.type = DISPLAY_TYPE_NONE;
> > +        if (!qemu_display_find_default(&dpy)) {
> > +            dpy.type = DISPLAY_TYPE_NONE;
> > +#if defined(CONFIG_VNC)
> > +            vnc_parse("localhost:0,to=99,id=default", &error_abort);
> > #endif
> 
> Mostly some questions on this:
> 
> - I'm curious, why is VNC not just one of the ones searched for in
>  qemu_display_find_default()?

vnc is a bit different.  It's a remote display protocol, not a (local)
user interface.  There is no DISPLAY_TYPE_VNC for that reason (without
this series too).  And IMO it was a bad idea to add -display vnc=$config
(same as -vnc $config) in the first place.

There can be only one user interface instance, i.e. you can't have gtk
and sdl at the same time.  With vnc (and spice) that works though, i.e.
you can start qemu with some local user interface and enable vnc or
spice (even both) remote access at the same time.

> - What if there is another display type added? Would it be added to
>  qemu_display_find_default() or in this if statement?

qemu_display_find_default() most likely,
but depends on what exactly it is.

> - Is there a reason that VNC doesn't follow the same registration
>  mechanism you're proposing here (as in you've no changes to that
>  module in this patch set).

See above ;)

> - In the spirit of encapsulation, would it not make sense for the
>  vnc_parse() to be in the VNC code itself as a fall back if no
>  specific options are given to the -vnc option?

It's not that simple.  The default vnc server is started only in case
no (graphical) local user interface is available, so it's not something
the vnc code can figure purely on its own.

cheers,
  Gerd




reply via email to

[Prev in Thread] Current Thread [Next in Thread]