]> git.proxmox.com Git - pve-qemu-kvm.git/blob - debian/patches/virtio-balloon-drop-old-stats-code.patch
Two more fixes
[pve-qemu-kvm.git] / debian / patches / virtio-balloon-drop-old-stats-code.patch
1 From: Luiz Capitulino <lcapitulino@redhat.com>
2 Subject: [Qemu-devel] [PATCH 1/3] virtio-balloon: drop old stats code
3
4 Next commit will re-enable balloon stats with a different interface, but
5 this old code conflicts with it. Drop it.
6
7 Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
8 ---
9 hw/virtio-balloon.c | 22 ----------------------
10 1 file changed, 22 deletions(-)
11
12 diff --git a/hw/virtio-balloon.c b/hw/virtio-balloon.c
13 index dd1a650..4398025 100644
14 --- a/hw/virtio-balloon.c
15 +++ b/hw/virtio-balloon.c
16 @@ -164,28 +164,6 @@ static uint32_t virtio_balloon_get_features(VirtIODevice *vdev, uint32_t f)
17 static void virtio_balloon_stat(void *opaque, BalloonInfo *info)
18 {
19 VirtIOBalloon *dev = opaque;
20 -
21 -#if 0
22 - /* Disable guest-provided stats for now. For more details please check:
23 - * https://bugzilla.redhat.com/show_bug.cgi?id=623903
24 - *
25 - * If you do enable it (which is probably not going to happen as we
26 - * need a new command for it), remember that you also need to fill the
27 - * appropriate members of the BalloonInfo structure so that the stats
28 - * are returned to the client.
29 - */
30 - if (dev->vdev.guest_features & (1 << VIRTIO_BALLOON_F_STATS_VQ)) {
31 - virtqueue_push(dev->svq, &dev->stats_vq_elem, dev->stats_vq_offset);
32 - virtio_notify(&dev->vdev, dev->svq);
33 - return;
34 - }
35 -#endif
36 -
37 - /* Stats are not supported. Clear out any stale values that might
38 - * have been set by a more featureful guest kernel.
39 - */
40 - reset_stats(dev);
41 -
42 info->actual = ram_size - ((uint64_t) dev->actual <<
43 VIRTIO_BALLOON_PFN_SHIFT);
44 }
45 --
46 1.8.0
47
48
49
50