guest agent: remove uneeded dependencies
[qemu/mdroth.git] / hw / isa.h
blobf1f21812d6e9943b1b0ad904022a4c00b1474522
1 #ifndef HW_ISA_H
2 #define HW_ISA_H
4 /* ISA bus */
6 #include "ioport.h"
7 #include "memory.h"
8 #include "qdev.h"
10 typedef struct ISABus ISABus;
11 typedef struct ISADevice ISADevice;
12 typedef struct ISADeviceInfo ISADeviceInfo;
14 struct ISADevice {
15 DeviceState qdev;
16 uint32_t isairq[2];
17 int nirqs;
18 uint16_t ioports[32];
19 int nioports;
22 typedef int (*isa_qdev_initfn)(ISADevice *dev);
23 struct ISADeviceInfo {
24 DeviceInfo qdev;
25 isa_qdev_initfn init;
28 ISABus *isa_bus_new(DeviceState *dev);
29 void isa_bus_irqs(qemu_irq *irqs);
30 qemu_irq isa_get_irq(int isairq);
31 void isa_init_irq(ISADevice *dev, qemu_irq *p, int isairq);
32 void isa_init_ioport(ISADevice *dev, uint16_t ioport);
33 void isa_init_ioport_range(ISADevice *dev, uint16_t start, uint16_t length);
34 void isa_qdev_register(ISADeviceInfo *info);
35 ISADevice *isa_create(const char *name);
36 ISADevice *isa_try_create(const char *name);
37 ISADevice *isa_create_simple(const char *name);
39 extern target_phys_addr_t isa_mem_base;
41 void isa_mmio_setup(MemoryRegion *mr, target_phys_addr_t size);
42 void isa_mmio_init(target_phys_addr_t base, target_phys_addr_t size);
44 /* dma.c */
45 int DMA_get_channel_mode (int nchan);
46 int DMA_read_memory (int nchan, void *buf, int pos, int size);
47 int DMA_write_memory (int nchan, void *buf, int pos, int size);
48 void DMA_hold_DREQ (int nchan);
49 void DMA_release_DREQ (int nchan);
50 void DMA_schedule(int nchan);
51 void DMA_init(int high_page_enable, qemu_irq *cpu_request_exit);
52 void DMA_register_channel (int nchan,
53 DMA_transfer_handler transfer_handler,
54 void *opaque);
55 #endif