diff --git a/repos/base-hw/src/core/include/spec/arm/pl310.h b/repos/base-hw/src/core/include/spec/arm/pl310.h index f69079905..806e6ba0e 100644 --- a/repos/base-hw/src/core/include/spec/arm/pl310.h +++ b/repos/base-hw/src/core/include/spec/arm/pl310.h @@ -53,6 +53,12 @@ struct Arm::Pl310 : Genode::Mmio struct Invalidate_by_way : Register <0x77c, 32> { }; struct Clean_invalidate_by_way : Register <0x7fc, 32> { }; + struct Debug : Register<0xf40, 32> + { + struct Dcl : Bitfield<0,1> { }; + struct Dwb : Bitfield<1,1> { }; + }; + Pl310(Genode::addr_t const base) : Mmio(base) { } inline void sync() { while (read()) ; } diff --git a/repos/base-hw/src/core/include/spec/panda/board.h b/repos/base-hw/src/core/include/spec/panda/board.h index e00d44de5..fc9778bd8 100644 --- a/repos/base-hw/src/core/include/spec/panda/board.h +++ b/repos/base-hw/src/core/include/spec/panda/board.h @@ -77,9 +77,12 @@ class Genode::L2_cache void flush() { - _secure_monitor.call(Secure_monitor::L2_CACHE_SET_DEBUG_REG, 0x3); + Arm::Pl310::Debug::access_t v = 0; + Arm::Pl310::Debug::Dwb::set(v, 1); + Arm::Pl310::Debug::Dcl::set(v, 1); + _secure_monitor.call(Secure_monitor::L2_CACHE_SET_DEBUG_REG, v); _pl310.flush(); - _secure_monitor.call(Secure_monitor::L2_CACHE_SET_DEBUG_REG, 0x0); + _secure_monitor.call(Secure_monitor::L2_CACHE_SET_DEBUG_REG, 0); } void invalidate() { _pl310.invalidate(); }