Rev 205 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 205 | Rev 227 | ||
---|---|---|---|
Line 64... | Line 64... | ||
64 | if (!m->ptl0) { |
64 | if (!m->ptl0) { |
65 | pte_t *src_ptl0, *dst_ptl0; |
65 | pte_t *src_ptl0, *dst_ptl0; |
66 | 66 | ||
67 | src_ptl0 = (pte_t *) PA2KA((__address) GET_PTL0_ADDRESS()); |
67 | src_ptl0 = (pte_t *) PA2KA((__address) GET_PTL0_ADDRESS()); |
68 | dst_ptl0 = (pte_t *) frame_alloc(FRAME_KA | FRAME_PANIC); |
68 | dst_ptl0 = (pte_t *) frame_alloc(FRAME_KA | FRAME_PANIC); |
- | 69 | ||
- | 70 | /* TODO: in theory, it should be only necessary to copy kernel address space... */ |
|
69 | memcpy((void *)PA2KA((__address) dst_ptl0), (void *)GET_PTL0_ADDRESS() , PAGE_SIZE); |
71 | memcpy((void *)PA2KA((__address) dst_ptl0), (void *)GET_PTL0_ADDRESS() , PAGE_SIZE); |
- | 72 | ||
70 | m->ptl0 = (pte_t *) KA2PA((__address) dst_ptl0); |
73 | m->ptl0 = (pte_t *) KA2PA((__address) dst_ptl0); |
71 | } |
74 | } |
72 | } |
75 | } |
73 | 76 | ||
74 | return m; |
77 | return m; |