[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-block] [RFC PATCH 12/56] pc-dimm: Make size and address unsigned i
From: |
Markus Armbruster |
Subject: |
[Qemu-block] [RFC PATCH 12/56] pc-dimm: Make size and address unsigned in QAPI/QMP |
Date: |
Mon, 7 Aug 2017 16:45:16 +0200 |
Sizes and addresses should use QAPI type 'size' (uint64_t).
PCDIMMDeviceInfo members @addr and @size are 'int' (int64_t).
qmp_pc_dimm_device_list() implicitly converts from uint64_t.
Change these PCDIMMDeviceInfo members to 'size'.
query-memory-devices now reports sizes and addresses above 2^63-1
correctly instead of their (negative) two's complement.
HMP's "info memory-devices" already reported them correctly, because
it printed the signed integers with PRIx64 and PRIu32.
Signed-off-by: Markus Armbruster <address@hidden>
---
qapi-schema.json | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/qapi-schema.json b/qapi-schema.json
index 23eb60d..6aa6be9 100644
--- a/qapi-schema.json
+++ b/qapi-schema.json
@@ -6057,8 +6057,8 @@
##
{ 'struct': 'PCDIMMDeviceInfo',
'data': { '*id': 'str',
- 'addr': 'int',
- 'size': 'int',
+ 'addr': 'size',
+ 'size': 'size',
'slot': 'int',
'node': 'int',
'memdev': 'str',
--
2.7.5
- Re: [Qemu-block] [Qemu-devel] [RFC PATCH 15/56] migration: Make XBZRLE cache size unsigned in QAPI/QMP, (continued)
- [Qemu-block] [RFC PATCH 08/56] dump: Make sizes and addresses unsigned in QAPI/QMP, Markus Armbruster, 2017/08/07
- [Qemu-block] [RFC PATCH 24/56] block/qcow2: Change align_offset() to operate on uint64_t, Markus Armbruster, 2017/08/07
- [Qemu-block] [RFC PATCH 10/56] hmp: Make balloon's argument unsigned, Markus Armbruster, 2017/08/07
- [Qemu-block] [RFC PATCH 23/56] option: Fix type of qemu_opt_set_number() parameter @val, Markus Armbruster, 2017/08/07
- [Qemu-block] [RFC PATCH 07/56] cpus: Make memsave, pmemsave sizes, addresses unsigned in QAPI/QMP, Markus Armbruster, 2017/08/07
- [Qemu-block] [RFC PATCH 12/56] pc-dimm: Make size and address unsigned in QAPI/QMP,
Markus Armbruster <=
[Qemu-block] [RFC PATCH 29/56] block: Make BlockDirtyInfo byte count unsigned in QAPI/QMP, Markus Armbruster, 2017/08/07
[Qemu-block] [RFC PATCH 35/56] blockjob: Lift speed sign conversion into block_job_set_speed(), Markus Armbruster, 2017/08/07
[Qemu-block] [RFC PATCH 37/56] blockjob: Make BlockJobInfo and event speed unsigned in QAPI/QMP, Markus Armbruster, 2017/08/07
[Qemu-block] [RFC PATCH 33/56] block: Make block_resize size unsigned in QAPI/QMP, Markus Armbruster, 2017/08/07