]> git.baikalelectronics.ru Git - kernel.git/commit
virtio: console: Ensure no memleaks in case of unused buffers
authorAmit Shah <amit.shah@redhat.com>
Fri, 12 Feb 2010 05:02:15 +0000 (10:32 +0530)
committerRusty Russell <rusty@rustcorp.com.au>
Wed, 24 Feb 2010 03:53:03 +0000 (14:23 +1030)
commitbd6a9a02b81274e917d3d73219947e90c34aa972
tree37ce268d3aceb90145d6d42d29b1f77a5bc1005f
parent1ec80f35f54f9b4af0a362a24915a28b4509f00e
virtio: console: Ensure no memleaks in case of unused buffers

If unused data exists in in_vq, ensure we flush that first and then
detach unused buffers, which will ensure all buffers from the in_vq are
removed.

Also ensure we free the buffers after detaching them.

Signed-off-by: Amit Shah <amit.shah@redhat.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
drivers/char/virtio_console.c