diff options
Diffstat (limited to 'hw/virtio.h')
-rw-r--r-- | hw/virtio.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/hw/virtio.h b/hw/virtio.h index f04e75f887..8c9cbaf63e 100644 --- a/hw/virtio.h +++ b/hw/virtio.h @@ -48,6 +48,12 @@ struct VirtQueue; +static inline target_phys_addr_t vring_align(target_phys_addr_t addr, + unsigned long align) +{ + return (addr + align - 1) & ~(align - 1); +} + typedef struct VirtQueue VirtQueue; typedef struct VirtIODevice VirtIODevice; |