Skip to contentSkip to conversation

qapi/hmp: use 'backend' instead of 'device' with memory backend

PATCH In review Igor Mammedov 3 participants 4 messages Jun 19, 2014

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 qapi/hmp: use 'backend' instead of 'device' with memory backend

fixup documentation comments and HMP message/help text

---
v2:
- add "##" above "# @PCDIMMDeviceInfo:"

PS: based on PCI tree

---
 hmp.c            |  2 +-
 monitor.c        |  2 +-
 qapi-schema.json | 12 +++++++-----
 3 files changed, 9 insertions(+), 7 deletions(-)
hmp.c +1 -1
index 41006f5..e183a79 100644
@@ -1692,7 +1692,7 @@ void hmp_info_memdev(Monitor *mon, const QDict *qdict)
         ov = string_output_visitor_new(false);
         visit_type_uint16List(string_output_get_visitor(ov),
                               &m->value->host_nodes, NULL, NULL);
-        monitor_printf(mon, "memory device %d\n", i);
+        monitor_printf(mon, "memory backend: %d\n", i);
         monitor_printf(mon, "  size:  %" PRId64 "\n", m->value->size);
         monitor_printf(mon, "  merge: %s\n",
                        m->value->merge ? "true" : "false");
monitor.c +1 -1
index c7f8797..8c17f89 100644
@@ -2968,7 +2968,7 @@ static mon_cmd_t info_cmds[] = {
         .name       = "memdev",
         .args_type  = "",
         .params     = "",
-        .help       = "show the memory device",
+        .help       = "show memory backends",
         .mhandler.cmd = hmp_info_memdev,
     },
     {
qapi-schema.json +7 -5
index 9835004..f490403 100644
@@ -3158,19 +3158,19 @@
 ##
 # @Memdev:
 #
-# Information of memory device
+# Information about memory backend
 #
-# @size: memory device size
+# @size: memory backend size
 #
 # @merge: enables or disables memory merge support
 #
-# @dump: includes memory device's memory in a core dump or not
+# @dump: includes memory backend's memory in a core dump or not
 #
 # @prealloc: enables or disables memory preallocation
 #
 # @host-nodes: host nodes for its memory policy
 #
-# @policy: memory policy of memory device
+# @policy: memory policy of memory backend
 #
 # Since: 2.1
 ##
@@ -3187,13 +3187,15 @@
 ##
 # @query-memdev:
 #
-# Returns information for all memory devices.
+# Returns information for all memory backends.
 #
 # Returns: a list of @Memdev.
 #
 # Since: 2.1
 ##
 { 'command': 'query-memdev', 'returns': ['Memdev'] }
+
+##
 # @PCDIMMDeviceInfo:
 #
 # PCDIMMDevice state information
Signature · 1 line
1.9.3
#1 lore raw
Quoted 1 line · On Thu, 19 Jun 2014 16:14:43 +0200 Igor Mammedov <[email protected]> wrote:

fixup documentation comments and HMP message/help text

Doesn't apply anymore on top of my branch:

git://repo.or.cz/qemu/qmp-unstable.git queue/qmp

I might be able to include it in the next pull request if you rebase on time.

Quoted 85 lines

---
v2:
- add "##" above "# @PCDIMMDeviceInfo:"

PS: based on PCI tree

---
 hmp.c            |  2 +-
 monitor.c        |  2 +-
 qapi-schema.json | 12 +++++++-----
 3 files changed, 9 insertions(+), 7 deletions(-)
hmp.c +1 -1
index 41006f5..e183a79 100644
@@ -1692,7 +1692,7 @@ void hmp_info_memdev(Monitor *mon, const QDict *qdict)
         ov = string_output_visitor_new(false);
         visit_type_uint16List(string_output_get_visitor(ov),
                               &m->value->host_nodes, NULL, NULL);
-        monitor_printf(mon, "memory device %d\n", i);
+        monitor_printf(mon, "memory backend: %d\n", i);
         monitor_printf(mon, "  size:  %" PRId64 "\n", m->value->size);
         monitor_printf(mon, "  merge: %s\n",
                        m->value->merge ? "true" : "false");
monitor.c +1 -1
index c7f8797..8c17f89 100644
@@ -2968,7 +2968,7 @@ static mon_cmd_t info_cmds[] = {
         .name       = "memdev",
         .args_type  = "",
         .params     = "",
-        .help       = "show the memory device",
+        .help       = "show memory backends",
         .mhandler.cmd = hmp_info_memdev,
     },
     {
qapi-schema.json +7 -5
index 9835004..f490403 100644
@@ -3158,19 +3158,19 @@
 ##
 # @Memdev:
 #
-# Information of memory device
+# Information about memory backend
 #
-# @size: memory device size
+# @size: memory backend size
 #
 # @merge: enables or disables memory merge support
 #
-# @dump: includes memory device's memory in a core dump or not
+# @dump: includes memory backend's memory in a core dump or not
 #
 # @prealloc: enables or disables memory preallocation
 #
 # @host-nodes: host nodes for its memory policy
 #
-# @policy: memory policy of memory device
+# @policy: memory policy of memory backend
 #
 # Since: 2.1
 ##
@@ -3187,13 +3187,15 @@
 ##
 # @query-memdev:
 #
-# Returns information for all memory devices.
+# Returns information for all memory backends.
 #
 # Returns: a list of @Memdev.
 #
 # Since: 2.1
 ##
 { 'command': 'query-memdev', 'returns': ['Memdev'] }
+
+##
 # @PCDIMMDeviceInfo:
 #
 # PCDIMMDevice state information
#2 lore raw
Quoted 10 lines · Luiz Capitulino
Quoted 1 line · On Thu, 19 Jun 2014 16:14:43 +0200 Igor Mammedov <[email protected]> wrote:

fixup documentation comments and HMP message/help text

Doesn't apply anymore on top of my branch:

git://repo.or.cz/qemu/qmp-unstable.git queue/qmp

I might be able to include it in the next pull request if you rebase on time.

See below, it's for pci tree.

Quoted 85 lines
Quoted 85 lines

---
v2:
- add "##" above "# @PCDIMMDeviceInfo:"

PS: based on PCI tree

---
 hmp.c            |  2 +-
 monitor.c        |  2 +-
 qapi-schema.json | 12 +++++++-----
 3 files changed, 9 insertions(+), 7 deletions(-)
hmp.c +1 -1
index 41006f5..e183a79 100644
@@ -1692,7 +1692,7 @@ void hmp_info_memdev(Monitor *mon, const QDict *qdict)
         ov = string_output_visitor_new(false);
         visit_type_uint16List(string_output_get_visitor(ov),
                               &m->value->host_nodes, NULL, NULL);
-        monitor_printf(mon, "memory device %d\n", i);
+        monitor_printf(mon, "memory backend: %d\n", i);
         monitor_printf(mon, "  size:  %" PRId64 "\n", m->value->size);
         monitor_printf(mon, "  merge: %s\n",
                        m->value->merge ? "true" : "false");
monitor.c +1 -1
index c7f8797..8c17f89 100644
@@ -2968,7 +2968,7 @@ static mon_cmd_t info_cmds[] = {
         .name       = "memdev",
         .args_type  = "",
         .params     = "",
-        .help       = "show the memory device",
+        .help       = "show memory backends",
         .mhandler.cmd = hmp_info_memdev,
     },
     {
qapi-schema.json +7 -5
index 9835004..f490403 100644
@@ -3158,19 +3158,19 @@
 ##
 # @Memdev:
 #
-# Information of memory device
+# Information about memory backend
 #
-# @size: memory device size
+# @size: memory backend size
 #
 # @merge: enables or disables memory merge support
 #
-# @dump: includes memory device's memory in a core dump or not
+# @dump: includes memory backend's memory in a core dump or not
 #
 # @prealloc: enables or disables memory preallocation
 #
 # @host-nodes: host nodes for its memory policy
 #
-# @policy: memory policy of memory device
+# @policy: memory policy of memory backend
 #
 # Since: 2.1
 ##
@@ -3187,13 +3187,15 @@
 ##
 # @query-memdev:
 #
-# Returns information for all memory devices.
+# Returns information for all memory backends.
 #
 # Returns: a list of @Memdev.
 #
 # Since: 2.1
 ##
 { 'command': 'query-memdev', 'returns': ['Memdev'] }
+
+##
 # @PCDIMMDeviceInfo:
 #
 # PCDIMMDevice state information
#3 lore raw
Quoted 6 lines · On Thu, 19 Jun 2014 22:26:58 +0300 "Michael S. Tsirkin" <[email protected]> wrote:
Quoted 5 lines · Luiz Capitulino
Quoted 1 line · On Thu, 19 Jun 2014 16:14:43 +0200 Igor Mammedov <[email protected]> wrote:

fixup documentation comments and HMP message/help text

Quoted 7 lines
Quoted 5 lines

Doesn't apply anymore on top of my branch:

git://repo.or.cz/qemu/qmp-unstable.git queue/qmp

I might be able to include it in the next pull request if you rebase on time.

See below, it's for pci tree.

OK then.

Quoted 87 lines
Quoted 86 lines
Quoted 86 lines

---
v2:
- add "##" above "# @PCDIMMDeviceInfo:"

PS: based on PCI tree

---
 hmp.c            |  2 +-
 monitor.c        |  2 +-
 qapi-schema.json | 12 +++++++-----
 3 files changed, 9 insertions(+), 7 deletions(-)
hmp.c +1 -1
index 41006f5..e183a79 100644
@@ -1692,7 +1692,7 @@ void hmp_info_memdev(Monitor *mon, const QDict *qdict)
         ov = string_output_visitor_new(false);
         visit_type_uint16List(string_output_get_visitor(ov),
                               &m->value->host_nodes, NULL, NULL);
-        monitor_printf(mon, "memory device %d\n", i);
+        monitor_printf(mon, "memory backend: %d\n", i);
         monitor_printf(mon, "  size:  %" PRId64 "\n", m->value->size);
         monitor_printf(mon, "  merge: %s\n",
                        m->value->merge ? "true" : "false");
monitor.c +1 -1
index c7f8797..8c17f89 100644
@@ -2968,7 +2968,7 @@ static mon_cmd_t info_cmds[] = {
         .name       = "memdev",
         .args_type  = "",
         .params     = "",
-        .help       = "show the memory device",
+        .help       = "show memory backends",
         .mhandler.cmd = hmp_info_memdev,
     },
     {
qapi-schema.json +7 -5
index 9835004..f490403 100644
@@ -3158,19 +3158,19 @@
 ##
 # @Memdev:
 #
-# Information of memory device
+# Information about memory backend
 #
-# @size: memory device size
+# @size: memory backend size
 #
 # @merge: enables or disables memory merge support
 #
-# @dump: includes memory device's memory in a core dump or not
+# @dump: includes memory backend's memory in a core dump or not
 #
 # @prealloc: enables or disables memory preallocation
 #
 # @host-nodes: host nodes for its memory policy
 #
-# @policy: memory policy of memory device
+# @policy: memory policy of memory backend
 #
 # Since: 2.1
 ##
@@ -3187,13 +3187,15 @@
 ##
 # @query-memdev:
 #
-# Returns information for all memory devices.
+# Returns information for all memory backends.
 #
 # Returns: a list of @Memdev.
 #
 # Since: 2.1
 ##
 { 'command': 'query-memdev', 'returns': ['Memdev'] }
+
+##
 # @PCDIMMDeviceInfo:
 #
 # PCDIMMDevice state information