Special treat VM Space clearing

This commit is contained in:
Zhang Junyang
2024-11-03 15:34:30 +08:00
committed by Tate, Hongliang Tian
parent fda05e9e23
commit c34706603a
4 changed files with 71 additions and 13 deletions

View File

@ -339,8 +339,7 @@ impl Vmar_ {
}
fn clear_vm_space(&self) {
let mut cursor = self.vm_space.cursor_mut(&(0..ROOT_VMAR_CAP_ADDR)).unwrap();
cursor.unmap(ROOT_VMAR_CAP_ADDR);
self.vm_space.clear().unwrap();
}
pub fn destroy(&self, range: Range<usize>) -> Result<()> {