1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 02:17:34 +00:00

Kernel: Convert klog() to dmesgln() in Region

This commit is contained in:
Andreas Kling 2021-03-09 21:30:35 +01:00
parent 4d30166d61
commit aef6474ea7

View file

@ -495,14 +495,14 @@ PageFaultResponse Region::handle_zero_fault(size_t page_index_in_region)
} else { } else {
page_slot = MM.allocate_user_physical_page(MemoryManager::ShouldZeroFill::Yes); page_slot = MM.allocate_user_physical_page(MemoryManager::ShouldZeroFill::Yes);
if (page_slot.is_null()) { if (page_slot.is_null()) {
klog() << "MM: handle_zero_fault was unable to allocate a physical page"; dmesgln("MM: handle_zero_fault was unable to allocate a physical page");
return PageFaultResponse::OutOfMemory; return PageFaultResponse::OutOfMemory;
} }
dbgln_if(PAGE_FAULT_DEBUG, " >> ALLOCATED {}", page_slot->paddr()); dbgln_if(PAGE_FAULT_DEBUG, " >> ALLOCATED {}", page_slot->paddr());
} }
if (!remap_vmobject_page(page_index_in_vmobject)) { if (!remap_vmobject_page(page_index_in_vmobject)) {
klog() << "MM: handle_zero_fault was unable to allocate a page table to map " << page_slot; dmesgln("MM: handle_zero_fault was unable to allocate a page table to map {}", page_slot);
return PageFaultResponse::OutOfMemory; return PageFaultResponse::OutOfMemory;
} }
return PageFaultResponse::Continue; return PageFaultResponse::Continue;
@ -566,7 +566,7 @@ PageFaultResponse Region::handle_inode_fault(size_t page_index_in_region, Scoped
mm_lock.lock(); mm_lock.lock();
if (nread < 0) { if (nread < 0) {
klog() << "MM: handle_inode_fault had error (" << nread << ") while reading!"; dmesgln("MM: handle_inode_fault had error ({}) while reading!", nread);
return PageFaultResponse::ShouldCrash; return PageFaultResponse::ShouldCrash;
} }
if (nread < PAGE_SIZE) { if (nread < PAGE_SIZE) {
@ -576,7 +576,7 @@ PageFaultResponse Region::handle_inode_fault(size_t page_index_in_region, Scoped
vmobject_physical_page_entry = MM.allocate_user_physical_page(MemoryManager::ShouldZeroFill::No); vmobject_physical_page_entry = MM.allocate_user_physical_page(MemoryManager::ShouldZeroFill::No);
if (vmobject_physical_page_entry.is_null()) { if (vmobject_physical_page_entry.is_null()) {
klog() << "MM: handle_inode_fault was unable to allocate a physical page"; dmesgln("MM: handle_inode_fault was unable to allocate a physical page");
return PageFaultResponse::OutOfMemory; return PageFaultResponse::OutOfMemory;
} }