]> rtime.felk.cvut.cz Git - l4.git/blobdiff - kernel/fiasco/src/kern/ia32/space-ia32.cpp
Update
[l4.git] / kernel / fiasco / src / kern / ia32 / space-ia32.cpp
index eeff4cac5a96bbd619ce89898beb245ebbc26405..fe328e2601b979fbbd1b156ff82db4030511a0c8 100644 (file)
@@ -57,10 +57,13 @@ Space::Ldt::~Ldt()
                                   reinterpret_cast<void*>(addr()));
 }
 
-
-IMPLEMENT inline NEEDS["cpu.h", "globals.h"]
+IMPLEMENT_OVERRIDE inline NEEDS["cpu.h", "globals.h"]
 void
-Space::switchin_ldt() const
+Space::switchin_context(Space *from, unsigned)
 {
-  Cpu::cpus.cpu(current_cpu()).enable_ldt(_ldt.addr(), _ldt.size());
+  if (this != from)
+    {
+      Mem_space::switchin_context(from);
+      Cpu::cpus.cpu(current_cpu()).enable_ldt(_ldt.addr(), _ldt.size());
+    }
 }