summary refs log tree commit diff stats
path: root/hw/core
diff options
context:
space:
mode:
authorDavid Hildenbrand <david@redhat.com>2021-05-10 13:43:28 +0200
committerPaolo Bonzini <pbonzini@redhat.com>2021-06-15 20:27:38 +0200
commitbaa014e3b92a12a6037c7525ee1a169ab7ec0302 (patch)
tree8d73b53aee5284a17ef2b95198d1b1824cd5ec89 /hw/core
parent69647f9d51795ebea09eef05b5b2d14ffb835baf (diff)
downloadfocaccia-qemu-baa014e3b92a12a6037c7525ee1a169ab7ec0302.tar.gz
focaccia-qemu-baa014e3b92a12a6037c7525ee1a169ab7ec0302.zip
hmp: Print "reserve" property of memory backends with "info memdev"
Let's print the new property.

Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>
Reviewed-by: Markus Armbruster <armbru@redhat.com>
Acked-by: Eduardo Habkost <ehabkost@redhat.com> for memory backend and machine core
Cc: Markus Armbruster <armbru@redhat.com>
Cc: Eric Blake <eblake@redhat.com>
Cc: Igor Mammedov <imammedo@redhat.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
Message-Id: <20210510114328.21835-16-david@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'hw/core')
-rw-r--r--hw/core/machine-hmp-cmds.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/hw/core/machine-hmp-cmds.c b/hw/core/machine-hmp-cmds.c
index 004a92b3d6..76b22b00d6 100644
--- a/hw/core/machine-hmp-cmds.c
+++ b/hw/core/machine-hmp-cmds.c
@@ -112,6 +112,10 @@ void hmp_info_memdev(Monitor *mon, const QDict *qdict)
                        m->value->prealloc ? "true" : "false");
         monitor_printf(mon, "  share: %s\n",
                        m->value->share ? "true" : "false");
+        if (m->value->has_reserve) {
+            monitor_printf(mon, "  reserve: %s\n",
+                           m->value->reserve ? "true" : "false");
+        }
         monitor_printf(mon, "  policy: %s\n",
                        HostMemPolicy_str(m->value->policy));
         visit_complete(v, &str);