summaryrefslogtreecommitdiff
path: root/Kernel/Arch/i386/CPU.h
diff options
context:
space:
mode:
authorTom <tomut@yahoo.com>2020-06-28 16:04:35 -0600
committerAndreas Kling <kling@serenityos.org>2020-07-01 12:07:01 +0200
commit2a38cc9a1267ec6c6e859a0fe72f02a5a145fa9b (patch)
treecaac07e683992aca0531509ae3ccd2b03dfec734 /Kernel/Arch/i386/CPU.h
parentd249b5df8f03949040f5a4ddfe5b2f7b9b4b1740 (diff)
downloadserenity-2a38cc9a1267ec6c6e859a0fe72f02a5a145fa9b.zip
Kernel: Add a quickmap region for each processor
Threads need to be able to concurrently quickmap things.
Diffstat (limited to 'Kernel/Arch/i386/CPU.h')
-rw-r--r--Kernel/Arch/i386/CPU.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/Kernel/Arch/i386/CPU.h b/Kernel/Arch/i386/CPU.h
index e1840e1a0c..0e2df7c357 100644
--- a/Kernel/Arch/i386/CPU.h
+++ b/Kernel/Arch/i386/CPU.h
@@ -611,6 +611,7 @@ struct TrapFrame;
#define GDT_SELECTOR_TSS 0x38
class ProcessorInfo;
+struct MemoryManagerData;
class Processor {
Processor* m_self; // must be first field (%fs offset 0x0)
@@ -626,6 +627,7 @@ class Processor {
static FPUState s_clean_fpu_state;
ProcessorInfo* m_info;
+ MemoryManagerData* m_mm_data;
Thread* m_current_thread;
Thread* m_idle_thread;
@@ -668,6 +670,16 @@ public:
return get_fs() == GDT_SELECTOR_PROC && read_fs_u32(0) != 0;
}
+ ALWAYS_INLINE void set_mm_data(MemoryManagerData& mm_data)
+ {
+ m_mm_data = &mm_data;
+ }
+
+ ALWAYS_INLINE MemoryManagerData& get_mm_data() const
+ {
+ return *m_mm_data;
+ }
+
ALWAYS_INLINE Thread* idle_thread() const
{
return m_idle_thread;