diff options
Diffstat (limited to 'src/core/paging.hpp')
| -rw-r--r-- | src/core/paging.hpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/core/paging.hpp b/src/core/paging.hpp index 5817765..a3c2fec 100644 --- a/src/core/paging.hpp +++ b/src/core/paging.hpp @@ -25,11 +25,19 @@ paging_allocate_addr(kpages[0],((u64)(addr))+i,((u64)(addr))+i,PAGING_OPT_P|PAGING_OPT_RW,kvar_kernel_vma); \ }} + +#define PAGING_MAP2(addr,phy) paging_allocate_addr(kpages[0],(u64)(addr),(u64)(phy),PAGING_OPT_P|PAGING_OPT_RW,kvar_kernel_vma) +#define PAGING_MAP2_RANGE(addr, phy, n) { \ + for(u64 i=0;i<(n);i++){ \ + paging_allocate_addr(kpages[0],((u64)(addr))+i,((u64)(phy))+i,PAGING_OPT_P|PAGING_OPT_RW,kvar_kernel_vma); \ +}} + /// @brief All PAE table structures are allocated here extern u64 kpages[MAX_TABLES][512]; /// CF boucane.hpp extern u64 kvar_kernel_vma,kvar_stack_pma,kvar_userspace_pma; +extern void (*printk)(char *str,...); /** * Setup and enable PAE paging |
