Add a few comments to vm subsystem
This commit is contained in:
parent
22edefc349
commit
a1ea05dc41
@ -142,7 +142,7 @@ impl ProcessVM {
|
||||
self.get_stack_vma().get_end()
|
||||
}
|
||||
|
||||
// TODO: override the mmaping of already mmaped range
|
||||
// TODO: support overriding the mmaping of already mmaped range
|
||||
pub fn mmap(&mut self, addr: usize, size: usize, flags: VMAreaFlags)
|
||||
-> Result<usize, Error>
|
||||
{
|
||||
@ -211,6 +211,7 @@ impl ProcessVM {
|
||||
return Ok(new_brk);
|
||||
}
|
||||
|
||||
// TODO: init the memory with zeros for the expanded area
|
||||
let resize_options = {
|
||||
let brk_start = self.get_brk_start();
|
||||
let new_heap_size = align_up(new_brk, 4096) - brk_start;
|
||||
|
@ -21,6 +21,7 @@ impl VMDomain {
|
||||
pub fn resize_area(&mut self, area: &mut VMArea, options: &VMResizeOptions)
|
||||
-> Result<(), Error>
|
||||
{
|
||||
// TODO: init memory with zeros when expanding!
|
||||
self.range.resize_subrange(&mut area.range, options)
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user