From d8966467ca4ecb25f46d7095e762c3486a6aab81 Mon Sep 17 00:00:00 2001 From: Gerd Hoffmann Date: Thu, 25 Jun 2015 16:14:21 +0200 Subject: virtio: find version 1.0 virtio capabilities virtio 1.0 specifies the location of the various virtio regions using pci capabilities. Look them up and store the results. Signed-off-by: Gerd Hoffmann --- src/hw/virtio-pci.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/hw/virtio-pci.h') diff --git a/src/hw/virtio-pci.h b/src/hw/virtio-pci.h index 42e2b7f7..467c02fb 100644 --- a/src/hw/virtio-pci.h +++ b/src/hw/virtio-pci.h @@ -115,8 +115,16 @@ typedef struct virtio_pci_isr { /* --- driver structs ----------------------------------------------- */ +struct vp_cap { + u32 addr; + u8 cap; + u8 bar; + u8 is_io; +}; + struct vp_device { unsigned int ioaddr; + struct vp_cap common, notify, isr, device; }; static inline u32 vp_get_features(struct vp_device *vp) -- cgit