mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 03:17:35 +00:00
AK: Rename KB, MB, GB to KiB, MiB, GiB
The SI prefixes "k", "M", "G" mean "10^3", "10^6", "10^9". The IEC prefixes "Ki", "Mi", "Gi" mean "2^10", "2^20", "2^30". Let's use the correct name, at least in code. Only changes the name of the constants, no other behavior change.
This commit is contained in:
parent
a68650a7b4
commit
430b265cd4
31 changed files with 69 additions and 69 deletions
|
@ -80,7 +80,7 @@ PageDirectory::PageDirectory(Process& process, const RangeAllocator* parent_rang
|
|||
if (parent_range_allocator) {
|
||||
m_range_allocator.initialize_from_parent(*parent_range_allocator);
|
||||
} else {
|
||||
size_t random_offset = (get_fast_random<u8>() % 32 * MB) & PAGE_MASK;
|
||||
size_t random_offset = (get_fast_random<u8>() % 32 * MiB) & PAGE_MASK;
|
||||
u32 base = userspace_range_base + random_offset;
|
||||
m_range_allocator.initialize_with_range(VirtualAddress(base), userspace_range_ceiling - base);
|
||||
}
|
||||
|
@ -102,7 +102,7 @@ PageDirectory::PageDirectory(Process& process, const RangeAllocator* parent_rang
|
|||
MM.unquickmap_page();
|
||||
}
|
||||
|
||||
// Clone bottom 2 MB of mappings from kernel_page_directory
|
||||
// Clone bottom 2 MiB of mappings from kernel_page_directory
|
||||
PageDirectoryEntry buffer;
|
||||
auto* kernel_pd = MM.quickmap_pd(MM.kernel_page_directory(), 0);
|
||||
memcpy(&buffer, kernel_pd, sizeof(PageDirectoryEntry));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue