diff options
Diffstat (limited to 'include/linux/virtio_ring.h')
| -rw-r--r-- | include/linux/virtio_ring.h | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/include/linux/virtio_ring.h b/include/linux/virtio_ring.h index 693e0ec5afa6..e4d144b132b5 100644 --- a/include/linux/virtio_ring.h +++ b/include/linux/virtio_ring.h | |||
| @@ -30,8 +30,7 @@ | |||
| 30 | #define VIRTIO_RING_F_INDIRECT_DESC 28 | 30 | #define VIRTIO_RING_F_INDIRECT_DESC 28 |
| 31 | 31 | ||
| 32 | /* Virtio ring descriptors: 16 bytes. These can chain together via "next". */ | 32 | /* Virtio ring descriptors: 16 bytes. These can chain together via "next". */ |
| 33 | struct vring_desc | 33 | struct vring_desc { |
| 34 | { | ||
| 35 | /* Address (guest-physical). */ | 34 | /* Address (guest-physical). */ |
| 36 | __u64 addr; | 35 | __u64 addr; |
| 37 | /* Length. */ | 36 | /* Length. */ |
| @@ -42,24 +41,21 @@ struct vring_desc | |||
| 42 | __u16 next; | 41 | __u16 next; |
| 43 | }; | 42 | }; |
| 44 | 43 | ||
| 45 | struct vring_avail | 44 | struct vring_avail { |
| 46 | { | ||
| 47 | __u16 flags; | 45 | __u16 flags; |
| 48 | __u16 idx; | 46 | __u16 idx; |
| 49 | __u16 ring[]; | 47 | __u16 ring[]; |
| 50 | }; | 48 | }; |
| 51 | 49 | ||
| 52 | /* u32 is used here for ids for padding reasons. */ | 50 | /* u32 is used here for ids for padding reasons. */ |
| 53 | struct vring_used_elem | 51 | struct vring_used_elem { |
| 54 | { | ||
| 55 | /* Index of start of used descriptor chain. */ | 52 | /* Index of start of used descriptor chain. */ |
| 56 | __u32 id; | 53 | __u32 id; |
| 57 | /* Total length of the descriptor chain which was used (written to) */ | 54 | /* Total length of the descriptor chain which was used (written to) */ |
| 58 | __u32 len; | 55 | __u32 len; |
| 59 | }; | 56 | }; |
| 60 | 57 | ||
| 61 | struct vring_used | 58 | struct vring_used { |
| 62 | { | ||
| 63 | __u16 flags; | 59 | __u16 flags; |
| 64 | __u16 idx; | 60 | __u16 idx; |
| 65 | struct vring_used_elem ring[]; | 61 | struct vring_used_elem ring[]; |
