4 #include <hw/ide/internal.h>
6 typedef struct BMDMAState {
13 /* current transfer state */
15 uint32_t cur_prd_last;
16 uint32_t cur_prd_addr;
19 BlockDriverCompletionFunc *dma_cb;
26 /* Bit 0-2 and 7: BM status register
27 * Bit 3-6: bus->error_status */
28 uint8_t migration_compat_status;
31 typedef struct PCIIDEState {
35 uint32_t secondary; /* used only for cmd646 */
39 static inline IDEState *bmdma_active_if(BMDMAState *bmdma)
41 assert(bmdma->unit != (uint8_t)-1);
42 return bmdma->bus->ifs + bmdma->unit;
46 void bmdma_init(IDEBus *bus, BMDMAState *bm);
47 void bmdma_cmd_writeb(void *opaque, uint32_t addr, uint32_t val);
48 extern const IORangeOps bmdma_addr_ioport_ops;
49 void pci_ide_create_devs(PCIDevice *dev, DriveInfo **hd_table);
51 extern const VMStateDescription vmstate_ide_pci;