diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/virtio.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/linux/virtio.h b/include/linux/virtio.h index 49a640e0a6f4..79e3c74391e0 100644 --- a/include/linux/virtio.h +++ b/include/linux/virtio.h @@ -9,6 +9,7 @@ #include <linux/device.h> #include <linux/mod_devicetable.h> #include <linux/gfp.h> +#include <linux/dma-mapping.h> /** * struct virtqueue - a queue to register buffers for sending or receiving. @@ -212,4 +213,11 @@ void unregister_virtio_driver(struct virtio_driver *drv); #define module_virtio_driver(__virtio_driver) \ module_driver(__virtio_driver, register_virtio_driver, \ unregister_virtio_driver) + +dma_addr_t virtqueue_dma_map_single_attrs(struct virtqueue *_vq, void *ptr, size_t size, + enum dma_data_direction dir, unsigned long attrs); +void virtqueue_dma_unmap_single_attrs(struct virtqueue *_vq, dma_addr_t addr, + size_t size, enum dma_data_direction dir, + unsigned long attrs); +int virtqueue_dma_mapping_error(struct virtqueue *_vq, dma_addr_t addr); #endif /* _LINUX_VIRTIO_H */ |