hw: do not flush core/kernel's page-tables

Fix genodelabs/genode#5380
This commit is contained in:
Stefan Kalkowski 2024-11-11 13:54:00 +01:00 committed by Christian Helmuth
parent 7dbc9129db
commit ed2d9fef47

View File

@ -60,6 +60,13 @@ bool Hw::Address_space::insert_translation(addr_t virt, addr_t phys,
_tt.insert_translation(virt, phys, size, flags, _tt_alloc);
return true;
} catch(Hw::Out_of_tables &) {
/* core/kernel's page-tables should never get flushed */
if (_tt_phys == Platform::core_page_table()) {
error("core's page-table allocator is empty!");
return false;
}
flush(platform().vm_start(), platform().vm_size());
}
}