projects
/
pintos-anon
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
828d300
)
Activate the base page directory if pagedir_activate() is passed a
author
Ben Pfaff
<blp@cs.stanford.edu>
Thu, 2 Sep 2004 20:59:40 +0000
(20:59 +0000)
committer
Ben Pfaff
<blp@cs.stanford.edu>
Thu, 2 Sep 2004 20:59:40 +0000
(20:59 +0000)
null pointer.
src/threads/paging.c
patch
|
blob
|
history
diff --git
a/src/threads/paging.c
b/src/threads/paging.c
index 587813cb3c3707071316d9926979873a98d8f91e..2ae78c3c456cff3a63ae1ddf913db847864e2965 100644
(file)
--- a/
src/threads/paging.c
+++ b/
src/threads/paging.c
@@
-220,5
+220,7
@@
pagedir_next (uint32_t *pd, void **upage)
void
pagedir_activate (uint32_t *pd)
{
+ if (pd == NULL)
+ pd = base_page_dir;
asm volatile ("movl %0,%%cr3" :: "r" (vtop (pd)));
}