From 8b4796a367ec21d294f7318343e5bb9d7e07a53e Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Tue, 26 Feb 2008 23:38:51 -0500 Subject: TLB: Make a TLB base class and put a virtual demapPage function in it. --HG-- extra : convert_revision : cc0e62a5a337fd5bf332ad33bed61c0d505a936f --- src/sim/tlb.hh | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) (limited to 'src/sim/tlb.hh') diff --git a/src/sim/tlb.hh b/src/sim/tlb.hh index b5e341185..011cc1144 100644 --- a/src/sim/tlb.hh +++ b/src/sim/tlb.hh @@ -39,13 +39,25 @@ class ThreadContext; class Packet; -class GenericTLB : public SimObject +class BaseTLB : public SimObject { protected: - GenericTLB(const Params *p) : SimObject(p) + BaseTLB(const Params *p) : SimObject(p) {} public: + virtual void demapPage(Addr vaddr, uint64_t asn) = 0; +}; + +class GenericTLB : public BaseTLB +{ + protected: + GenericTLB(const Params *p) : BaseTLB(p) + {} + + public: + void demapPage(Addr vaddr, uint64_t asn); + Fault translate(RequestPtr req, ThreadContext *tc, bool=false); }; -- cgit v1.2.3