MCPcopy Create free account
hub / github.com/bendudson/EuraliOS / deallocate_frame

Method deallocate_frame

kernel/src/memory/frame_allocator.rs:281–288  ·  view source on GitHub ↗
(&mut self, frame: PhysFrame)

Source from the content-addressed store, hash-verified

279 }
280
281 pub fn deallocate_frame(&mut self, frame: PhysFrame) {
282 if frame.start_address() < self.frame_phys_addr {
283 // Not managed by this frame allocator
284 return;
285 }
286 let frame_number = (frame.start_address() - self.frame_phys_addr) / 4096;
287 self.return_frame(frame_number);
288 }
289
290 /// Allocate a consecutive set of frames
291 ///

Callers 2

free_pages_recFunction · 0.80
free_user_stackFunction · 0.80

Calls 1

return_frameMethod · 0.80

Tested by

no test coverage detected