linux-stable/drivers/virtio
Konstantin Neumoin 37cf99e08c balloon: check the number of available pages in leak balloon
The balloon has a special mechanism that is subscribed to the oom
notification which leads to deflation for a fixed number of pages.
The number is always fixed even when the balloon is fully deflated.
But leak_balloon did not expect that the pages to deflate will be more
than taken, and raise a "BUG" in balloon_page_dequeue when page list
will be empty.

So, the simplest solution would be to check that the number of releases
pages is less or equal to the number taken pages.

Cc: stable@vger.kernel.org
Signed-off-by: Konstantin Neumoin <kneumoin@virtuozzo.com>
Signed-off-by: Denis V. Lunev <den@openvz.org>
CC: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2016-08-01 21:44:51 +03:00
..
config.c Remove all #inclusions of asm/system.h 2012-03-28 18:30:03 +01:00
Kconfig virtio_ring: Support DMA APIs 2016-03-02 17:01:57 +02:00
Makefile Add virtio-input driver. 2015-03-29 12:13:52 +10:30
virtio.c virtio: fix memory leak of virtio ida cache layers 2015-12-07 17:28:01 +02:00
virtio_balloon.c balloon: check the number of available pages in leak balloon 2016-08-01 21:44:51 +03:00
virtio_input.c virtio: make find_vqs() checkpatch.pl-friendly 2016-01-12 20:47:06 +02:00
virtio_mmio.c virtio_mmio: Use the DMA API if enabled 2016-03-02 17:01:58 +02:00
virtio_pci_common.c PCI changes for the v4.6 merge window: 2016-03-16 14:45:55 -07:00
virtio_pci_common.h virtio_pci: Use the DMA API if enabled 2016-03-02 17:01:58 +02:00
virtio_pci_legacy.c virtio_pci: Use the DMA API if enabled 2016-03-02 17:01:58 +02:00
virtio_pci_modern.c virtio: virtio 1.0 cs04 spec compliance for reset 2016-04-07 15:16:39 +03:00
virtio_ring.c virtio: Silence uninitialized variable warning 2016-05-01 15:50:08 +03:00