Bladeren bron

Kernel: Rename Kernel/VM/ to Kernel/Memory/

This directory isn't just about virtual memory, it's about all kinds
of memory management.
Andreas Kling 4 jaren geleden
bovenliggende
commit
a1d7ebf85a
100 gewijzigde bestanden met toevoegingen van 175 en 172 verwijderingen
  1. 2 0
      AK/RedBlackTree.h
  2. 1 1
      Kernel/ACPI/DynamicParser.h
  3. 1 1
      Kernel/ACPI/MultiProcessorParser.cpp
  4. 1 1
      Kernel/ACPI/MultiProcessorParser.h
  5. 1 1
      Kernel/ACPI/Parser.cpp
  6. 1 1
      Kernel/ACPI/Parser.h
  7. 2 2
      Kernel/Arch/PC/BIOS.cpp
  8. 2 2
      Kernel/Arch/PC/BIOS.h
  9. 1 1
      Kernel/Arch/x86/common/Processor.cpp
  10. 1 1
      Kernel/Bus/PCI/MMIOAccess.cpp
  11. 4 4
      Kernel/Bus/PCI/MMIOAccess.h
  12. 1 1
      Kernel/Bus/PCI/WindowedMMIOAccess.cpp
  13. 4 4
      Kernel/Bus/PCI/WindowedMMIOAccess.h
  14. 2 2
      Kernel/Bus/USB/UHCIController.cpp
  15. 1 1
      Kernel/Bus/USB/UHCIController.h
  16. 1 1
      Kernel/Bus/USB/USBPipe.h
  17. 1 1
      Kernel/Bus/USB/USBTransfer.cpp
  18. 3 3
      Kernel/Bus/USB/USBTransfer.h
  19. 18 18
      Kernel/CMakeLists.txt
  20. 1 1
      Kernel/CoreDump.cpp
  21. 1 1
      Kernel/Devices/AsyncDeviceRequest.h
  22. 1 1
      Kernel/Devices/KCOVInstance.h
  23. 1 1
      Kernel/Devices/MemoryDevice.cpp
  24. 2 2
      Kernel/Devices/SB16.cpp
  25. 1 1
      Kernel/Devices/SB16.h
  26. 1 1
      Kernel/FileSystem/AnonymousFile.cpp
  27. 1 1
      Kernel/FileSystem/AnonymousFile.h
  28. 1 1
      Kernel/FileSystem/FileDescription.cpp
  29. 1 1
      Kernel/FileSystem/FileSystem.cpp
  30. 1 1
      Kernel/FileSystem/Inode.cpp
  31. 2 2
      Kernel/FileSystem/InodeFile.cpp
  32. 1 1
      Kernel/FutexQueue.h
  33. 1 1
      Kernel/Graphics/Bochs/GraphicsAdapter.cpp
  34. 1 1
      Kernel/Graphics/Bochs/GraphicsAdapter.h
  35. 2 2
      Kernel/Graphics/FramebufferDevice.cpp
  36. 1 1
      Kernel/Graphics/FramebufferDevice.h
  37. 1 1
      Kernel/Graphics/GraphicsManagement.cpp
  38. 1 1
      Kernel/Graphics/GraphicsManagement.h
  39. 1 1
      Kernel/Heap/SlabAllocator.cpp
  40. 1 1
      Kernel/Heap/kmalloc.cpp
  41. 3 3
      Kernel/Interrupts/APIC.cpp
  42. 1 1
      Kernel/Interrupts/APIC.h
  43. 1 1
      Kernel/Interrupts/IOAPIC.h
  44. 1 1
      Kernel/Interrupts/InterruptManagement.cpp
  45. 2 2
      Kernel/KBuffer.h
  46. 0 0
      Kernel/Memory/AllocationStrategy.h
  47. 3 3
      Kernel/Memory/AnonymousVMObject.cpp
  48. 4 4
      Kernel/Memory/AnonymousVMObject.h
  49. 1 1
      Kernel/Memory/InodeVMObject.cpp
  50. 1 1
      Kernel/Memory/InodeVMObject.h
  51. 1 1
      Kernel/Memory/MappedROM.h
  52. 5 5
      Kernel/Memory/MemoryManager.cpp
  53. 5 5
      Kernel/Memory/MemoryManager.h
  54. 2 2
      Kernel/Memory/PageDirectory.cpp
  55. 2 2
      Kernel/Memory/PageDirectory.h
  56. 0 0
      Kernel/Memory/PageFaultResponse.h
  57. 2 2
      Kernel/Memory/PhysicalPage.cpp
  58. 0 0
      Kernel/Memory/PhysicalPage.h
  59. 3 3
      Kernel/Memory/PhysicalRegion.cpp
  60. 2 2
      Kernel/Memory/PhysicalRegion.h
  61. 3 3
      Kernel/Memory/PhysicalZone.cpp
  62. 0 0
      Kernel/Memory/PhysicalZone.h
  63. 1 1
      Kernel/Memory/PrivateInodeVMObject.cpp
  64. 1 1
      Kernel/Memory/PrivateInodeVMObject.h
  65. 2 2
      Kernel/Memory/ProcessPagingScope.cpp
  66. 0 0
      Kernel/Memory/ProcessPagingScope.h
  67. 2 2
      Kernel/Memory/Range.cpp
  68. 1 0
      Kernel/Memory/Range.h
  69. 1 1
      Kernel/Memory/RangeAllocator.cpp
  70. 1 1
      Kernel/Memory/RangeAllocator.h
  71. 5 5
      Kernel/Memory/Region.cpp
  72. 2 2
      Kernel/Memory/Region.h
  73. 2 2
      Kernel/Memory/RingBuffer.cpp
  74. 0 0
      Kernel/Memory/RingBuffer.h
  75. 1 1
      Kernel/Memory/ScatterGatherList.cpp
  76. 2 2
      Kernel/Memory/ScatterGatherList.h
  77. 1 1
      Kernel/Memory/SharedInodeVMObject.cpp
  78. 1 1
      Kernel/Memory/SharedInodeVMObject.h
  79. 4 4
      Kernel/Memory/Space.cpp
  80. 2 2
      Kernel/Memory/Space.h
  81. 1 1
      Kernel/Memory/TypedMapping.h
  82. 2 2
      Kernel/Memory/VMObject.cpp
  83. 1 1
      Kernel/Memory/VMObject.h
  84. 1 1
      Kernel/Net/NetworkingManagement.cpp
  85. 1 1
      Kernel/Net/NetworkingManagement.h
  86. 3 3
      Kernel/Process.cpp
  87. 1 1
      Kernel/Process.h
  88. 2 2
      Kernel/ProcessSpecificExposed.cpp
  89. 1 1
      Kernel/StdLib.cpp
  90. 1 1
      Kernel/Storage/AHCIController.cpp
  91. 3 3
      Kernel/Storage/AHCIPort.cpp
  92. 3 3
      Kernel/Storage/AHCIPort.h
  93. 1 1
      Kernel/Storage/AHCIPortHandler.h
  94. 1 1
      Kernel/Storage/IDEChannel.cpp
  95. 1 1
      Kernel/Storage/IDEChannel.h
  96. 1 1
      Kernel/Storage/StorageController.h
  97. 1 1
      Kernel/Syscall.cpp
  98. 1 1
      Kernel/Syscalls/anon_create.cpp
  99. 5 5
      Kernel/Syscalls/execve.cpp
  100. 1 1
      Kernel/Syscalls/fork.cpp

+ 2 - 0
AK/RedBlackTree.h

@@ -7,6 +7,8 @@
 #pragma once
 
 #include <AK/Concepts.h>
+#include <AK/Noncopyable.h>
+#include <AK/kmalloc.h>
 
 namespace AK {
 

+ 1 - 1
Kernel/ACPI/DynamicParser.h

@@ -9,9 +9,9 @@
 #include <AK/RefPtr.h>
 #include <Kernel/ACPI/Parser.h>
 #include <Kernel/Interrupts/IRQHandler.h>
+#include <Kernel/Memory/PhysicalPage.h>
 #include <Kernel/Mutex.h>
 #include <Kernel/PhysicalAddress.h>
-#include <Kernel/VM/PhysicalPage.h>
 
 namespace Kernel::ACPI {
 

+ 1 - 1
Kernel/ACPI/MultiProcessorParser.cpp

@@ -10,9 +10,9 @@
 #include <Kernel/Arch/PC/BIOS.h>
 #include <Kernel/Debug.h>
 #include <Kernel/Interrupts/IOAPIC.h>
+#include <Kernel/Memory/TypedMapping.h>
 #include <Kernel/Sections.h>
 #include <Kernel/StdLib.h>
-#include <Kernel/VM/TypedMapping.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/ACPI/MultiProcessorParser.h

@@ -7,8 +7,8 @@
 #pragma once
 
 #include <AK/Types.h>
+#include <Kernel/Memory/Region.h>
 #include <Kernel/PhysicalAddress.h>
-#include <Kernel/VM/Region.h>
 #include <Kernel/VirtualAddress.h>
 
 namespace Kernel {

+ 1 - 1
Kernel/ACPI/Parser.cpp

@@ -13,9 +13,9 @@
 #include <Kernel/Bus/PCI/Access.h>
 #include <Kernel/Debug.h>
 #include <Kernel/IO.h>
+#include <Kernel/Memory/TypedMapping.h>
 #include <Kernel/Sections.h>
 #include <Kernel/StdLib.h>
-#include <Kernel/VM/TypedMapping.h>
 
 namespace Kernel::ACPI {
 

+ 1 - 1
Kernel/ACPI/Parser.h

@@ -10,8 +10,8 @@
 #include <Kernel/ACPI/Definitions.h>
 #include <Kernel/ACPI/Initialize.h>
 #include <Kernel/FileSystem/SysFSComponent.h>
+#include <Kernel/Memory/Region.h>
 #include <Kernel/PhysicalAddress.h>
-#include <Kernel/VM/Region.h>
 #include <Kernel/VirtualAddress.h>
 
 namespace Kernel::ACPI {

+ 2 - 2
Kernel/Arch/PC/BIOS.cpp

@@ -9,9 +9,9 @@
 #include <Kernel/Arch/PC/BIOS.h>
 #include <Kernel/FileSystem/FileDescription.h>
 #include <Kernel/KBufferBuilder.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/TypedMapping.h>
 #include <Kernel/Sections.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/TypedMapping.h>
 
 namespace Kernel {
 

+ 2 - 2
Kernel/Arch/PC/BIOS.h

@@ -11,9 +11,9 @@
 #include <AK/Vector.h>
 #include <Kernel/FileSystem/SysFS.h>
 #include <Kernel/KBuffer.h>
+#include <Kernel/Memory/MappedROM.h>
+#include <Kernel/Memory/Region.h>
 #include <Kernel/PhysicalAddress.h>
-#include <Kernel/VM/MappedROM.h>
-#include <Kernel/VM/Region.h>
 #include <Kernel/VirtualAddress.h>
 
 namespace Kernel::SMBIOS {

+ 1 - 1
Kernel/Arch/x86/common/Processor.cpp

@@ -10,11 +10,11 @@
 #include <AK/Types.h>
 
 #include <Kernel/Interrupts/APIC.h>
+#include <Kernel/Memory/ProcessPagingScope.h>
 #include <Kernel/Process.h>
 #include <Kernel/Sections.h>
 #include <Kernel/StdLib.h>
 #include <Kernel/Thread.h>
-#include <Kernel/VM/ProcessPagingScope.h>
 
 #include <Kernel/Arch/x86/CPUID.h>
 #include <Kernel/Arch/x86/Interrupts.h>

+ 1 - 1
Kernel/Bus/PCI/MMIOAccess.cpp

@@ -9,8 +9,8 @@
 #include <Kernel/Arch/x86/InterruptDisabler.h>
 #include <Kernel/Bus/PCI/MMIOAccess.h>
 #include <Kernel/Debug.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/Sections.h>
-#include <Kernel/VM/MemoryManager.h>
 
 namespace Kernel {
 namespace PCI {

+ 4 - 4
Kernel/Bus/PCI/MMIOAccess.h

@@ -12,11 +12,11 @@
 #include <AK/Types.h>
 #include <Kernel/ACPI/Definitions.h>
 #include <Kernel/Bus/PCI/Access.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
+#include <Kernel/Memory/PhysicalRegion.h>
+#include <Kernel/Memory/Region.h>
+#include <Kernel/Memory/VMObject.h>
 #include <Kernel/SpinLock.h>
-#include <Kernel/VM/AnonymousVMObject.h>
-#include <Kernel/VM/PhysicalRegion.h>
-#include <Kernel/VM/Region.h>
-#include <Kernel/VM/VMObject.h>
 
 namespace Kernel {
 namespace PCI {

+ 1 - 1
Kernel/Bus/PCI/WindowedMMIOAccess.cpp

@@ -10,8 +10,8 @@
 #include <Kernel/Arch/x86/InterruptDisabler.h>
 #include <Kernel/Bus/PCI/WindowedMMIOAccess.h>
 #include <Kernel/Debug.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/Sections.h>
-#include <Kernel/VM/MemoryManager.h>
 
 namespace Kernel {
 namespace PCI {

+ 4 - 4
Kernel/Bus/PCI/WindowedMMIOAccess.h

@@ -13,10 +13,10 @@
 #include <Kernel/ACPI/Definitions.h>
 #include <Kernel/Bus/PCI/Access.h>
 #include <Kernel/Bus/PCI/MMIOAccess.h>
-#include <Kernel/VM/AnonymousVMObject.h>
-#include <Kernel/VM/PhysicalRegion.h>
-#include <Kernel/VM/Region.h>
-#include <Kernel/VM/VMObject.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
+#include <Kernel/Memory/PhysicalRegion.h>
+#include <Kernel/Memory/Region.h>
+#include <Kernel/Memory/VMObject.h>
 
 namespace Kernel {
 namespace PCI {

+ 2 - 2
Kernel/Bus/USB/UHCIController.cpp

@@ -14,12 +14,12 @@
 #include <Kernel/Debug.h>
 #include <Kernel/FileSystem/SysFS.h>
 #include <Kernel/KBufferBuilder.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/Process.h>
 #include <Kernel/Sections.h>
 #include <Kernel/StdLib.h>
 #include <Kernel/Time/TimeManagement.h>
-#include <Kernel/VM/AnonymousVMObject.h>
-#include <Kernel/VM/MemoryManager.h>
 
 static constexpr u8 MAXIMUM_NUMBER_OF_TDS = 128; // Upper pool limit. This consumes the second page we have allocated
 static constexpr u8 MAXIMUM_NUMBER_OF_QHS = 64;

+ 1 - 1
Kernel/Bus/USB/UHCIController.h

@@ -15,9 +15,9 @@
 #include <Kernel/Bus/USB/USBDevice.h>
 #include <Kernel/Bus/USB/USBTransfer.h>
 #include <Kernel/IO.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
 #include <Kernel/Process.h>
 #include <Kernel/Time/TimeManagement.h>
-#include <Kernel/VM/AnonymousVMObject.h>
 
 namespace Kernel::USB {
 

+ 1 - 1
Kernel/Bus/USB/USBPipe.h

@@ -9,7 +9,7 @@
 #include <AK/OwnPtr.h>
 #include <AK/Types.h>
 #include <Kernel/Bus/USB/USBDescriptors.h>
-#include <Kernel/VM/Region.h>
+#include <Kernel/Memory/Region.h>
 
 namespace Kernel::USB {
 

+ 1 - 1
Kernel/Bus/USB/USBTransfer.cpp

@@ -5,7 +5,7 @@
  */
 
 #include <Kernel/Bus/USB/USBTransfer.h>
-#include <Kernel/VM/MemoryManager.h>
+#include <Kernel/Memory/MemoryManager.h>
 
 namespace Kernel::USB {
 

+ 3 - 3
Kernel/Bus/USB/USBTransfer.h

@@ -10,9 +10,9 @@
 #include <AK/RefPtr.h>
 #include <Kernel/Bus/USB/PacketTypes.h>
 #include <Kernel/Bus/USB/USBPipe.h>
-#include <Kernel/VM/AnonymousVMObject.h>
-#include <Kernel/VM/PhysicalPage.h>
-#include <Kernel/VM/Region.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
+#include <Kernel/Memory/PhysicalPage.h>
+#include <Kernel/Memory/Region.h>
 
 // TODO: Callback stuff in this class please!
 namespace Kernel::USB {

+ 18 - 18
Kernel/CMakeLists.txt

@@ -131,6 +131,23 @@ set(KERNEL_SOURCES
     KLexicalPath.cpp
     KString.cpp
     KSyms.cpp
+    Memory/AnonymousVMObject.cpp
+    Memory/InodeVMObject.cpp
+    Memory/MemoryManager.cpp
+    Memory/PageDirectory.cpp
+    Memory/PhysicalPage.cpp
+    Memory/PhysicalRegion.cpp
+    Memory/PhysicalZone.cpp
+    Memory/PrivateInodeVMObject.cpp
+    Memory/ProcessPagingScope.cpp
+    Memory/Range.cpp
+    Memory/RangeAllocator.cpp
+    Memory/Region.cpp
+    Memory/RingBuffer.cpp
+    Memory/ScatterGatherList.cpp
+    Memory/SharedInodeVMObject.cpp
+    Memory/Space.cpp
+    Memory/VMObject.cpp
     MiniStdLib.cpp
     Mutex.cpp
     Net/E1000ENetworkAdapter.cpp
@@ -140,8 +157,8 @@ set(KERNEL_SOURCES
     Net/LoopbackAdapter.cpp
     Net/NE2000NetworkAdapter.cpp
     Net/NetworkAdapter.cpp
-    Net/NetworkingManagement.cpp
     Net/NetworkTask.cpp
+    Net/NetworkingManagement.cpp
     Net/RTL8139NetworkAdapter.cpp
     Net/RTL8168NetworkAdapter.cpp
     Net/Routing.cpp
@@ -255,23 +272,6 @@ set(KERNEL_SOURCES
     VirtIO/VirtIOConsolePort.cpp
     VirtIO/VirtIOQueue.cpp
     VirtIO/VirtIORNG.cpp
-    VM/AnonymousVMObject.cpp
-    VM/InodeVMObject.cpp
-    VM/MemoryManager.cpp
-    VM/PageDirectory.cpp
-    VM/PhysicalPage.cpp
-    VM/PhysicalRegion.cpp
-    VM/PhysicalZone.cpp
-    VM/PrivateInodeVMObject.cpp
-    VM/ProcessPagingScope.cpp
-    VM/Range.cpp
-    VM/RangeAllocator.cpp
-    VM/Region.cpp
-    VM/RingBuffer.cpp
-    VM/ScatterGatherList.cpp
-    VM/SharedInodeVMObject.cpp
-    VM/Space.cpp
-    VM/VMObject.cpp
     WaitQueue.cpp
     WorkQueue.cpp
     init.cpp

+ 1 - 1
Kernel/CoreDump.cpp

@@ -14,10 +14,10 @@
 #include <Kernel/FileSystem/FileDescription.h>
 #include <Kernel/FileSystem/VirtualFileSystem.h>
 #include <Kernel/KLexicalPath.h>
+#include <Kernel/Memory/ProcessPagingScope.h>
 #include <Kernel/Process.h>
 #include <Kernel/RTC.h>
 #include <Kernel/SpinLock.h>
-#include <Kernel/VM/ProcessPagingScope.h>
 #include <LibC/elf.h>
 #include <LibELF/CoreDump.h>
 

+ 1 - 1
Kernel/Devices/AsyncDeviceRequest.h

@@ -8,10 +8,10 @@
 
 #include <AK/IntrusiveList.h>
 #include <AK/NonnullRefPtr.h>
+#include <Kernel/Memory/ProcessPagingScope.h>
 #include <Kernel/Process.h>
 #include <Kernel/Thread.h>
 #include <Kernel/UserOrKernelBuffer.h>
-#include <Kernel/VM/ProcessPagingScope.h>
 #include <Kernel/WaitQueue.h>
 
 namespace Kernel {

+ 1 - 1
Kernel/Devices/KCOVInstance.h

@@ -6,8 +6,8 @@
 
 #pragma once
 
+#include <Kernel/Memory/AnonymousVMObject.h>
 #include <Kernel/SpinLock.h>
-#include <Kernel/VM/AnonymousVMObject.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/Devices/MemoryDevice.cpp

@@ -8,8 +8,8 @@
 #include <AK/StdLibExtras.h>
 #include <Kernel/Arch/PC/BIOS.h>
 #include <Kernel/Devices/MemoryDevice.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
 #include <Kernel/Sections.h>
-#include <Kernel/VM/AnonymousVMObject.h>
 
 namespace Kernel {
 

+ 2 - 2
Kernel/Devices/SB16.cpp

@@ -11,10 +11,10 @@
 #include <Kernel/Debug.h>
 #include <Kernel/Devices/SB16.h>
 #include <Kernel/IO.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/Sections.h>
 #include <Kernel/Thread.h>
-#include <Kernel/VM/AnonymousVMObject.h>
-#include <Kernel/VM/MemoryManager.h>
 
 namespace Kernel {
 #define SB16_DEFAULT_IRQ 5

+ 1 - 1
Kernel/Devices/SB16.h

@@ -8,8 +8,8 @@
 
 #include <Kernel/Devices/CharacterDevice.h>
 #include <Kernel/Interrupts/IRQHandler.h>
+#include <Kernel/Memory/PhysicalPage.h>
 #include <Kernel/PhysicalAddress.h>
-#include <Kernel/VM/PhysicalPage.h>
 #include <Kernel/WaitQueue.h>
 
 namespace Kernel {

+ 1 - 1
Kernel/FileSystem/AnonymousFile.cpp

@@ -5,8 +5,8 @@
  */
 
 #include <Kernel/FileSystem/AnonymousFile.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
 #include <Kernel/Process.h>
-#include <Kernel/VM/AnonymousVMObject.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/FileSystem/AnonymousFile.h

@@ -7,7 +7,7 @@
 #pragma once
 
 #include <Kernel/FileSystem/File.h>
-#include <Kernel/VM/AnonymousVMObject.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/FileSystem/FileDescription.cpp

@@ -14,12 +14,12 @@
 #include <Kernel/FileSystem/FileSystem.h>
 #include <Kernel/FileSystem/InodeFile.h>
 #include <Kernel/FileSystem/InodeWatcher.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/Net/Socket.h>
 #include <Kernel/Process.h>
 #include <Kernel/TTY/MasterPTY.h>
 #include <Kernel/TTY/TTY.h>
 #include <Kernel/UnixTypes.h>
-#include <Kernel/VM/MemoryManager.h>
 #include <LibC/errno_numbers.h>
 
 namespace Kernel {

+ 1 - 1
Kernel/FileSystem/FileSystem.cpp

@@ -10,8 +10,8 @@
 #include <Kernel/Arch/x86/InterruptDisabler.h>
 #include <Kernel/FileSystem/FileSystem.h>
 #include <Kernel/FileSystem/Inode.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/Net/LocalSocket.h>
-#include <Kernel/VM/MemoryManager.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/FileSystem/Inode.cpp

@@ -16,9 +16,9 @@
 #include <Kernel/FileSystem/InodeWatcher.h>
 #include <Kernel/FileSystem/VirtualFileSystem.h>
 #include <Kernel/KBufferBuilder.h>
+#include <Kernel/Memory/SharedInodeVMObject.h>
 #include <Kernel/Net/LocalSocket.h>
 #include <Kernel/Process.h>
-#include <Kernel/VM/SharedInodeVMObject.h>
 
 namespace Kernel {
 

+ 2 - 2
Kernel/FileSystem/InodeFile.cpp

@@ -9,9 +9,9 @@
 #include <Kernel/FileSystem/Inode.h>
 #include <Kernel/FileSystem/InodeFile.h>
 #include <Kernel/FileSystem/VirtualFileSystem.h>
+#include <Kernel/Memory/PrivateInodeVMObject.h>
+#include <Kernel/Memory/SharedInodeVMObject.h>
 #include <Kernel/Process.h>
-#include <Kernel/VM/PrivateInodeVMObject.h>
-#include <Kernel/VM/SharedInodeVMObject.h>
 #include <LibC/errno_numbers.h>
 #include <LibC/sys/ioctl_numbers.h>
 

+ 1 - 1
Kernel/FutexQueue.h

@@ -8,9 +8,9 @@
 
 #include <AK/Atomic.h>
 #include <AK/RefCounted.h>
+#include <Kernel/Memory/VMObject.h>
 #include <Kernel/SpinLock.h>
 #include <Kernel/Thread.h>
-#include <Kernel/VM/VMObject.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/Graphics/Bochs/GraphicsAdapter.cpp

@@ -13,8 +13,8 @@
 #include <Kernel/Graphics/Console/ContiguousFramebufferConsole.h>
 #include <Kernel/Graphics/GraphicsManagement.h>
 #include <Kernel/IO.h>
+#include <Kernel/Memory/TypedMapping.h>
 #include <Kernel/Sections.h>
-#include <Kernel/VM/TypedMapping.h>
 
 #define VBE_DISPI_IOPORT_INDEX 0x01CE
 #define VBE_DISPI_IOPORT_DATA 0x01CF

+ 1 - 1
Kernel/Graphics/Bochs/GraphicsAdapter.h

@@ -12,8 +12,8 @@
 #include <Kernel/Graphics/Console/GenericFramebufferConsole.h>
 #include <Kernel/Graphics/FramebufferDevice.h>
 #include <Kernel/Graphics/GraphicsDevice.h>
+#include <Kernel/Memory/TypedMapping.h>
 #include <Kernel/PhysicalAddress.h>
-#include <Kernel/VM/TypedMapping.h>
 
 namespace Kernel {
 

+ 2 - 2
Kernel/Graphics/FramebufferDevice.cpp

@@ -8,10 +8,10 @@
 #include <Kernel/Debug.h>
 #include <Kernel/Graphics/FramebufferDevice.h>
 #include <Kernel/Graphics/GraphicsManagement.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/Process.h>
 #include <Kernel/Sections.h>
-#include <Kernel/VM/AnonymousVMObject.h>
-#include <Kernel/VM/MemoryManager.h>
 #include <LibC/errno_numbers.h>
 #include <LibC/sys/ioctl_numbers.h>
 

+ 1 - 1
Kernel/Graphics/FramebufferDevice.h

@@ -11,9 +11,9 @@
 #include <AK/Types.h>
 #include <Kernel/Devices/BlockDevice.h>
 #include <Kernel/Graphics/GraphicsDevice.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
 #include <Kernel/PhysicalAddress.h>
 #include <Kernel/SpinLock.h>
-#include <Kernel/VM/AnonymousVMObject.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/Graphics/GraphicsManagement.cpp

@@ -13,9 +13,9 @@
 #include <Kernel/Graphics/VGACompatibleAdapter.h>
 #include <Kernel/Graphics/VirtIOGPU/GraphicsAdapter.h>
 #include <Kernel/IO.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
 #include <Kernel/Multiboot.h>
 #include <Kernel/Sections.h>
-#include <Kernel/VM/AnonymousVMObject.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/Graphics/GraphicsManagement.h

@@ -15,7 +15,7 @@
 #include <Kernel/Graphics/GraphicsDevice.h>
 #include <Kernel/Graphics/VGACompatibleAdapter.h>
 #include <Kernel/Graphics/VirtIOGPU/GraphicsAdapter.h>
-#include <Kernel/VM/Region.h>
+#include <Kernel/Memory/Region.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/Heap/SlabAllocator.cpp

@@ -8,8 +8,8 @@
 #include <AK/Memory.h>
 #include <Kernel/Heap/SlabAllocator.h>
 #include <Kernel/Heap/kmalloc.h>
+#include <Kernel/Memory/Region.h>
 #include <Kernel/Sections.h>
-#include <Kernel/VM/Region.h>
 
 #define SANITIZE_SLABS
 

+ 1 - 1
Kernel/Heap/kmalloc.cpp

@@ -16,12 +16,12 @@
 #include <Kernel/Heap/Heap.h>
 #include <Kernel/Heap/kmalloc.h>
 #include <Kernel/KSyms.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/Panic.h>
 #include <Kernel/PerformanceManager.h>
 #include <Kernel/Sections.h>
 #include <Kernel/SpinLock.h>
 #include <Kernel/StdLib.h>
-#include <Kernel/VM/MemoryManager.h>
 
 #define CHUNK_SIZE 32
 #define POOL_SIZE (2 * MiB)

+ 3 - 3
Kernel/Interrupts/APIC.cpp

@@ -15,13 +15,13 @@
 #include <Kernel/IO.h>
 #include <Kernel/Interrupts/APIC.h>
 #include <Kernel/Interrupts/SpuriousInterruptHandler.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/PageDirectory.h>
+#include <Kernel/Memory/TypedMapping.h>
 #include <Kernel/Panic.h>
 #include <Kernel/Sections.h>
 #include <Kernel/Thread.h>
 #include <Kernel/Time/APICTimer.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/PageDirectory.h>
-#include <Kernel/VM/TypedMapping.h>
 
 #define IRQ_APIC_TIMER (0xfc - IRQ_VECTOR_BASE)
 #define IRQ_APIC_IPI (0xfd - IRQ_VECTOR_BASE)

+ 1 - 1
Kernel/Interrupts/APIC.h

@@ -7,8 +7,8 @@
 #pragma once
 
 #include <AK/Types.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/Time/HardwareTimer.h>
-#include <Kernel/VM/MemoryManager.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/Interrupts/IOAPIC.h

@@ -7,7 +7,7 @@
 #pragma once
 
 #include <Kernel/Interrupts/IRQController.h>
-#include <Kernel/VM/TypedMapping.h>
+#include <Kernel/Memory/TypedMapping.h>
 
 namespace Kernel {
 struct [[gnu::packed]] ioapic_mmio_regs {

+ 1 - 1
Kernel/Interrupts/InterruptManagement.cpp

@@ -16,8 +16,8 @@
 #include <Kernel/Interrupts/PIC.h>
 #include <Kernel/Interrupts/SharedIRQHandler.h>
 #include <Kernel/Interrupts/SpuriousInterruptHandler.h>
+#include <Kernel/Memory/TypedMapping.h>
 #include <Kernel/Sections.h>
-#include <Kernel/VM/TypedMapping.h>
 
 #define PCAT_COMPAT_FLAG 0x1
 

+ 2 - 2
Kernel/KBuffer.h

@@ -20,8 +20,8 @@
 #include <AK/ByteBuffer.h>
 #include <AK/Memory.h>
 #include <AK/StringView.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/Region.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/Region.h>
 
 namespace Kernel {
 

+ 0 - 0
Kernel/VM/AllocationStrategy.h → Kernel/Memory/AllocationStrategy.h


+ 3 - 3
Kernel/VM/AnonymousVMObject.cpp → Kernel/Memory/AnonymousVMObject.cpp

@@ -6,10 +6,10 @@
 
 #include <Kernel/Arch/x86/SmapDisabler.h>
 #include <Kernel/Debug.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/PhysicalPage.h>
 #include <Kernel/Process.h>
-#include <Kernel/VM/AnonymousVMObject.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/PhysicalPage.h>
 
 namespace Kernel {
 

+ 4 - 4
Kernel/VM/AnonymousVMObject.h → Kernel/Memory/AnonymousVMObject.h

@@ -6,11 +6,11 @@
 
 #pragma once
 
+#include <Kernel/Memory/AllocationStrategy.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/PageFaultResponse.h>
+#include <Kernel/Memory/VMObject.h>
 #include <Kernel/PhysicalAddress.h>
-#include <Kernel/VM/AllocationStrategy.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/PageFaultResponse.h>
-#include <Kernel/VM/VMObject.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/VM/InodeVMObject.cpp → Kernel/Memory/InodeVMObject.cpp

@@ -5,7 +5,7 @@
  */
 
 #include <Kernel/FileSystem/Inode.h>
-#include <Kernel/VM/InodeVMObject.h>
+#include <Kernel/Memory/InodeVMObject.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/VM/InodeVMObject.h → Kernel/Memory/InodeVMObject.h

@@ -7,8 +7,8 @@
 #pragma once
 
 #include <AK/Bitmap.h>
+#include <Kernel/Memory/VMObject.h>
 #include <Kernel/UnixTypes.h>
-#include <Kernel/VM/VMObject.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/VM/MappedROM.h → Kernel/Memory/MappedROM.h

@@ -7,8 +7,8 @@
 #pragma once
 
 #include <AK/OwnPtr.h>
+#include <Kernel/Memory/Region.h>
 #include <Kernel/PhysicalAddress.h>
-#include <Kernel/VM/Region.h>
 
 namespace Kernel {
 

+ 5 - 5
Kernel/VM/MemoryManager.cpp → Kernel/Memory/MemoryManager.cpp

@@ -11,16 +11,16 @@
 #include <Kernel/CMOS.h>
 #include <Kernel/FileSystem/Inode.h>
 #include <Kernel/Heap/kmalloc.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/PageDirectory.h>
+#include <Kernel/Memory/PhysicalRegion.h>
+#include <Kernel/Memory/SharedInodeVMObject.h>
 #include <Kernel/Multiboot.h>
 #include <Kernel/Panic.h>
 #include <Kernel/Process.h>
 #include <Kernel/Sections.h>
 #include <Kernel/StdLib.h>
-#include <Kernel/VM/AnonymousVMObject.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/PageDirectory.h>
-#include <Kernel/VM/PhysicalRegion.h>
-#include <Kernel/VM/SharedInodeVMObject.h>
 
 extern u8 start_of_kernel_image[];
 extern u8 end_of_kernel_image[];

+ 5 - 5
Kernel/VM/MemoryManager.h → Kernel/Memory/MemoryManager.h

@@ -14,12 +14,12 @@
 #include <Kernel/Arch/x86/PageFault.h>
 #include <Kernel/Arch/x86/TrapFrame.h>
 #include <Kernel/Forward.h>
+#include <Kernel/Memory/AllocationStrategy.h>
+#include <Kernel/Memory/PhysicalPage.h>
+#include <Kernel/Memory/PhysicalRegion.h>
+#include <Kernel/Memory/Region.h>
+#include <Kernel/Memory/VMObject.h>
 #include <Kernel/SpinLock.h>
-#include <Kernel/VM/AllocationStrategy.h>
-#include <Kernel/VM/PhysicalPage.h>
-#include <Kernel/VM/PhysicalRegion.h>
-#include <Kernel/VM/Region.h>
-#include <Kernel/VM/VMObject.h>
 
 namespace Kernel {
 

+ 2 - 2
Kernel/VM/PageDirectory.cpp → Kernel/Memory/PageDirectory.cpp

@@ -6,12 +6,12 @@
 
 #include <AK/Memory.h>
 #include <AK/Singleton.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/PageDirectory.h>
 #include <Kernel/Prekernel/Prekernel.h>
 #include <Kernel/Process.h>
 #include <Kernel/Random.h>
 #include <Kernel/Sections.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/PageDirectory.h>
 
 extern u8 end_of_kernel_image[];
 

+ 2 - 2
Kernel/VM/PageDirectory.h → Kernel/Memory/PageDirectory.h

@@ -10,8 +10,8 @@
 #include <AK/RefCounted.h>
 #include <AK/RefPtr.h>
 #include <Kernel/Forward.h>
-#include <Kernel/VM/PhysicalPage.h>
-#include <Kernel/VM/RangeAllocator.h>
+#include <Kernel/Memory/PhysicalPage.h>
+#include <Kernel/Memory/RangeAllocator.h>
 
 namespace Kernel {
 

+ 0 - 0
Kernel/VM/PageFaultResponse.h → Kernel/Memory/PageFaultResponse.h


+ 2 - 2
Kernel/VM/PhysicalPage.cpp → Kernel/Memory/PhysicalPage.cpp

@@ -5,8 +5,8 @@
  */
 
 #include <Kernel/Heap/kmalloc.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/PhysicalPage.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/PhysicalPage.h>
 
 namespace Kernel {
 

+ 0 - 0
Kernel/VM/PhysicalPage.h → Kernel/Memory/PhysicalPage.h


+ 3 - 3
Kernel/VM/PhysicalRegion.cpp → Kernel/Memory/PhysicalRegion.cpp

@@ -7,10 +7,10 @@
 #include <AK/NonnullRefPtr.h>
 #include <AK/RefPtr.h>
 #include <Kernel/Assertions.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/PhysicalRegion.h>
+#include <Kernel/Memory/PhysicalZone.h>
 #include <Kernel/Random.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/PhysicalRegion.h>
-#include <Kernel/VM/PhysicalZone.h>
 
 namespace Kernel {
 

+ 2 - 2
Kernel/VM/PhysicalRegion.h → Kernel/Memory/PhysicalRegion.h

@@ -7,8 +7,8 @@
 #pragma once
 
 #include <AK/OwnPtr.h>
-#include <Kernel/VM/PhysicalPage.h>
-#include <Kernel/VM/PhysicalZone.h>
+#include <Kernel/Memory/PhysicalPage.h>
+#include <Kernel/Memory/PhysicalZone.h>
 
 namespace Kernel {
 

+ 3 - 3
Kernel/VM/PhysicalZone.cpp → Kernel/Memory/PhysicalZone.cpp

@@ -5,9 +5,9 @@
  */
 
 #include <AK/Format.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/PhysicalPage.h>
-#include <Kernel/VM/PhysicalZone.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/PhysicalPage.h>
+#include <Kernel/Memory/PhysicalZone.h>
 
 namespace Kernel {
 

+ 0 - 0
Kernel/VM/PhysicalZone.h → Kernel/Memory/PhysicalZone.h


+ 1 - 1
Kernel/VM/PrivateInodeVMObject.cpp → Kernel/Memory/PrivateInodeVMObject.cpp

@@ -5,7 +5,7 @@
  */
 
 #include <Kernel/FileSystem/Inode.h>
-#include <Kernel/VM/PrivateInodeVMObject.h>
+#include <Kernel/Memory/PrivateInodeVMObject.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/VM/PrivateInodeVMObject.h → Kernel/Memory/PrivateInodeVMObject.h

@@ -7,8 +7,8 @@
 #pragma once
 
 #include <AK/Bitmap.h>
+#include <Kernel/Memory/InodeVMObject.h>
 #include <Kernel/UnixTypes.h>
-#include <Kernel/VM/InodeVMObject.h>
 
 namespace Kernel {
 

+ 2 - 2
Kernel/VM/ProcessPagingScope.cpp → Kernel/Memory/ProcessPagingScope.cpp

@@ -5,8 +5,8 @@
  */
 
 #include <Kernel/Arch/x86/InterruptDisabler.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/ProcessPagingScope.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/ProcessPagingScope.h>
 
 namespace Kernel {
 

+ 0 - 0
Kernel/VM/ProcessPagingScope.h → Kernel/Memory/ProcessPagingScope.h


+ 2 - 2
Kernel/VM/Range.cpp → Kernel/Memory/Range.cpp

@@ -6,8 +6,8 @@
  */
 
 #include <AK/Vector.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/Range.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/Range.h>
 #include <LibC/limits.h>
 
 namespace Kernel {

+ 1 - 0
Kernel/VM/Range.h → Kernel/Memory/Range.h

@@ -7,6 +7,7 @@
 
 #pragma once
 
+#include <Kernel/KResult.h>
 #include <Kernel/VirtualAddress.h>
 
 namespace Kernel {

+ 1 - 1
Kernel/VM/RangeAllocator.cpp → Kernel/Memory/RangeAllocator.cpp

@@ -5,8 +5,8 @@
  */
 
 #include <AK/Checked.h>
+#include <Kernel/Memory/RangeAllocator.h>
 #include <Kernel/Random.h>
-#include <Kernel/VM/RangeAllocator.h>
 
 #define VM_GUARD_PAGES
 

+ 1 - 1
Kernel/VM/RangeAllocator.h → Kernel/Memory/RangeAllocator.h

@@ -8,8 +8,8 @@
 
 #include <AK/RedBlackTree.h>
 #include <AK/Traits.h>
+#include <Kernel/Memory/Range.h>
 #include <Kernel/SpinLock.h>
-#include <Kernel/VM/Range.h>
 
 namespace Kernel {
 

+ 5 - 5
Kernel/VM/Region.cpp → Kernel/Memory/Region.cpp

@@ -8,14 +8,14 @@
 #include <AK/StringView.h>
 #include <Kernel/Debug.h>
 #include <Kernel/FileSystem/Inode.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/PageDirectory.h>
+#include <Kernel/Memory/Region.h>
+#include <Kernel/Memory/SharedInodeVMObject.h>
 #include <Kernel/Panic.h>
 #include <Kernel/Process.h>
 #include <Kernel/Thread.h>
-#include <Kernel/VM/AnonymousVMObject.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/PageDirectory.h>
-#include <Kernel/VM/Region.h>
-#include <Kernel/VM/SharedInodeVMObject.h>
 
 namespace Kernel {
 

+ 2 - 2
Kernel/VM/Region.h → Kernel/Memory/Region.h

@@ -13,10 +13,10 @@
 #include <Kernel/Forward.h>
 #include <Kernel/Heap/SlabAllocator.h>
 #include <Kernel/KString.h>
+#include <Kernel/Memory/PageFaultResponse.h>
+#include <Kernel/Memory/RangeAllocator.h>
 #include <Kernel/Sections.h>
 #include <Kernel/UnixTypes.h>
-#include <Kernel/VM/PageFaultResponse.h>
-#include <Kernel/VM/RangeAllocator.h>
 
 namespace Kernel {
 

+ 2 - 2
Kernel/VM/RingBuffer.cpp → Kernel/Memory/RingBuffer.cpp

@@ -4,9 +4,9 @@
  * SPDX-License-Identifier: BSD-2-Clause
  */
 
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/RingBuffer.h>
 #include <Kernel/UserOrKernelBuffer.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/RingBuffer.h>
 
 namespace Kernel {
 

+ 0 - 0
Kernel/VM/RingBuffer.h → Kernel/Memory/RingBuffer.h


+ 1 - 1
Kernel/VM/ScatterGatherList.cpp → Kernel/Memory/ScatterGatherList.cpp

@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: BSD-2-Clause
  */
 
-#include <Kernel/VM/ScatterGatherList.h>
+#include <Kernel/Memory/ScatterGatherList.h>
 
 namespace Kernel {
 

+ 2 - 2
Kernel/VM/ScatterGatherList.h → Kernel/Memory/ScatterGatherList.h

@@ -8,9 +8,9 @@
 
 #include <AK/Vector.h>
 #include <Kernel/Devices/BlockDevice.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/PhysicalAddress.h>
-#include <Kernel/VM/AnonymousVMObject.h>
-#include <Kernel/VM/MemoryManager.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/VM/SharedInodeVMObject.cpp → Kernel/Memory/SharedInodeVMObject.cpp

@@ -5,7 +5,7 @@
  */
 
 #include <Kernel/FileSystem/Inode.h>
-#include <Kernel/VM/SharedInodeVMObject.h>
+#include <Kernel/Memory/SharedInodeVMObject.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/VM/SharedInodeVMObject.h → Kernel/Memory/SharedInodeVMObject.h

@@ -7,8 +7,8 @@
 #pragma once
 
 #include <AK/Bitmap.h>
+#include <Kernel/Memory/InodeVMObject.h>
 #include <Kernel/UnixTypes.h>
-#include <Kernel/VM/InodeVMObject.h>
 
 namespace Kernel {
 

+ 4 - 4
Kernel/VM/Space.cpp → Kernel/Memory/Space.cpp

@@ -5,13 +5,13 @@
  * SPDX-License-Identifier: BSD-2-Clause
  */
 
+#include <Kernel/Memory/AnonymousVMObject.h>
+#include <Kernel/Memory/InodeVMObject.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/Space.h>
 #include <Kernel/PerformanceManager.h>
 #include <Kernel/Process.h>
 #include <Kernel/SpinLock.h>
-#include <Kernel/VM/AnonymousVMObject.h>
-#include <Kernel/VM/InodeVMObject.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/Space.h>
 
 namespace Kernel {
 

+ 2 - 2
Kernel/VM/Space.h → Kernel/Memory/Space.h

@@ -10,9 +10,9 @@
 #include <AK/RedBlackTree.h>
 #include <AK/Vector.h>
 #include <AK/WeakPtr.h>
+#include <Kernel/Memory/AllocationStrategy.h>
+#include <Kernel/Memory/PageDirectory.h>
 #include <Kernel/UnixTypes.h>
-#include <Kernel/VM/AllocationStrategy.h>
-#include <Kernel/VM/PageDirectory.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/VM/TypedMapping.h → Kernel/Memory/TypedMapping.h

@@ -7,7 +7,7 @@
 #pragma once
 
 #include <AK/StringView.h>
-#include <Kernel/VM/MemoryManager.h>
+#include <Kernel/Memory/MemoryManager.h>
 
 namespace Kernel {
 

+ 2 - 2
Kernel/VM/VMObject.cpp → Kernel/Memory/VMObject.cpp

@@ -4,8 +4,8 @@
  * SPDX-License-Identifier: BSD-2-Clause
  */
 
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/VMObject.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/VMObject.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/VM/VMObject.h → Kernel/Memory/VMObject.h

@@ -14,8 +14,8 @@
 #include <AK/Vector.h>
 #include <AK/Weakable.h>
 #include <Kernel/Forward.h>
+#include <Kernel/Memory/Region.h>
 #include <Kernel/Mutex.h>
-#include <Kernel/VM/Region.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/Net/NetworkingManagement.cpp

@@ -7,6 +7,7 @@
 #include <AK/Singleton.h>
 #include <Kernel/CommandLine.h>
 #include <Kernel/IO.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
 #include <Kernel/Multiboot.h>
 #include <Kernel/Net/E1000ENetworkAdapter.h>
 #include <Kernel/Net/E1000NetworkAdapter.h>
@@ -16,7 +17,6 @@
 #include <Kernel/Net/RTL8139NetworkAdapter.h>
 #include <Kernel/Net/RTL8168NetworkAdapter.h>
 #include <Kernel/Sections.h>
-#include <Kernel/VM/AnonymousVMObject.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/Net/NetworkingManagement.h

@@ -12,7 +12,7 @@
 #include <AK/NonnullRefPtrVector.h>
 #include <AK/Types.h>
 #include <Kernel/Bus/PCI/Definitions.h>
-#include <Kernel/VM/Region.h>
+#include <Kernel/Memory/Region.h>
 
 namespace Kernel {
 

+ 3 - 3
Kernel/Process.cpp

@@ -21,6 +21,9 @@
 #include <Kernel/FileSystem/VirtualFileSystem.h>
 #include <Kernel/KBufferBuilder.h>
 #include <Kernel/KSyms.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
+#include <Kernel/Memory/PageDirectory.h>
+#include <Kernel/Memory/SharedInodeVMObject.h>
 #include <Kernel/Module.h>
 #include <Kernel/PerformanceEventBuffer.h>
 #include <Kernel/PerformanceManager.h>
@@ -32,9 +35,6 @@
 #include <Kernel/TTY/TTY.h>
 #include <Kernel/Thread.h>
 #include <Kernel/ThreadTracer.h>
-#include <Kernel/VM/AnonymousVMObject.h>
-#include <Kernel/VM/PageDirectory.h>
-#include <Kernel/VM/SharedInodeVMObject.h>
 #include <LibC/errno_numbers.h>
 #include <LibC/limits.h>
 

+ 1 - 1
Kernel/Process.h

@@ -20,6 +20,7 @@
 #include <Kernel/FileSystem/InodeMetadata.h>
 #include <Kernel/Forward.h>
 #include <Kernel/FutexQueue.h>
+#include <Kernel/Memory/Space.h>
 #include <Kernel/Mutex.h>
 #include <Kernel/PerformanceEventBuffer.h>
 #include <Kernel/ProcessGroup.h>
@@ -27,7 +28,6 @@
 #include <Kernel/Thread.h>
 #include <Kernel/UnixTypes.h>
 #include <Kernel/UnveilNode.h>
-#include <Kernel/VM/Space.h>
 #include <LibC/elf.h>
 #include <LibC/signal_numbers.h>
 

+ 2 - 2
Kernel/ProcessSpecificExposed.cpp

@@ -10,9 +10,9 @@
 #include <Kernel/Arch/x86/InterruptDisabler.h>
 #include <Kernel/FileSystem/Custody.h>
 #include <Kernel/KBufferBuilder.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/ProcessExposed.h>
-#include <Kernel/VM/AnonymousVMObject.h>
-#include <Kernel/VM/MemoryManager.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/StdLib.cpp

@@ -10,8 +10,8 @@
 #include <AK/Types.h>
 #include <Kernel/Arch/x86/SmapDisabler.h>
 #include <Kernel/Heap/kmalloc.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/StdLib.h>
-#include <Kernel/VM/MemoryManager.h>
 
 String copy_string_from_user(const char* user_str, size_t user_str_size)
 {

+ 1 - 1
Kernel/Storage/AHCIController.cpp

@@ -8,9 +8,9 @@
 #include <AK/OwnPtr.h>
 #include <AK/RefPtr.h>
 #include <AK/Types.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/Storage/AHCIController.h>
 #include <Kernel/Storage/SATADiskDevice.h>
-#include <Kernel/VM/MemoryManager.h>
 
 namespace Kernel {
 

+ 3 - 3
Kernel/Storage/AHCIPort.cpp

@@ -8,13 +8,13 @@
 // please look at Documentation/Kernel/AHCILocking.md
 
 #include <AK/Atomic.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/ScatterGatherList.h>
+#include <Kernel/Memory/TypedMapping.h>
 #include <Kernel/SpinLock.h>
 #include <Kernel/Storage/AHCIPort.h>
 #include <Kernel/Storage/ATA.h>
 #include <Kernel/Storage/SATADiskDevice.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/ScatterGatherList.h>
-#include <Kernel/VM/TypedMapping.h>
 #include <Kernel/WorkQueue.h>
 
 namespace Kernel {

+ 3 - 3
Kernel/Storage/AHCIPort.h

@@ -11,6 +11,9 @@
 #include <Kernel/Devices/Device.h>
 #include <Kernel/IO.h>
 #include <Kernel/Interrupts/IRQHandler.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
+#include <Kernel/Memory/PhysicalPage.h>
+#include <Kernel/Memory/ScatterGatherList.h>
 #include <Kernel/Mutex.h>
 #include <Kernel/PhysicalAddress.h>
 #include <Kernel/Random.h>
@@ -19,9 +22,6 @@
 #include <Kernel/Storage/AHCI.h>
 #include <Kernel/Storage/AHCIPortHandler.h>
 #include <Kernel/Storage/StorageDevice.h>
-#include <Kernel/VM/AnonymousVMObject.h>
-#include <Kernel/VM/PhysicalPage.h>
-#include <Kernel/VM/ScatterGatherList.h>
 #include <Kernel/WaitQueue.h>
 
 namespace Kernel {

+ 1 - 1
Kernel/Storage/AHCIPortHandler.h

@@ -10,6 +10,7 @@
 #include <Kernel/Devices/Device.h>
 #include <Kernel/IO.h>
 #include <Kernel/Interrupts/IRQHandler.h>
+#include <Kernel/Memory/PhysicalPage.h>
 #include <Kernel/Mutex.h>
 #include <Kernel/PhysicalAddress.h>
 #include <Kernel/Random.h>
@@ -17,7 +18,6 @@
 #include <Kernel/Storage/AHCIController.h>
 #include <Kernel/Storage/AHCIPort.h>
 #include <Kernel/Storage/StorageDevice.h>
-#include <Kernel/VM/PhysicalPage.h>
 #include <Kernel/WaitQueue.h>
 
 namespace Kernel {

+ 1 - 1
Kernel/Storage/IDEChannel.cpp

@@ -8,13 +8,13 @@
 #include <AK/Singleton.h>
 #include <AK/StringView.h>
 #include <Kernel/IO.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/Process.h>
 #include <Kernel/Sections.h>
 #include <Kernel/Storage/ATA.h>
 #include <Kernel/Storage/IDEChannel.h>
 #include <Kernel/Storage/IDEController.h>
 #include <Kernel/Storage/PATADiskDevice.h>
-#include <Kernel/VM/MemoryManager.h>
 #include <Kernel/WorkQueue.h>
 
 namespace Kernel {

+ 1 - 1
Kernel/Storage/IDEChannel.h

@@ -21,11 +21,11 @@
 #include <Kernel/Devices/Device.h>
 #include <Kernel/IO.h>
 #include <Kernel/Interrupts/IRQHandler.h>
+#include <Kernel/Memory/PhysicalPage.h>
 #include <Kernel/Mutex.h>
 #include <Kernel/PhysicalAddress.h>
 #include <Kernel/Random.h>
 #include <Kernel/Storage/StorageDevice.h>
-#include <Kernel/VM/PhysicalPage.h>
 #include <Kernel/WaitQueue.h>
 
 namespace Kernel {

+ 1 - 1
Kernel/Storage/StorageController.h

@@ -12,10 +12,10 @@
 #include <Kernel/Bus/PCI/DeviceController.h>
 #include <Kernel/Devices/Device.h>
 #include <Kernel/IO.h>
+#include <Kernel/Memory/PhysicalPage.h>
 #include <Kernel/Mutex.h>
 #include <Kernel/PhysicalAddress.h>
 #include <Kernel/Random.h>
-#include <Kernel/VM/PhysicalPage.h>
 #include <Kernel/WaitQueue.h>
 
 namespace Kernel {

+ 1 - 1
Kernel/Syscall.cpp

@@ -7,11 +7,11 @@
 #include <Kernel/API/Syscall.h>
 #include <Kernel/Arch/x86/Interrupts.h>
 #include <Kernel/Arch/x86/TrapFrame.h>
+#include <Kernel/Memory/MemoryManager.h>
 #include <Kernel/Panic.h>
 #include <Kernel/Process.h>
 #include <Kernel/Sections.h>
 #include <Kernel/ThreadTracer.h>
-#include <Kernel/VM/MemoryManager.h>
 
 namespace Kernel {
 

+ 1 - 1
Kernel/Syscalls/anon_create.cpp

@@ -6,8 +6,8 @@
 
 #include <Kernel/FileSystem/AnonymousFile.h>
 #include <Kernel/FileSystem/FileDescription.h>
+#include <Kernel/Memory/AnonymousVMObject.h>
 #include <Kernel/Process.h>
-#include <Kernel/VM/AnonymousVMObject.h>
 
 namespace Kernel {
 

+ 5 - 5
Kernel/Syscalls/execve.cpp

@@ -10,16 +10,16 @@
 #include <Kernel/Debug.h>
 #include <Kernel/FileSystem/Custody.h>
 #include <Kernel/FileSystem/FileDescription.h>
+#include <Kernel/Memory/AllocationStrategy.h>
+#include <Kernel/Memory/MemoryManager.h>
+#include <Kernel/Memory/PageDirectory.h>
+#include <Kernel/Memory/Region.h>
+#include <Kernel/Memory/SharedInodeVMObject.h>
 #include <Kernel/Panic.h>
 #include <Kernel/PerformanceManager.h>
 #include <Kernel/Process.h>
 #include <Kernel/Random.h>
 #include <Kernel/Time/TimeManagement.h>
-#include <Kernel/VM/AllocationStrategy.h>
-#include <Kernel/VM/MemoryManager.h>
-#include <Kernel/VM/PageDirectory.h>
-#include <Kernel/VM/Region.h>
-#include <Kernel/VM/SharedInodeVMObject.h>
 #include <LibC/limits.h>
 #include <LibELF/AuxiliaryVector.h>
 #include <LibELF/Image.h>

+ 1 - 1
Kernel/Syscalls/fork.cpp

@@ -7,9 +7,9 @@
 #include <Kernel/Debug.h>
 #include <Kernel/FileSystem/Custody.h>
 #include <Kernel/FileSystem/FileDescription.h>
+#include <Kernel/Memory/Region.h>
 #include <Kernel/PerformanceManager.h>
 #include <Kernel/Process.h>
-#include <Kernel/VM/Region.h>
 
 namespace Kernel {
 

Some files were not shown because too many files changed in this diff