PPC: e500: msync is 440 only, e500 has real sync
[qemu.git] / hw / etraxfs_dma.h
1 struct dma_context_metadata {
2 /* data descriptor md */
3 uint16_t metadata;
4 };
5
6 struct etraxfs_dma_client
7 {
8 /* DMA controller. */
9 int channel;
10 void *ctrl;
11
12 /* client. */
13 struct {
14 int (*push)(void *opaque, unsigned char *buf,
15 int len, bool eop);
16 void (*pull)(void *opaque);
17 void (*metadata_push)(void *opaque,
18 const struct dma_context_metadata *md);
19 void *opaque;
20 } client;
21 };
22
23 void *etraxfs_dmac_init(target_phys_addr_t base, int nr_channels);
24 void etraxfs_dmac_connect(void *opaque, int channel, qemu_irq *line,
25 int input);
26 void etraxfs_dmac_connect_client(void *opaque, int c,
27 struct etraxfs_dma_client *cl);
28 int etraxfs_dmac_input(struct etraxfs_dma_client *client,
29 void *buf, int len, int eop);