Skip to contentSkip to conversation

machine: Drop use of DEFAULT_RAM_SIZE in help text

PATCH Applied Alexander Graf 4 participants 4 messages Jun 5, 2015 – Jun 8, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 machine: Drop use of DEFAULT_RAM_SIZE in help text

As of commit 076b35b5a (machine: add default_ram_size to machine class) we no longer have a global default ram size, but instead machine specific defaults. When invoking qemu --help we don't know which machine you selected, so we can't tell the user the default RAM size in the help text anymore now.

Thus I don't see an easy way to expose the default ram size to the user in the help text. The easiest option IMHO is to just drop this piece of information.

---
 qemu-options.hx | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
qemu-options.hx +1 -2
index b3db6cb..5eaba11 100644
@@ -241,8 +241,7 @@ ETEXI
 DEF("m", HAS_ARG, QEMU_OPTION_m,
     "-m[emory] [size=]megs[,slots=n,maxmem=size]\n"
     "                configure guest RAM\n"
-    "                size: initial amount of guest memory (default: "
-    stringify(DEFAULT_RAM_SIZE) "MiB)\n"
+    "                size: initial amount of guest memory\n"
     "                slots: number of hotplug slots (default: none)\n"
     "                maxmem: maximum amount of guest memory (default: none)\n"
     "NOTE: Some architectures might enforce a specific granularity\n",
Signature · 1 line
1.8.1.4
Acked-by on v1 1/1
#1 lore raw
Quoted 7 lines · Alexander Graf

As of commit 076b35b5a (machine: add default_ram_size to machine class) we no longer have a global default ram size, but instead machine specific defaults. When invoking qemu --help we don't know which machine you selected, so we can't tell the user the default RAM size in the help text anymore now.

Thus I don't see an easy way to expose the default ram size to the user in the help text. The easiest option IMHO is to just drop this piece of information.

It's unfortunate, but I agree.

Thanks,

Laurent

Quoted 23 lines
---
 qemu-options.hx | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
qemu-options.hx +1 -3
index b3db6cb..5eaba11 100644
@@ -241,8 +241,7 @@ ETEXI
 DEF("m", HAS_ARG, QEMU_OPTION_m,
     "-m[emory] [size=]megs[,slots=n,maxmem=size]\n"
     "                configure guest RAM\n"
-    "                size: initial amount of guest memory (default: "
-    stringify(DEFAULT_RAM_SIZE) "MiB)\n"
+    "                size: initial amount of guest memory\n"
     "                slots: number of hotplug slots (default: none)\n"
     "                maxmem: maximum amount of guest memory (default: none)\n"
     "NOTE: Some architectures might enforce a specific granularity\n",
--

1.8.1.4

Acked-by on v1 1/1
#2 lore raw
In reply to Alexander Graf
Quoted 7 lines · Alexander Graf

As of commit 076b35b5a (machine: add default_ram_size to machine class) we no longer have a global default ram size, but instead machine specific defaults. When invoking qemu --help we don't know which machine you selected, so we can't tell the user the default RAM size in the help text anymore now.

Thus I don't see an easy way to expose the default ram size to the user in the help text. The easiest option IMHO is to just drop this piece of information.

Quoted 23 lines
---
 qemu-options.hx | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
qemu-options.hx +1 -2
index b3db6cb..5eaba11 100644
@@ -241,8 +241,7 @@ ETEXI
 DEF("m", HAS_ARG, QEMU_OPTION_m,
     "-m[emory] [size=]megs[,slots=n,maxmem=size]\n"
     "                configure guest RAM\n"
-    "                size: initial amount of guest memory (default: "
-    stringify(DEFAULT_RAM_SIZE) "MiB)\n"
+    "                size: initial amount of guest memory\n"
     "                slots: number of hotplug slots (default: none)\n"
     "                maxmem: maximum amount of guest memory (default: none)\n"
     "NOTE: Some architectures might enforce a specific granularity\n",
Signature · 1 line
1.8.1.4
#3 lore raw
In reply to Alexander Graf
Quoted 19 lines · Alexander Graf

As of commit 076b35b5a (machine: add default_ram_size to machine class) we no longer have a global default ram size, but instead machine specific defaults. When invoking qemu --help we don't know which machine you selected, so we can't tell the user the default RAM size in the help text anymore now.

Thus I don't see an easy way to expose the default ram size to the user in the help text. The easiest option IMHO is to just drop this piece of information.

---
 qemu-options.hx | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
qemu-options.hx +0 -0
index b3db6cb..5eaba11 100644

qemu-options.hx ETEXI · line 247

Quoted 9 lines
qemu-options.hx +1 -2
@@ -241,8 +241,7 @@ ETEXI
 DEF("m", HAS_ARG, QEMU_OPTION_m,
     "-m[emory] [size=]megs[,slots=n,maxmem=size]\n"
     "                configure guest RAM\n"
-    "                size: initial amount of guest memory (default: "
-    stringify(DEFAULT_RAM_SIZE) "MiB)\n"
+    "                size: initial amount of guest memory\n"
     "                slots: number of hotplug slots (default: none)\n"
     "                maxmem: maximum amount of guest memory (default: none)\n"
     "NOTE: Some architectures might enforce a specific granularity\n",

Applied to master as a fix.

thanks
-- PMM