From 4569f39c7c1e3d7ce010f0b120e1f45dbba17b1c Mon Sep 17 00:00:00 2001 From: Wunkolo Date: Wed, 23 Jun 2021 14:18:27 -0700 Subject: common: Replace common_sizes into user-literals Removes common_sizes.h in favor of having `_KiB`, `_MiB`, `_GiB`, etc user-literals within literals.h. To keep the global namespace clean, users will have to use: ``` using namespace Common::Literals; ``` to access these literals. --- src/core/hle/kernel/k_memory_layout.board.nintendo_nx.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/core/hle/kernel/k_memory_layout.board.nintendo_nx.cpp') diff --git a/src/core/hle/kernel/k_memory_layout.board.nintendo_nx.cpp b/src/core/hle/kernel/k_memory_layout.board.nintendo_nx.cpp index a78551291..af652af58 100644 --- a/src/core/hle/kernel/k_memory_layout.board.nintendo_nx.cpp +++ b/src/core/hle/kernel/k_memory_layout.board.nintendo_nx.cpp @@ -3,6 +3,7 @@ // Refer to the license.txt file included. #include "common/alignment.h" +#include "common/literals.h" #include "core/hle/kernel/k_memory_layout.h" #include "core/hle/kernel/k_memory_manager.h" #include "core/hle/kernel/k_system_control.h" @@ -12,8 +13,10 @@ namespace Kernel { namespace { +using namespace Common::Literals; + constexpr size_t CarveoutAlignment = 0x20000; -constexpr size_t CarveoutSizeMax = (512ULL * 1024 * 1024) - CarveoutAlignment; +constexpr size_t CarveoutSizeMax = (512_MiB) - CarveoutAlignment; bool SetupPowerManagementControllerMemoryRegion(KMemoryLayout& memory_layout) { // Above firmware 2.0.0, the PMC is not mappable. -- cgit v1.2.3