diff options
| author | Miguel <m.i@gmx.at> | 2018-09-12 02:10:11 +0200 |
|---|---|---|
| committer | Miguel <m.i@gmx.at> | 2018-09-12 02:10:11 +0200 |
| commit | a3ee159ebfd2d088432e386e8809840784f697e7 (patch) | |
| tree | 9ecfc506bb65ec982aae47f161afa1777359d3f7 /asm/asm_x86.h | |
| parent | c9351caacd49c8442cc586f9e53a2dcc49a004aa (diff) | |
working on smp scheduler
Diffstat (limited to 'asm/asm_x86.h')
| -rw-r--r-- | asm/asm_x86.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/asm/asm_x86.h b/asm/asm_x86.h index 529a6c2..ec9ebd0 100644 --- a/asm/asm_x86.h +++ b/asm/asm_x86.h @@ -91,6 +91,9 @@ void x86_set_cr(uint8_t num, uint32_t value); /** Set the address of the page directory. This is required **before** enabling paging */ static inline void x86_set_page_directory(uint32_t pdir_addr) {x86_set_cr(3,pdir_addr);} +/** Get the address of the page directory. */ +static inline uint32_t x86_get_page_directory() {return x86_get_cr(3);} + /** Enable paging */ static inline void x86_paging_enable() {x86_set_cr(0,x86_get_cr(0)| 0x80000000);} |
