diff --git a/devices/ioctrl/heathrow.cpp b/devices/ioctrl/heathrow.cpp index c77a1f9..9eb9439 100644 --- a/devices/ioctrl/heathrow.cpp +++ b/devices/ioctrl/heathrow.cpp @@ -96,6 +96,8 @@ HeathrowIC::HeathrowIC() : PCIDevice("mac-io/heathrow"), InterruptCtrl() // connect Ethernet HW this->bmac = dynamic_cast(gMachineObj->get_comp_by_type(HWCompType::ETHER_MAC)); + this->enet_xmit_dma = std::unique_ptr (new DMAChannel()); + this->enet_rcv_dma = std::unique_ptr (new DMAChannel()); // set EMMO pin status (active low) this->emmo_pin = GET_BIN_PROP("emmo") ^ 1; @@ -122,6 +124,10 @@ uint32_t HeathrowIC::dma_read(uint32_t offset, int size) { return this->scsi_dma->reg_read(offset & 0xFF, size); case MIO_OHARE_DMA_FLOPPY: return this->floppy_dma->reg_read(offset & 0xFF, size); + case MIO_OHARE_DMA_ETH_XMIT: + return this->enet_xmit_dma->reg_read(offset & 0xFF, size); + case MIO_OHARE_DMA_ETH_RCV: + return this->enet_rcv_dma->reg_read(offset & 0xFF, size); case MIO_OHARE_DMA_AUDIO_OUT: return this->snd_out_dma->reg_read(offset & 0xFF, size); default: @@ -139,6 +145,12 @@ void HeathrowIC::dma_write(uint32_t offset, uint32_t value, int size) { case MIO_OHARE_DMA_FLOPPY: this->floppy_dma->reg_write(offset & 0xFF, value, size); break; + case MIO_OHARE_DMA_ETH_XMIT: + this->enet_xmit_dma->reg_write(offset & 0xFF, value, size); + break; + case MIO_OHARE_DMA_ETH_RCV: + this->enet_rcv_dma->reg_write(offset & 0xFF, value, size); + break; case MIO_OHARE_DMA_AUDIO_OUT: this->snd_out_dma->reg_write(offset & 0xFF, value, size); break; diff --git a/devices/ioctrl/macio.h b/devices/ioctrl/macio.h index cd70f69..2b63ef9 100644 --- a/devices/ioctrl/macio.h +++ b/devices/ioctrl/macio.h @@ -299,8 +299,10 @@ private: // DMA channels std::unique_ptr scsi_dma; - std::unique_ptr snd_out_dma; std::unique_ptr floppy_dma; + std::unique_ptr enet_xmit_dma; + std::unique_ptr enet_rcv_dma; + std::unique_ptr snd_out_dma; }; #endif /* MACIO_H */