yeahuh / rpms / qemu-kvm

Forked from rpms/qemu-kvm 2 years ago
Clone
22c213
From 2754dd8da8975757753fd491985d5e7b36966106 Mon Sep 17 00:00:00 2001
22c213
From: Eduardo Habkost <ehabkost@redhat.com>
22c213
Date: Wed, 4 Dec 2013 18:53:17 +0100
22c213
Subject: Add support statement to -help output
22c213
22c213
RH-Author: Eduardo Habkost <ehabkost@redhat.com>
22c213
Message-id: <1386183197-27761-1-git-send-email-ehabkost@redhat.com>
22c213
Patchwork-id: 55994
22c213
O-Subject: [qemu-kvm RHEL7 PATCH] Add support statement to -help output
22c213
Bugzilla: 972773
22c213
RH-Acked-by: Miroslav Rezanina <mrezanin@redhat.com>
22c213
RH-Acked-by: knoel@redhat.com
22c213
RH-Acked-by: Paolo Bonzini <pbonzini@redhat.com>
22c213
22c213
Add support statement to -help output, reporting direct qemu-kvm usage
22c213
as unsupported by Red Hat, and advising users to use libvirt instead.
22c213
22c213
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
22c213
(cherry picked from commit 2a07700936e39856cc9f149c6a6517f0715536a6)
22c213
(cherry picked from commit 5dd2f4706e2fef945771949e59a8fcc1b5452de9)
22c213
Signed-off-by: Danilo C. L. de Paula <ddepaula@redhat.com>
22c213
---
22c213
 vl.c | 9 +++++++++
22c213
 1 file changed, 9 insertions(+)
22c213
22c213
diff --git a/vl.c b/vl.c
22c213
index 668a34577e..9f3e7e7733 100644
22c213
--- a/vl.c
22c213
+++ b/vl.c
22c213
@@ -1822,9 +1822,17 @@ static void version(void)
22c213
            QEMU_COPYRIGHT "\n");
22c213
 }
22c213
 
22c213
+static void print_rh_warning(void)
22c213
+{
22c213
+    printf("\nWARNING: Direct use of qemu-kvm from the command line is not supported by Red Hat.\n"
22c213
+             "WARNING: Use libvirt as the stable management interface.\n"
22c213
+             "WARNING: Some command line options listed here may not be available in future releases.\n\n");
22c213
+}
22c213
+
22c213
 static void help(int exitcode)
22c213
 {
22c213
     version();
22c213
+    print_rh_warning();
22c213
     printf("usage: %s [options] [disk_image]\n\n"
22c213
            "'disk_image' is a raw hard disk image for IDE hard disk 0\n\n",
22c213
             error_get_progname());
22c213
@@ -1841,6 +1849,7 @@ static void help(int exitcode)
22c213
            "\n"
22c213
            QEMU_HELP_BOTTOM "\n");
22c213
 
22c213
+    print_rh_warning();
22c213
     exit(exitcode);
22c213
 }
22c213
 
22c213
-- 
22c213
2.21.0
22c213