[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 11/11] test-vmstate: add test case to verify we
From: |
Stefan Hajnoczi |
Subject: |
Re: [Qemu-devel] [PATCH 11/11] test-vmstate: add test case to verify we don't change VMState |
Date: |
Wed, 23 Mar 2011 08:37:40 +0000 |
On Wed, Mar 23, 2011 at 12:16 AM, Anthony Liguori <address@hidden> wrote:
> +static QObject *read_current_schema(void)
> +{
> + char buffer[65536];
> + int fd;
> + int ret;
> + size_t offset = 0;
> + ssize_t len;
> +
> + ret = system("i386-softmmu/qemu -vmstate-dump > /tmp/schema.json");
Please don't hardcode i386-softmmu, there should at least be a way to
override it. For example, I tend to build x86_64-softmmu only.
Using a temporary file is not ideal because as soon as this program
runs as part of an automated build system we could be clobbering the
file if multiple runs are going in parallel. How about popen(3)?
> diff --git a/vmstate/schema.json b/vmstate/schema.json
> new file mode 100644
> index 0000000..23483ab
> --- /dev/null
> +++ b/vmstate/schema.json
> @@ -0,0 +1,1176 @@
> +{
> + "cpu": {
> + "mcg_cap": "uint64",
> + "a20_mask": "int32",
> + "tsc_offset": "uint64",
> + "idt": {
> + "flags": "uint32",
> + "limit": "uint32",
> + "selector": "uint32",
> + "base": "uint32",
> + "__version__": 1
> + },
Is field ordering important and did we lose that information as soon
as we started using dicts to represent vmstate dumps?
Stefan
- [Qemu-devel] Re: [PATCH 07/11] eeprom93xx: Use the new hack macro to avoid duplicate field names, (continued)
- [Qemu-devel] [PATCH 02/11] vmstate: register all VMStateDescriptions, Anthony Liguori, 2011/03/22
- [Qemu-devel] [PATCH 05/11] vga-isa: fix migration by breaking it, Anthony Liguori, 2011/03/22
- [Qemu-devel] [PATCH 09/11] pckbd: make non-ISA pckbd use a unique name, Anthony Liguori, 2011/03/22
- [Qemu-devel] [PATCH 11/11] test-vmstate: add test case to verify we don't change VMState, Anthony Liguori, 2011/03/22
- Re: [Qemu-devel] [PATCH 11/11] test-vmstate: add test case to verify we don't change VMState, Anthony Liguori, 2011/03/22
- Re: [Qemu-devel] [PATCH 11/11] test-vmstate: add test case to verify we don't change VMState,
Stefan Hajnoczi <=
- Re: [Qemu-devel] [PATCH 11/11] test-vmstate: add test case to verify we don't change VMState, Peter Maydell, 2011/03/23
- Re: [Qemu-devel] [PATCH 11/11] test-vmstate: add test case to verify we don't change VMState, Anthony Liguori, 2011/03/23
- [Qemu-devel] Re: [PATCH 11/11] test-vmstate: add test case to verify we don't change VMState, Juan Quintela, 2011/03/23
- Re: [Qemu-devel] Re: [PATCH 11/11] test-vmstate: add test case to verify we don't change VMState, Anthony Liguori, 2011/03/23
- Re: [Qemu-devel] Re: [PATCH 11/11] test-vmstate: add test case to verify we don't change VMState, Peter Maydell, 2011/03/23
- Re: [Qemu-devel] Re: [PATCH 11/11] test-vmstate: add test case to verify we don't change VMState, Jan Kiszka, 2011/03/23
- Re: [Qemu-devel] Re: [PATCH 11/11] test-vmstate: add test case to verify we don't change VMState, Anthony Liguori, 2011/03/23
- Re: [Qemu-devel] Re: [PATCH 11/11] test-vmstate: add test case to verify we don't change VMState, Jan Kiszka, 2011/03/23
- Re: [Qemu-devel] Re: [PATCH 11/11] test-vmstate: add test case to verify we don't change VMState, Anthony Liguori, 2011/03/23
- Re: [Qemu-devel] Re: [PATCH 11/11] test-vmstate: add test case to verify we don't change VMState, Peter Maydell, 2011/03/23