grml...
[seabios.git] / src / virtio-pci.h
index 6932036ab148b01c10a2640b33abdf36968400c3..e1d972dc53275bddfd4966c0295ed91682f9ac06 100644 (file)
@@ -1,6 +1,8 @@
 #ifndef _VIRTIO_PCI_H
 #define _VIRTIO_PCI_H
 
+#include "ioport.h" // inl
+
 /* A 32-bit r/o bitmask of the features supported by the host */
 #define VIRTIO_PCI_HOST_FEATURES        0
 
@@ -69,6 +71,10 @@ static inline void vp_set_status(unsigned int ioaddr, u8 status)
    outb(status, ioaddr + VIRTIO_PCI_STATUS);
 }
 
+static inline u8 vp_get_isr(unsigned int ioaddr)
+{
+   return inb(ioaddr + VIRTIO_PCI_ISR);
+}
 
 static inline void vp_reset(unsigned int ioaddr)
 {
@@ -92,6 +98,8 @@ static inline void vp_del_vq(unsigned int ioaddr, int queue_index)
    outl(0, ioaddr + VIRTIO_PCI_QUEUE_PFN);
 }
 
+struct vring_virtqueue;
+u16 vp_init_simple(u16 bdf);
 int vp_find_vq(unsigned int ioaddr, int queue_index,
-               struct vring_virtqueue *vq);
+               struct vring_virtqueue **p_vq);
 #endif /* _VIRTIO_PCI_H_ */