mirror of
https://git.eden-emu.dev/eden-emu/eden.git
synced 2025-10-17 17:17:52 +00:00
hle: kernel: Add architecture and board specific memory regions.
This commit is contained in:
parent
0f5efc8f29
commit
d25a181956
2 changed files with 72 additions and 0 deletions
|
@ -0,0 +1,20 @@
|
|||
// Copyright 2021 yuzu Emulator Project
|
||||
// Licensed under GPLv2 or any later version
|
||||
// Refer to the license.txt file included.
|
||||
|
||||
// All architectures must define NumArchitectureDeviceRegions.
|
||||
constexpr inline const auto NumArchitectureDeviceRegions = 3;
|
||||
|
||||
constexpr inline const auto KMemoryRegionType_Uart =
|
||||
KMemoryRegionType_ArchDeviceBase.DeriveSparse(0, NumArchitectureDeviceRegions, 0);
|
||||
constexpr inline const auto KMemoryRegionType_InterruptCpuInterface =
|
||||
KMemoryRegionType_ArchDeviceBase.DeriveSparse(0, NumArchitectureDeviceRegions, 1)
|
||||
.SetAttribute(KMemoryRegionAttr_NoUserMap);
|
||||
constexpr inline const auto KMemoryRegionType_InterruptDistributor =
|
||||
KMemoryRegionType_ArchDeviceBase.DeriveSparse(0, NumArchitectureDeviceRegions, 2)
|
||||
.SetAttribute(KMemoryRegionAttr_NoUserMap);
|
||||
static_assert(KMemoryRegionType_Uart.GetValue() == (0x1D));
|
||||
static_assert(KMemoryRegionType_InterruptCpuInterface.GetValue() ==
|
||||
(0x2D | KMemoryRegionAttr_NoUserMap));
|
||||
static_assert(KMemoryRegionType_InterruptDistributor.GetValue() ==
|
||||
(0x4D | KMemoryRegionAttr_NoUserMap));
|
Loading…
Add table
Add a link
Reference in a new issue