)]}'
{
  "commit": "10a06fd65f667a972848ebbbcac11bdba931b544",
  "tree": "e1461fcc0b5fa83e67f91454f2a23c11c7dcf879",
  "parents": [
    "c900ef86c5e30e1adec0f79350edc3f30ebee285"
  ],
  "author": {
    "name": "Pavel Butsykin",
    "email": "pbutsykin@virtuozzo.com",
    "time": "Mon Oct 26 14:42:57 2015 +0300"
  },
  "committer": {
    "name": "Stefan Hajnoczi",
    "email": "stefanha@redhat.com",
    "time": "Thu Oct 29 17:59:27 2015 +0000"
  },
  "message": "virtio: sync the dataplane vring state to the virtqueue before virtio_save\n\nWhen creating snapshot with the dataplane enabled, the snapshot file gets\nnot the actual state of virtqueue, because the current state is stored in\nVirtIOBlockDataPlane. Therefore, before saving snapshot need to sync\nthe dataplane vring state to the virtqueue. The dataplane will resume its\nwork at the next notify virtqueue.\n\nWhen snapshot loads with loadvm we get a message:\nVQ 0 size 0x80 Guest index 0x15f5 inconsistent with Host index 0x0:\n    delta 0x15f5\nerror while loading state for instance 0x0 of device\n    \u00270000:00:08.0/virtio-blk\u0027\nError -1 while loading VM state\n\nto reproduce the error I used the following hmp commands:\nsavevm snap1\nloadvm snap1\n\nqemu parameters:\n--enable-kvm -smp 4 -m 1024 -drive file\u003d/var/lib/libvirt/images/centos6.4.qcow2,if\u003dnone,id\u003ddrive-virtio-disk0,format\u003dqcow2,cache\u003dnone,aio\u003dnative -device virtio-blk-pci,scsi\u003doff,bus\u003dpci.0,addr\u003d0x8,drive\u003ddrive-virtio-disk0,id\u003dvirtio-disk0 -set device.virtio-disk0.x-data-plane\u003don\n\nSigned-off-by: Pavel Butsykin \u003cpbutsykin@virtuozzo.com\u003e\nSigned-off-by: Denis V. Lunev \u003cden@openvz.org\u003e\nMessage-id: 1445859777-2982-1-git-send-email-den@openvz.org\nCC: Stefan Hajnoczi \u003cstefanha@redhat.com\u003e\nCC: \"Michael S. Tsirkin\" \u003cmst@redhat.com\u003e\nCC: Kevin Wolf \u003ckwolf@redhat.com\u003e\nCC: Paolo Bonzini \u003cpbonzini@redhat.com\u003e\nSigned-off-by: Stefan Hajnoczi \u003cstefanha@redhat.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "45a24e4fa61152866c663b2b099925ca789c3567",
      "old_mode": 33188,
      "old_path": "hw/block/virtio-blk.c",
      "new_id": "093e475dc9c976f86bf42027c60c60f3cb6d6bd1",
      "new_mode": 33188,
      "new_path": "hw/block/virtio-blk.c"
    },
    {
      "type": "modify",
      "old_id": "46553e1e683bf9bb21f3d905948f1b351231c3b7",
      "old_mode": 33188,
      "old_path": "hw/scsi/virtio-scsi.c",
      "new_id": "76554011cbffb4c940514d9d98b09255c81ff51d",
      "new_mode": 33188,
      "new_path": "hw/scsi/virtio-scsi.c"
    }
  ]
}
