qemu/include/hw/virtio
David Hildenbrand a8cd64d488 virtio-balloon: Use temporary PBP only
We still have multiple issues in the current code
- The PBP is not freed during unrealize()
- The PBP is not reset on device resets: After a reset, the PBP is stale.
- We are not indicating VIRTIO_BALLOON_F_MUST_TELL_HOST, therefore
  guests (esp. legacy guests) will reuse pages without deflating,
  turning the PBP stale. Adding that would require compat handling.

Instead, let's use the PBP only temporarily, when processing one bulk of
inflation requests. This will keep guest_page_size > 4k working (with
Linux guests). There is nothing to do for deflation requests anymore.
The pbp is only used for a limited amount of time.

Fixes: ed48c59875 ("virtio-balloon: Safely handle BALLOON_PAGE_SIZE < host page size")
Cc: qemu-stable@nongnu.org #v4.0.0
Suggested-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
Message-Id: <20190722134108.22151-7-david@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Acked-by: David Gibson <david@gibson.dropbear.id.au>
2019-07-25 07:58:03 -04:00
..
vhost-backend.h vhost-user: add vhost_user_gpu_set_socket() 2019-05-29 06:29:07 +02:00
vhost-scsi-common.h Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
vhost-scsi.h Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
vhost-user-blk.h Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
vhost-user-scsi.h Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
vhost-user.h vhost-user: simplify vhost_user_init/vhost_user_cleanup 2019-03-12 21:22:31 -04:00
vhost-vsock.h Clean up ill-advised or unusual header guards 2019-05-13 08:58:55 +02:00
vhost.h vhost-user: Support transferring inflight buffer between qemu and backend 2019-03-12 22:31:21 -04:00
virtio-access.h hw: Do not include "exec/address-spaces.h" if it is not necessary 2018-06-01 14:15:10 +02:00
virtio-balloon.h virtio-balloon: Use temporary PBP only 2019-07-25 07:58:03 -04:00
virtio-blk.h virtio-blk: add DISCARD and WRITE_ZEROES features 2019-02-22 09:42:17 +00:00
virtio-bus.h virtio: support setting memory region based host notifier 2018-05-23 17:01:54 +03:00
virtio-crypto.h Clean up ill-advised or unusual header guards 2019-05-13 08:58:55 +02:00
virtio-gpu-bswap.h virtio-gpu: add bswap helpers header 2019-05-29 06:29:07 +02:00
virtio-gpu-pci.h hw/display: add vhost-user-vga & gpu-pci 2019-05-29 06:30:45 +02:00
virtio-gpu-pixman.h virtio-gpu: add a pixman helper header 2019-05-29 06:29:07 +02:00
virtio-gpu.h edid: flip the default to enabled 2019-06-13 09:34:50 +02:00
virtio-input.h Add vhost-user-input-pci 2019-05-10 14:52:47 +02:00
virtio-net.h virtio-net: Switch to using announce timer 2019-03-05 11:27:41 +08:00
virtio-pmem.h virtio-pmem: add virtio device 2019-07-02 12:59:22 -04:00
virtio-rng.h virtio-rng: stop virtqueue while the CPU is stopped 2017-04-21 12:25:40 +02:00
virtio-scsi.h virtio-scsi: remove unused argument to virtio_scsi_common_realize 2019-07-19 19:04:38 +02:00
virtio-serial.h virtio-serial: add enable_backend callback 2017-09-21 11:51:49 +02:00
virtio.h virtio: Set "start_on_kick" for legacy devices 2019-07-04 17:00:32 -04:00