core: arm: Implement InvalidateCacheRange for CPU cache invalidation.

This commit is contained in:
bunnei 2020-11-13 23:20:32 -08:00
parent c0870315fd
commit 63fd1bb503
12 changed files with 56 additions and 16 deletions

View file

@ -497,12 +497,17 @@ const Core::ExclusiveMonitor& KernelCore::GetExclusiveMonitor() const {
}
void KernelCore::InvalidateAllInstructionCaches() {
if (!IsMulticore()) {
for (auto& physical_core : impl->cores) {
physical_core.ArmInterface().ClearInstructionCache();
for (auto& physical_core : impl->cores) {
physical_core.ArmInterface().ClearInstructionCache();
}
}
void KernelCore::InvalidateCpuInstructionCacheRange(VAddr addr, std::size_t size) {
for (auto& physical_core : impl->cores) {
if (!physical_core.IsInitialized()) {
continue;
}
} else {
UNIMPLEMENTED();
physical_core.ArmInterface().InvalidateCacheRange(addr, size);
}
}