diff options
Diffstat (limited to 'xenolinux-2.4.16-sparse/include/asm-xeno/hypervisor-ifs/block.h')
-rw-r--r-- | xenolinux-2.4.16-sparse/include/asm-xeno/hypervisor-ifs/block.h | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/xenolinux-2.4.16-sparse/include/asm-xeno/hypervisor-ifs/block.h b/xenolinux-2.4.16-sparse/include/asm-xeno/hypervisor-ifs/block.h new file mode 100644 index 0000000000..55f7a33ce2 --- /dev/null +++ b/xenolinux-2.4.16-sparse/include/asm-xeno/hypervisor-ifs/block.h @@ -0,0 +1,40 @@ +/****************************************************************************** + * block.h + * + * Block IO communication rings. + * + * These are the ring data structures for buffering messages between + * the hypervisor and guestos's. + * + * For now we'll start with our own rings for the block IO code instead + * of using the network rings. Hopefully, this will give us additional + * flexibility in the future should we choose to move away from a + * ring producer consumer communication model. + */ + +#ifndef __BLOCK_H__ +#define __BLOCK_H__ + +typedef struct blk_tx_entry_st { + unsigned long addr; /* virtual address */ + unsigned long size; /* in bytes */ +} blk_tx_entry_t; + +typedef struct blk_rx_entry_st { + unsigned long addr; /* virtual address */ + unsigned long size; /* in bytes */ +} blk_rx_entry_t; + +typedef struct blk_ring_st { + blk_tx_entry_t *tx_ring; + unsigned int tx_prod, tx_cons, tx_event; + unsigned int tx_ring_size; + + blk_rx_entry_t *rx_ring; + unsigned int rx_prod, rx_cons, rx_event; + unsigned int rx_ring_size; +} blk_ring_t; + +int blk_create_ring(int domain, unsigned long ptr); + +#endif |