linux/drivers/virtio
Michael S. Tsirkin 1fe9b6fef1 virtio: fix oops on OOM
virtio ring was changed to return an error code on OOM,
but one caller was missed and still checks for vq->vring.num.
The fix is just to check for <0 error code.

Long term it might make sense to change goto add_head to
just return an error on oom instead, but let's apply
a minimal fix for 2.6.35.

Reported-by: Chris Mason <chris.mason@oracle.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Tested-by: Chris Mason <chris.mason@oracle.com>
Cc: stable@kernel.org # .34.x
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-07-26 08:05:31 -07:00
..
config.c
Kconfig
Makefile
virtio_balloon.c
virtio_pci.c virtio-pci: disable msi at startup 2010-06-23 22:49:07 +09:30
virtio_ring.c virtio: fix oops on OOM 2010-07-26 08:05:31 -07:00
virtio.c