Skip to content

Commit

Permalink
softmmu/vl: Fence 'xenfb' if Xen support is not compiled in
Browse files Browse the repository at this point in the history
The 'xenfb' parameter for the '-vga' command line option is currently
always enabled unconditionally (since the xenfb is not a proper QOM
device that could be tested via its class name). That means it also
shows up if Xen is not enabled at all, e.g. like this:

 $ ./qemu-system-sparc -vga help
 none                 no graphic card
 xenfb                Xen paravirtualized framebuffer
 tcx                  TCX framebuffer (default)
 cg3                  CG3 framebuffer

Let's avoid this situation by fencing the parameter with the
CONFIG_XEN_BACKEND switch.

Message-Id: <20220427123316.329312-1-thuth@redhat.com>
Acked-by: Anthony PERARD <anthony.perard@citrix.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
  • Loading branch information
huth committed May 6, 2022
1 parent 64d1379 commit 4dd89bd
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions softmmu/vl.c
Expand Up @@ -934,10 +934,12 @@ static const VGAInterfaceInfo vga_interfaces[VGA_TYPE_MAX] = {
.name = "CG3 framebuffer",
.class_names = { "cgthree" },
},
#ifdef CONFIG_XEN_BACKEND
[VGA_XENFB] = {
.opt_name = "xenfb",
.name = "Xen paravirtualized framebuffer",
},
#endif
};

static bool vga_interface_available(VGAInterfaceType t)
Expand Down

0 comments on commit 4dd89bd

Please sign in to comment.