mirror of
https://github.com/asterinas/asterinas.git
synced 2025-06-29 14:43:23 +00:00
Fix unnecessary page table activation
This commit is contained in:
committed by
Tate, Hongliang Tian
parent
8dce83605f
commit
b5f8e4e7bb
@ -128,12 +128,12 @@ where
|
|||||||
|
|
||||||
let last_activated_paddr = current_page_table_paddr();
|
let last_activated_paddr = current_page_table_paddr();
|
||||||
|
|
||||||
activate_page_table(self.raw, CachePolicy::Writeback);
|
|
||||||
|
|
||||||
if last_activated_paddr == self.raw {
|
if last_activated_paddr == self.raw {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
activate_page_table(self.raw, CachePolicy::Writeback);
|
||||||
|
|
||||||
// Increment the reference count of the current page table.
|
// Increment the reference count of the current page table.
|
||||||
self.inc_ref_count();
|
self.inc_ref_count();
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user