diff options
author | Alexander Graf <agraf@suse.de> | 2012-01-20 14:41:12 +0100 |
---|---|---|
committer | Alexander Graf <agraf@suse.de> | 2012-02-02 02:47:42 +0100 |
commit | 1529ae1bc61a15e9a243dcbad70c95dfcdd1f0c5 (patch) | |
tree | 92e4d946da35ff705a79e6271905209b24e90065 /linux-headers/linux/virtio_ring.h | |
parent | d34e8f6e9d3a396c3327aa9807c83f9e1f4a7bd7 (diff) |
KVM: Update headers (except HIOR mess)
This patch is basically what ./scripts/update-linux-headers.sh against
upstream KVM's next branch outputs except that all the HIOR bits are
removed. These we have to update with the code that uses them.
Signed-off-by: Alexander Graf <agraf@suse.de>
Diffstat (limited to 'linux-headers/linux/virtio_ring.h')
-rw-r--r-- | linux-headers/linux/virtio_ring.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/linux-headers/linux/virtio_ring.h b/linux-headers/linux/virtio_ring.h index 78289eedf2..1b333e2536 100644 --- a/linux-headers/linux/virtio_ring.h +++ b/linux-headers/linux/virtio_ring.h @@ -135,13 +135,13 @@ static __inline__ void vring_init(struct vring *vr, unsigned int num, void *p, vr->num = num; vr->desc = p; vr->avail = p + num*sizeof(struct vring_desc); - vr->used = (void *)(((unsigned long)&vr->avail->ring[num] + align-1) - & ~(align - 1)); + vr->used = (void *)(((unsigned long)&vr->avail->ring[num] + sizeof(__u16) + + align-1) & ~(align - 1)); } static __inline__ unsigned vring_size(unsigned int num, unsigned long align) { - return ((sizeof(struct vring_desc) * num + sizeof(__u16) * (2 + num) + return ((sizeof(struct vring_desc) * num + sizeof(__u16) * (3 + num) + align - 1) & ~(align - 1)) + sizeof(__u16) * 3 + sizeof(struct vring_used_elem) * num; } |