virtio: Add improved queue allocation API
authorAndy Lutomirski <luto@kernel.org>
Wed, 3 Feb 2016 05:46:37 +0000 (21:46 -0800)
committerMichael S. Tsirkin <mst@redhat.com>
Wed, 2 Mar 2016 15:01:57 +0000 (17:01 +0200)
commit2a2d1382fe9dccfce6f9c60a9c9fd2f0fe5bcf2b
treeab3783be11369f689e3e7aebe0c438ab6746375f
parent780bc7903a32edb63be138487fd981694d993610
virtio: Add improved queue allocation API

This leaves vring_new_virtqueue alone for compatbility, but it
adds two new improved APIs:

vring_create_virtqueue: Creates a virtqueue backed by automatically
allocated coherent memory.  (Some day it this could be extended to
support non-coherent memory, too, if there ends up being a platform
on which it's worthwhile.)

__vring_new_virtqueue: Creates a virtqueue with a manually-specified
layout.  This should allow mic_virtio to work much more cleanly.

Signed-off-by: Andy Lutomirski <luto@kernel.org>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
drivers/virtio/virtio_ring.c
include/linux/virtio.h
include/linux/virtio_ring.h