All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] Be consistent in -clock parameter
@ 2008-01-31 16:14 Hervé Poussineau
  0 siblings, 0 replies; only message in thread
From: Hervé Poussineau @ 2008-01-31 16:14 UTC (permalink / raw)
  To: qemu-devel

[-- Attachment #1: Type: text/plain, Size: 245 bytes --]

Hi,

-soundhw, -M, -cpu, -d, -translation options use the '?' to display the 
list of possibilities, whereas -clock uses 'help'. Change it to be 
consistent.
Display also the list of available sources if no valid clock name has 
been specified.

[-- Attachment #2: clock.diff --]
[-- Type: text/plain, Size: 1337 bytes --]

Index: vl.c
===================================================================
RCS file: /sources/qemu/qemu/vl.c,v
retrieving revision 1.401
diff -u -r1.401 vl.c
--- vl.c	23 Jan 2008 19:01:12 -0000	1.401
+++ vl.c	31 Jan 2008 16:11:12 -0000
@@ -917,7 +917,7 @@
     char *arg;
     char *name;
 
-    if (!strcmp(opt, "help")) {
+    if (!strcmp(opt, "?")) {
         show_available_alarms();
         exit(0);
     }
@@ -956,13 +956,13 @@
     free(arg);
 
     if (cur) {
-	/* Disable remaining timers */
+        /* Disable remaining timers */
         for (i = cur; i < count; i++)
             alarm_timers[i].name = NULL;
+    } else {
+        show_available_alarms();
+        exit(1);
     }
-
-    /* debug */
-    show_available_alarms();
 }
 
 QEMUClock *rt_clock;
@@ -7662,7 +7662,7 @@
            "-prom-env variable=value  set OpenBIOS nvram variables\n"
 #endif
            "-clock          force the use of the given methods for timer alarm.\n"
-           "                To see what timers are available use -clock help\n"
+           "                To see what timers are available use -clock ?\n"
            "-startdate      select initial date of the Qemu clock\n"
            "-translation setting1,... configures code translation\n"
            "                (use -translation ? for a list of settings)\n"

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2008-01-31 16:14 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-01-31 16:14 [Qemu-devel] [PATCH] Be consistent in -clock parameter Hervé Poussineau

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.