linux-stable/drivers/virtio
Suman Anna c13f99b7e9 virtio: fix memory leak of virtio ida cache layers
The virtio core uses a static ida named virtio_index_ida for
assigning index numbers to virtio devices during registration.
The ida core may allocate some internal idr cache layers and
an ida bitmap upon any ida allocation, and all these layers are
truely freed only upon the ida destruction. The virtio_index_ida
is not destroyed at present, leading to a memory leak when using
the virtio core as a module and atleast one virtio device is
registered and unregistered.

Fix this by invoking ida_destroy() in the virtio core module
exit.

Cc: stable@vger.kernel.org
Signed-off-by: Suman Anna <s-anna@ti.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-12-07 17:28:01 +02:00
..
config.c Remove all #inclusions of asm/system.h 2012-03-28 18:30:03 +01:00
Kconfig Add virtio-input driver. 2015-03-29 12:13:52 +10:30
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 virtio_balloon: do not change memory amount visible via /proc/meminfo 2015-09-08 13:32:11 +03:00
virtio_input.c virtio-input: reset device and detach unused during remove 2015-08-06 10:40:35 +03:00
virtio_mmio.c virtio_mmio: add ACPI probing 2015-09-08 13:30:28 +03:00
virtio_pci_common.c virtio/vhost: cross endian support 2015-07-03 16:02:25 -07:00
virtio_pci_common.h virtio-pci: alloc only resources actually used. 2015-06-24 08:15:09 +02:00
virtio_pci_legacy.c virtio-pci: alloc only resources actually used. 2015-06-24 08:15:09 +02:00
virtio_pci_modern.c virtio-pci: alloc only resources actually used. 2015-06-24 08:15:09 +02:00
virtio_ring.c virtio: Avoid possible kernel panic if DEBUG is enabled. 2015-02-11 15:03:14 +10:30