summaryrefslogtreecommitdiff
path: root/mmu.h
diff options
context:
space:
mode:
authorFrans Kaashoek <[email protected]>2011-09-01 10:25:20 -0400
committerFrans Kaashoek <[email protected]>2011-09-01 10:25:20 -0400
commite25b74ca8069e340c3f2c267d09beed6d9328250 (patch)
tree81489f3133ad678a0ccd9ff4e0afcffd84cc6173 /mmu.h
parent15997d58497f4c716c227787acf9591439e5fe9c (diff)
downloadxv6-labs-e25b74ca8069e340c3f2c267d09beed6d9328250.tar.gz
xv6-labs-e25b74ca8069e340c3f2c267d09beed6d9328250.tar.bz2
xv6-labs-e25b74ca8069e340c3f2c267d09beed6d9328250.zip
Fix layout issues for printed version
Diffstat (limited to 'mmu.h')
-rw-r--r--mmu.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/mmu.h b/mmu.h
index 0da30e7..5c9ab60 100644
--- a/mmu.h
+++ b/mmu.h
@@ -118,13 +118,13 @@ struct segdesc {
#define PGADDR(d, t, o) ((uint)((d) << PDXSHIFT | (t) << PTXSHIFT | (o)))
// Page directory and page table constants.
-#define NPDENTRIES 1024 // page directory entries per page directory
-#define NPTENTRIES 1024 // page table entries per page table
-#define PGSIZE 4096 // bytes mapped by a page
+#define NPDENTRIES 1024 // # directory entries per page directory
+#define NPTENTRIES 1024 // # PTEs per page table
+#define PGSIZE 4096 // bytes mapped by a page
-#define PGSHIFT 12 // log2(PGSIZE)
-#define PTXSHIFT 12 // offset of PTX in a linear address
-#define PDXSHIFT 22 // offset of PDX in a linear address
+#define PGSHIFT 12 // log2(PGSIZE)
+#define PTXSHIFT 12 // offset of PTX in a linear address
+#define PDXSHIFT 22 // offset of PDX in a linear address
#define PGROUNDUP(sz) (((sz)+PGSIZE-1) & ~(PGSIZE-1))
#define PGROUNDDOWN(a) (((a)) & ~(PGSIZE-1))