Subversion Repositories HelenOS-historic

Rev

Rev 167 | Rev 205 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 167 Rev 195
Line 34... Line 34...
34
#include <arch/mm/page.h>
34
#include <arch/mm/page.h>
35
#include <arch/interrupt.h>
35
#include <arch/interrupt.h>
36
#include <arch/asm.h>
36
#include <arch/asm.h>
37
#include <synch/spinlock.h>
37
#include <synch/spinlock.h>
38
#include <debug.h>
38
#include <debug.h>
-
 
39
#include <memstr.h>
39
 
40
 
40
__address bootstrap_dba;
41
__address bootstrap_dba;
41
 
42
 
42
void page_arch_init(void)
43
void page_arch_init(void)
43
{
44
{
Line 69... Line 70...
69
         * already-initialized paging information from the bootstrap
70
         * already-initialized paging information from the bootstrap
70
         * processor and adjusts it to fulfill its needs.
71
         * processor and adjusts it to fulfill its needs.
71
         */
72
         */
72
 
73
 
73
        dba = frame_alloc(FRAME_KA | FRAME_PANIC);
74
        dba = frame_alloc(FRAME_KA | FRAME_PANIC);
74
        memcopy(bootstrap_dba, dba, PAGE_SIZE);
75
        memcopy((void *)dba,(void *)bootstrap_dba , PAGE_SIZE); //swaped
75
        write_cr3(KA2PA(dba));
76
        write_cr3(KA2PA(dba));
76
    }
77
    }
77
 
78
 
78
    paging_on();
79
    paging_on();
79
}
80
}