Commit Graph

57 Commits

Author SHA1 Message Date
Liam 2a255b2d61 kernel: add KPageTableBase
Co-authored-by: Kelebek1 <eeeedddccc@hotmail.co.uk>
2023-11-10 12:01:35 -05:00
Liam 8c59543ee3 kernel: update KProcess 2023-10-21 20:03:41 -04:00
Liam f21058a6c0 k_page_table: add MapFirstGroup 2023-10-20 02:34:15 -04:00
Liam 0441853d0f k_page_table: implement PermissionLocked 2023-10-20 02:34:15 -04:00
Liam 60a1c6b95b k_page_table: add new CheckMemoryState helper 2023-10-20 02:34:15 -04:00
Liam 794e6c7a96 kernel: split Io memory state, add PermissionLocked attribute 2023-10-20 02:34:15 -04:00
Liam e797a917a9 kernel: implement transfer memory 2023-10-04 22:32:27 -04:00
Liam 474db2d8da kernel: reduce page table region checking 2023-07-14 22:33:10 -04:00
Liam 41d99aa89d memory: rename global memory references to application memory 2023-03-23 20:28:47 -04:00
Liam fb49ec19c1 kernel: use KTypedAddress for addresses 2023-03-22 09:35:16 -04:00
Liam ac6cbb7134 kernel: prefer std::addressof 2023-03-12 22:09:09 -04:00
Liam 31e54c4573 kernel: KPageTable: update 2023-01-22 13:17:29 -05:00
bunnei a5693afa03
Revert "Revert "k_page_group: synchronize"" 2023-01-07 15:32:10 -08:00
gidoly 10eaf31af3
Revert "k_page_group: synchronize" 2022-12-29 17:39:42 +09:00
Liam 28d9c30861 k_page_table: remove HACK_OpenPages/ClosePages 2022-12-25 13:43:49 -05:00
Liam 3392fdac9b k_page_group: synchronize 2022-12-25 12:55:21 -05:00
Liam 18123ff958 gdbstub: add ams monitor commands 2022-11-10 19:20:57 -05:00
bunnei 661fe06d9d core: hle: kernel: k_page_table: Implement IPC memory methods. 2022-11-03 21:17:07 -07:00
bunnei 32d7faafa8 core: hle: kernel: Integrate system KSystemResource. 2022-11-03 21:17:07 -07:00
bunnei 829e82e264 core: hle: kernel: Use result macros for new/changed code. 2022-10-18 19:13:35 -07:00
bunnei abcc009dff core: hle: kernel: k_process: Improve management of page table & cleanup. 2022-10-18 19:13:35 -07:00
bunnei ff26190d42 core: hle: kernel: k_page_table: Impl. LockForUn/MapDeviceAddressSpace, cleanup. 2022-10-18 19:13:35 -07:00
bunnei ed591934fb core: hle: kernel: k_page_table: Update, and integrate with new KMemoryBlockManager/SlabManager. 2022-10-18 19:13:34 -07:00
german77 7b48e7b363 core: kernel: Replace instances of KPageLinkedList with KPageGroup 2022-06-26 20:21:45 -05:00
german77 a7d9be1384 core: Replace all instances of ResultCode with Result 2022-06-26 20:21:37 -05:00
Liam 6c659c3a16 kernel: fix KCodeMemory initialization 2022-06-09 12:33:28 -04:00
Morph 99ceb03a1c general: Convert source file copyright comments over to SPDX
This formats all copyright comments according to SPDX formatting guidelines.
Additionally, this resolves the remaining GPLv2 only licensed files by relicensing them to GPLv2.0-or-later.
2022-04-23 05:55:32 -04:00
tech-ticks 3b91d213b1 hle: kernel: Invalidate entire icache in UnmapProcessMemory and UnmapCodeMemory (fixes #8174) 2022-04-09 13:29:19 +02:00
bunnei 0c75913bf2 hle: kernel: k_page_table: Implement LockMemoryAndOpen & UnlockMemory. 2022-03-26 01:46:41 -07:00
bunnei 5b667f5e52 hle: kernel: k_page_table: Implement MakeAndOpenPageGroup & MakePageGroup. 2022-03-26 01:25:52 -07:00
bunnei c975a51ae7 hle: kernel: k_page_table: Add IsHeapPhysicalAddress method. 2022-03-26 01:23:43 -07:00
bunnei 3210bc2767 core: hle: kernel: k_page_table: Add implementations of MapPages, UnmapPages, and FindFreeArea for TLS. 2022-03-14 18:14:54 -07:00
bunnei 853e58e593 hle: service: ldr: Use deterministic addresses when mapping NROs.
- Instead of randomization, choose in-order addresses for where to map NROs into memory.
- This results in predictable behavior when debugging and consistent behavior when reproducing issues.
2022-03-08 17:38:20 -08:00
bunnei 749f76e6fe hle: kernel: KPageTable: Improve implementations of MapCodeMemory and UnmapCodeMemory.
- This makes these functions more accurate to the real HOS implementations.
- Fixes memory access issues in Super Smash Bros. Ultimate that occur when un/mapping NROs.
2022-03-07 17:18:20 -08:00
bunnei f87f076162 hle: kernel: k_memory_manager: Rework for latest kernel behavior.
- Updates the KMemoryManager implementation against latest documentation.
- Reworks KMemoryLayout to be accessed throughout the kernel.
- Fixes an issue with pool sizes being incorrectly reported.
2022-02-27 18:00:09 -08:00
bunnei adbb9c2b00 hle: kernel: k_page_heap: GetPhysicalAddr can be const. 2022-02-27 10:34:02 -08:00
bunnei f7e65eb971 hle: kernel: k_page_heap: Remove superfluous consexpr. 2022-02-27 10:34:02 -08:00
bunnei 03186af6a1
Merge pull request #7835 from bunnei/page-table-lock
hle: kernel: KPageTable: Migrate locks to KScopedLightLock.
2022-02-02 17:58:55 -07:00
Lioncash f785f73e92 general: Replace NonCopyable struct with equivalents 2022-02-02 13:17:12 -05:00
bunnei 995e27e9b7 hle: kernel: KPageTable: Migrate locks to KScopedLightLock.
- More accurately reflects real kernel behavior by using guest locks.
2022-02-01 19:34:24 -08:00
bunnei 2935c9d8de core: hle: kernel: KPageTable: Assert valid address on GetPhysicalAddr. 2022-01-22 01:33:26 -08:00
bunnei 6d8e498f76 core: hle: kernel: Refactor Un/MapPhysicalMemory to remove unnecessary methods. 2022-01-22 01:33:26 -08:00
bunnei b8b1b58f36 core: hle: kernel: Rename Un/Map to Un/MapMeory. 2022-01-22 01:33:26 -08:00
bunnei b54cbc985e hle: kernel: k_memory_manager: Clear pages on allocation & free.
- Heap pages should be zero'd.
- Also explicitly passed along heap allocation option.
2022-01-14 21:16:33 -08:00
bunnei 49a0e4330e hle: kernel: k_page_table: Update SetProcessMemoryPermission. 2022-01-11 16:28:11 -08:00
bunnei 081669c334 hle: kernel: k_page_table: Rename *ProcessCodeMemory -> *CodeMemory. 2022-01-11 16:28:11 -08:00
bunnei af4696657c core: hle: kernel: svc: Updates to SetMemoryAttribute and SetMemoryPermission. 2022-01-08 12:18:14 -08:00
bunnei b9a313057e core: hle: kernel: k_page_table: Update CheckMemoryState. 2022-01-08 03:20:57 -08:00
bunnei 091463a429 core: hle: kernel: Updated implementation of svcSetHeapSize.
- Updates our svcSetHeapSize with latest HOS, furthermore allowing heap size to properly be extended/shrunk.
- Validated with tests https://github.com/Atmosphere-NX/Atmosphere/blob/master/tests/TestSvc/source/test_set_heap_size.cpp.
2021-12-28 01:25:20 -08:00
bunnei 4e7a6639d2 core: hle: kernel: Implement SetMemoryPermission.
- Not seen in any games yet, but validated with kernel tests.
2021-12-23 01:10:36 -08:00