Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 197852
b: refs/heads/master
c: 316f25f
h: refs/heads/master
v: v3
  • Loading branch information
Michael S. Tsirkin authored and Rusty Russell committed May 19, 2010
1 parent 8c5b5af commit 69ed3eb
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: bdb4a1305723f985249210a803105dbc48e86b64
refs/heads/master: 316f25f5b3d547ce892d370f99f08a27276896ff
34 changes: 34 additions & 0 deletions trunk/include/linux/virtio.h
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,40 @@ struct virtqueue_ops {
void *(*detach_unused_buf)(struct virtqueue *vq);
};

static inline int virtqueue_add_buf(struct virtqueue *vq,
struct scatterlist sg[],
unsigned int out_num,
unsigned int in_num,
void *data)
{
return vq->vq_ops->add_buf(vq, sg, out_num, in_num, data);
}

static inline int void virtqueue_kick(struct virtqueue *vq)
{
return vq->vq_ops->kick(vq);
}

static inline void *virtqueue_get_buf(struct virtqueue *vq, unsigned int *len)
{
return vq->vq_ops->get_buf(vq, len);
}

static inline void virtqueue_disable_cb(struct virtqueue *vq)
{
vq->vq_ops->disable_cb(vq);
}

static inline bool virtqueue_enable_cb(struct virtqueue *vq)
{
return vq->vq_ops->enable_cb(vq);
}

static inline void *virtqueue_detach_unused_buf(struct virtqueue *vq)
{
return vq->vq_ops->detach_unused_buf(vq);
}

/**
* virtio_device - representation of a device using virtio
* @index: unique position on the virtio bus
Expand Down

0 comments on commit 69ed3eb

Please sign in to comment.