aboutsummaryrefslogtreecommitdiff
path: root/src/kernel/dev/v86.c
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2015-03-09 23:34:46 +0100
committerAlex Auvolat <alex@adnab.me>2015-03-09 23:34:46 +0100
commit011d99fc5f90b1e2b51f7b96688bdcbbb944e104 (patch)
tree20a2a03ef168a09185b77fbea04adfeefc1d99bf /src/kernel/dev/v86.c
parente499d74b6f0b57f9a11486c346dbc335e4f8433d (diff)
downloadkogata-011d99fc5f90b1e2b51f7b96688bdcbbb944e104.tar.gz
kogata-011d99fc5f90b1e2b51f7b96688bdcbbb944e104.zip
VESA mode setting ; displays kogata logo!
Diffstat (limited to 'src/kernel/dev/v86.c')
-rw-r--r--src/kernel/dev/v86.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/kernel/dev/v86.c b/src/kernel/dev/v86.c
index 183b791..db84a4f 100644
--- a/src/kernel/dev/v86.c
+++ b/src/kernel/dev/v86.c
@@ -48,6 +48,9 @@ bool v86_begin_session() {
pd_map_page(addr, (uint32_t)addr / PAGE_SIZE, true);
}
pd_map_page(0, 0, true);
+ } else {
+ v86_prev_pagedir = get_current_pagedir();
+ switch_pagedir(v86_pagedir);
}
if (v86_thread == 0) {
@@ -70,6 +73,7 @@ bool v86_begin_session() {
void v86_end_session() {
switch_pagedir(v86_prev_pagedir);
+
v86_prev_pagedir = 0;
v86_caller_thread = 0;