summary refs log tree commit diff stats
path: root/ui/console.c
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2020-01-14 16:00:31 +0000
committerPeter Maydell <peter.maydell@linaro.org>2020-01-14 16:00:31 +0000
commit3a63b24a1bbf166e6f455fe43a6bbd8dea413d92 (patch)
treef6def5fbe955648e9d632a2a266fc80c02b12893 /ui/console.c
parentfee0ec1fd11a6fb960517e18201ed8a686a0d7e8 (diff)
parentc4c00922cc948bb5e879bfae60764eba1f8745f3 (diff)
downloadfocaccia-qemu-3a63b24a1bbf166e6f455fe43a6bbd8dea413d92.tar.gz
focaccia-qemu-3a63b24a1bbf166e6f455fe43a6bbd8dea413d92.zip
Merge remote-tracking branch 'remotes/kraxel/tags/ui-20200114-pull-request' into staging
ui: add "-display help", gtk refresh rate.

# gpg: Signature made Tue 14 Jan 2020 10:01:14 GMT
# gpg:                using RSA key 4CB6D8EED3E87138
# gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>" [full]
# gpg:                 aka "Gerd Hoffmann <gerd@kraxel.org>" [full]
# gpg:                 aka "Gerd Hoffmann (private) <kraxel@gmail.com>" [full]
# Primary key fingerprint: A032 8CFF B93A 17A7 9901  FE7D 4CB6 D8EE D3E8 7138

* remotes/kraxel/tags/ui-20200114-pull-request:
  display/gtk: get proper refreshrate
  ui: Print available display backends with '-display help'

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'ui/console.c')
-rw-r--r--ui/console.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/ui/console.c b/ui/console.c
index ac79d679f5..69339b028b 100644
--- a/ui/console.c
+++ b/ui/console.c
@@ -2333,6 +2333,21 @@ void qemu_display_init(DisplayState *ds, DisplayOptions *opts)
     dpys[opts->type]->init(ds, opts);
 }
 
+void qemu_display_help(void)
+{
+    int idx;
+
+    printf("Available display backend types:\n");
+    for (idx = DISPLAY_TYPE_NONE; idx < DISPLAY_TYPE__MAX; idx++) {
+        if (!dpys[idx]) {
+            ui_module_load_one(DisplayType_str(idx));
+        }
+        if (dpys[idx]) {
+            printf("%s\n",  DisplayType_str(dpys[idx]->type));
+        }
+    }
+}
+
 void qemu_chr_parse_vc(QemuOpts *opts, ChardevBackend *backend, Error **errp)
 {
     int val;