Kernel: Move i386.{cpp,h} => Arch/i386/CPU.{cpp,h}

There's a ton of work that would need to be done before we could spin up on
another architecture, but let's at least try to separate things out a bit.
This commit is contained in:
Andreas Kling 2019-06-07 20:02:01 +02:00
parent 5bce004d84
commit 736092a087
Notes: sideshowbarker 2024-07-19 13:40:46 +09:00
20 changed files with 20 additions and 21 deletions

View file

@ -1,10 +1,10 @@
#include "i386.h"
#include "Assertions.h"
#include "IRQHandler.h"
#include "PIC.h"
#include "Process.h"
#include "Scheduler.h"
#include <AK/Types.h>
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/KSyms.h>
#include <Kernel/VM/MemoryManager.h>

View file

@ -1,6 +1,6 @@
#pragma once
#include <Kernel/i386.h>
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/kstdio.h>
#ifdef DEBUG

View file

@ -1,8 +1,8 @@
#include "IO.h"
#include "PIC.h"
#include "i386.h"
#include <AK/Assertions.h>
#include <AK/Types.h>
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/Devices/KeyboardDevice.h>
#include <Kernel/TTY/VirtualConsole.h>

View file

@ -1,6 +1,6 @@
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/Devices/PCSpeaker.h>
#include <Kernel/IO.h>
#include <Kernel/i386.h>
#include <Kernel/i8253.h>
void PCSpeaker::tone_on(int frequency)

View file

@ -1,6 +1,6 @@
#include "DiskBackedFileSystem.h"
#include "i386.h"
#include <AK/InlineLRUCache.h>
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/Process.h>
//#define DBFS_DEBUG

View file

@ -4,8 +4,8 @@
#include "Process.h"
#include "Scheduler.h"
#include "StdLib.h"
#include "i386.h"
#include <AK/StringBuilder.h>
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/FileSystem/Custody.h>
#include <Kernel/FileSystem/FileDescription.h>
#include <Kernel/FileSystem/VirtualFileSystem.h>

View file

@ -1,6 +1,6 @@
#include "IRQHandler.h"
#include "PIC.h"
#include "i386.h"
#include <Kernel/Arch/i386/CPU.h>
IRQHandler::IRQHandler(byte irq)
: m_irq_number(irq)

View file

@ -2,9 +2,9 @@
#include <AK/Assertions.h>
#include <AK/Types.h>
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/KSyms.h>
#include <Kernel/Scheduler.h>
#include <Kernel/i386.h>
class Thread;
extern Thread* current;

View file

@ -4,7 +4,7 @@ KERNEL_OBJS = \
init.o \
kmalloc.o \
StdLib.o \
i386.o \
Arch/i386/CPU.o \
Process.o \
Thread.o \
i8253.o \

View file

@ -1,8 +1,8 @@
#include "PIC.h"
#include "Assertions.h"
#include "IO.h"
#include "i386.h"
#include <AK/Types.h>
#include <Kernel/Arch/i386/CPU.h>
// The slave 8259 is connected to the master's IRQ2 line.
// This is really only to enhance clarity.

View file

@ -4,6 +4,7 @@
#include <AK/StringBuilder.h>
#include <AK/Time.h>
#include <AK/Types.h>
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/Devices/NullDevice.h>
#include <Kernel/FileSystem/Custody.h>
#include <Kernel/FileSystem/FIFO.h>
@ -21,7 +22,6 @@
#include <Kernel/Syscall.h>
#include <Kernel/TTY/MasterPTY.h>
#include <Kernel/VM/MemoryManager.h>
#include <Kernel/i386.h>
#include <Kernel/i8253.h>
#include <Kernel/kmalloc.h>
#include <LibC/errno_numbers.h>
@ -1441,8 +1441,7 @@ pid_t Process::sys$waitpid(pid_t waitee, int* wstatus, int options)
return current->m_waitee_pid;
}
enum class KernelMemoryCheckResult
{
enum class KernelMemoryCheckResult {
NotInsideKernelMemory,
AccessGranted,
AccessDenied

View file

@ -1,9 +1,9 @@
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/Console.h>
#include <Kernel/Process.h>
#include <Kernel/ProcessTracer.h>
#include <Kernel/Scheduler.h>
#include <Kernel/Syscall.h>
#include <Kernel/i386.h>
extern "C" void syscall_trap_entry(RegisterDump&);
extern "C" void syscall_trap_handler();

View file

@ -1,9 +1,9 @@
#include "VirtualConsole.h"
#include "IO.h"
#include "StdLib.h"
#include "i386.h"
#include "kmalloc.h"
#include <AK/AKString.h>
#include <Kernel/Arch/i386/CPU.h>
static byte* s_vga_buffer;
static VirtualConsole* s_consoles[6];

View file

@ -5,11 +5,11 @@
#include <AK/OwnPtr.h>
#include <AK/RetainPtr.h>
#include <AK/Vector.h>
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/KResult.h>
#include <Kernel/UnixTypes.h>
#include <Kernel/VM/Region.h>
#include <Kernel/VirtualAddress.h>
#include <Kernel/i386.h>
class Alarm;
class FileDescription;

View file

@ -1,9 +1,9 @@
#include "CMOS.h"
#include "Process.h"
#include "StdLib.h"
#include "i386.h"
#include <AK/Assertions.h>
#include <AK/kstdio.h>
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/FileSystem/Inode.h>
#include <Kernel/VM/MemoryManager.h>

View file

@ -1,6 +1,5 @@
#pragma once
#include "i386.h"
#include <AK/AKString.h>
#include <AK/Badge.h>
#include <AK/Bitmap.h>
@ -11,6 +10,7 @@
#include <AK/Types.h>
#include <AK/Vector.h>
#include <AK/Weakable.h>
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/FileSystem/InodeIdentifier.h>
#include <Kernel/VM/PhysicalPage.h>
#include <Kernel/VM/Region.h>

View file

@ -2,7 +2,7 @@
#include "IO.h"
#include "PIC.h"
#include "Scheduler.h"
#include "i386.h"
#include <Kernel/Arch/i386/CPU.h>
#define IRQ_TIMER 0

View file

@ -3,10 +3,10 @@
#include "Process.h"
#include "RTC.h"
#include "Scheduler.h"
#include "i386.h"
#include "i8253.h"
#include "kmalloc.h"
#include <AK/Types.h>
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/Devices/BXVGADevice.h>
#include <Kernel/Devices/DebugLogDevice.h>
#include <Kernel/Devices/DiskPartition.h>

View file

@ -5,11 +5,11 @@
#include <AK/Assertions.h>
#include <AK/Types.h>
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/KSyms.h>
#include <Kernel/Process.h>
#include <Kernel/Scheduler.h>
#include <Kernel/StdLib.h>
#include <Kernel/i386.h>
#include <Kernel/kmalloc.h>
#define SANITIZE_KMALLOC