Rev 684 | Rev 724 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
| Rev 684 | Rev 703 | ||
|---|---|---|---|
| Line 46... | Line 46... | ||
| 46 | #include <mm/heap.h> |
46 | #include <mm/heap.h> |
| 47 | #include <mm/frame.h> |
47 | #include <mm/frame.h> |
| 48 | #include <mm/page.h> |
48 | #include <mm/page.h> |
| 49 | #include <genarch/mm/page_pt.h> |
49 | #include <genarch/mm/page_pt.h> |
| 50 | #include <mm/tlb.h> |
50 | #include <mm/tlb.h> |
| 51 | #include <mm/vm.h> |
51 | #include <mm/as.h> |
| 52 | #include <synch/waitq.h> |
52 | #include <synch/waitq.h> |
| 53 | #include <arch/arch.h> |
53 | #include <arch/arch.h> |
| 54 | #include <arch.h> |
54 | #include <arch.h> |
| 55 | #include <arch/faddr.h> |
55 | #include <arch/faddr.h> |
| 56 | #include <typedefs.h> |
56 | #include <typedefs.h> |
| Line 133... | Line 133... | ||
| 133 | * Second part of main_bsp(). |
133 | * Second part of main_bsp(). |
| 134 | * |
134 | * |
| 135 | */ |
135 | */ |
| 136 | void main_bsp_separated_stack(void) |
136 | void main_bsp_separated_stack(void) |
| 137 | { |
137 | { |
| 138 | vm_t *m; |
138 | as_t *as; |
| 139 | task_t *k; |
139 | task_t *k; |
| 140 | thread_t *t; |
140 | thread_t *t; |
| 141 | 141 | ||
| 142 | the_initialize(THE); |
142 | the_initialize(THE); |
| 143 | 143 | ||
| Line 181... | Line 181... | ||
| 181 | 181 | ||
| 182 | if (config.init_size > 0) |
182 | if (config.init_size > 0) |
| 183 | printf("config.init_addr=%X, config.init_size=%d\n", config.init_addr, config.init_size); |
183 | printf("config.init_addr=%X, config.init_size=%d\n", config.init_addr, config.init_size); |
| 184 | 184 | ||
| 185 | /* |
185 | /* |
| 186 | * Create kernel vm mapping. |
186 | * Create kernel address space. |
| 187 | */ |
187 | */ |
| 188 | m = vm_create(GET_PTL0_ADDRESS()); |
188 | as = as_create(GET_PTL0_ADDRESS()); |
| 189 | if (!m) |
189 | if (!as) |
| 190 | panic("can't create kernel vm address space\n"); |
190 | panic("can't create kernel address space\n"); |
| 191 | 191 | ||
| 192 | /* |
192 | /* |
| 193 | * Create kernel task. |
193 | * Create kernel task. |
| 194 | */ |
194 | */ |
| 195 | k = task_create(m); |
195 | k = task_create(as); |
| 196 | if (!k) |
196 | if (!k) |
| 197 | panic("can't create kernel task\n"); |
197 | panic("can't create kernel task\n"); |
| 198 | 198 | ||
| 199 | /* |
199 | /* |
| 200 | * Create the first thread. |
200 | * Create the first thread. |