From dd3abb296f9df75aa2eabda1d417c613ecc320f6 Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Mon, 28 Oct 2019 19:27:21 -0700 Subject: [PATCH] dev: Remove SINIC_VTOPHYS and related code. The code in this #ifdef isn't turned on by anything, and either has or likely will bitrot, especially since there are no tests to even determine manually if the code they guard works. They are also preceeded by panics which say that the code they guard is known not to work now anyway. This change also gets rid of TheISA in that file since the only reason it was around was for vtophys in the guarded code. Change-Id: I59fd8974d0dd3d7ab0d5a8ccfa6a446d2da41eb0 Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/22265 Reviewed-by: Jason Lowe-Power Maintainer: Jason Lowe-Power Tested-by: kokoro --- src/dev/net/sinic.cc | 24 ------------------------ 1 file changed, 24 deletions(-) diff --git a/src/dev/net/sinic.cc b/src/dev/net/sinic.cc index c6260078c..f422cf319 100644 --- a/src/dev/net/sinic.cc +++ b/src/dev/net/sinic.cc @@ -34,15 +34,10 @@ #include #include -#ifdef SINIC_VTOPHYS -#include "arch/vtophys.hh" - -#endif #include "base/compiler.hh" #include "base/debug.hh" #include "base/inet.hh" #include "base/types.hh" -#include "config/the_isa.hh" #include "debug/EthernetAll.hh" #include "dev/net/etherlink.hh" #include "mem/packet.hh" @@ -52,7 +47,6 @@ using namespace std; using namespace Net; -using namespace TheISA; namespace Sinic { @@ -365,15 +359,6 @@ Device::write(PacketPtr pkt) if (Regs::get_RxData_Vaddr(pkt->getLE())) { panic("vtophys not implemented in newmem"); -#ifdef SINIC_VTOPHYS - Addr vaddr = Regs::get_RxData_Addr(reg64); - Addr paddr = vtophys(req->xc, vaddr); - DPRINTF(EthernetPIO, "write RxData vnic %d (rxunique %d): " - "vaddr=%#x, paddr=%#x\n", - index, vnic.rxUnique, vaddr, paddr); - - vnic.RxData = Regs::set_RxData_Addr(vnic.RxData, paddr); -#endif } else { DPRINTF(EthernetPIO, "write RxData vnic %d (rxunique %d)\n", index, vnic.rxUnique); @@ -403,15 +388,6 @@ Device::write(PacketPtr pkt) if (Regs::get_TxData_Vaddr(pkt->getLE())) { panic("vtophys won't work here in newmem.\n"); -#ifdef SINIC_VTOPHYS - Addr vaddr = Regs::get_TxData_Addr(reg64); - Addr paddr = vtophys(req->xc, vaddr); - DPRINTF(EthernetPIO, "write TxData vnic %d (txunique %d): " - "vaddr=%#x, paddr=%#x\n", - index, vnic.txUnique, vaddr, paddr); - - vnic.TxData = Regs::set_TxData_Addr(vnic.TxData, paddr); -#endif } else { DPRINTF(EthernetPIO, "write TxData vnic %d (txunique %d)\n", index, vnic.txUnique); -- 2.30.2