Hi,

+/* This struct represents a device that uses an IDE bus, but requires
+ * modifications to how it works. An example is AHCI. */
+struct IDEExtender {
+    TransferStartFunc *transfer_start_fn;
+    IRQSetFunc *irq_set_fn;
+    DMAStartFunc *dma_start_fn;
+};

Hmm, I'd call that IDEBusOps or simliar.

  struct IDEBus {
      BusState qbus;
      IDEDevice *master;
      IDEDevice *slave;
      BMDMAState *bmdma;
      IDEState ifs[2];
+    IDEExtender extender;
        IDEBusOps *ops;

Note this is a pointer now, so you can have static IDEBusOps structs and just set the ops pointer instead of filling in three function pointers.

cheers,
  Gerd

Reply via email to