diff --git a/pcsx2/DEV9/net.cpp b/pcsx2/DEV9/net.cpp index 28d882f85d..089f9a9b6c 100644 --- a/pcsx2/DEV9/net.cpp +++ b/pcsx2/DEV9/net.cpp @@ -67,6 +67,12 @@ void tx_put(NetPacket* pkt) //pkt must be copied if its not processed by here, since it can be allocated on the callers stack } +void ad_reset() +{ + if (nif != nullptr) + nif->reset(); +} + NetAdapter* GetNetAdapter() { NetAdapter* na = nullptr; diff --git a/pcsx2/DEV9/net.h b/pcsx2/DEV9/net.h index 6f9a8becb5..711603b4ab 100644 --- a/pcsx2/DEV9/net.h +++ b/pcsx2/DEV9/net.h @@ -117,6 +117,7 @@ public: virtual bool isInitialised() = 0; virtual bool recv(NetPacket* pkt); //gets a packet virtual bool send(NetPacket* pkt); //sends the packet and deletes it when done + virtual void reset(){}; virtual void reloadSettings() = 0; virtual void close(){}; virtual ~NetAdapter(); @@ -145,6 +146,8 @@ private: }; void tx_put(NetPacket* ptr); +void ad_reset(); + void InitNet(); void ReconfigureLiveNet(const Pcsx2Config& old_config); void TermNet(); diff --git a/pcsx2/DEV9/smap.cpp b/pcsx2/DEV9/smap.cpp index 60e2e687e0..dbcc20f265 100644 --- a/pcsx2/DEV9/smap.cpp +++ b/pcsx2/DEV9/smap.cpp @@ -267,6 +267,7 @@ void emac3_write(u32 addr) if (value == 0x380f0000) { Console.WriteLn("DEV9: Adapter Detection Hack - Resetting RX/TX"); + ad_reset(); _DEV9irq(SMAP_INTR_RXEND | SMAP_INTR_TXEND | SMAP_INTR_TXDNV, 5); } break;