> > + if (s->stats_vq_elem == NULL) { > > + virtqueue_push(s->svq, &elem, 0); > > + virtio_notify(vdev, s->svq); > > + return; > > + } > > virtqueue_push(s->svq, s->stats_vq_elem, s->stats_vq_offset); > > virtio_notify(vdev, s->svq); > > g_free(s->stats_vq_elem); > > > > Hi, the right fix is to migrate s->stats_vq_elem if it is not NULL. See how > it's > done in hw/char/virtio-serial.c's virtio_serial_save_device > (save) and fetch_active_ports_list (load). > > Paolo
Thanks for your information, it's very helpful. I will send the v2. Liang