| 896 | } |
| 897 | |
| 898 | static void |
| 899 | init_proc0(vm_offset_t kstack) |
| 900 | { |
| 901 | struct pcpu *pcpup = &__pcpu[0]; |
| 902 | |
| 903 | proc_linkup0(&proc0, &thread0); |
| 904 | thread0.td_kstack = kstack; |
| 905 | thread0.td_kstack_pages = KSTACK_PAGES; |
| 906 | thread0.td_pcb = (struct pcb *)(thread0.td_kstack + |
| 907 | thread0.td_kstack_pages * PAGE_SIZE) - 1; |
| 908 | thread0.td_pcb->pcb_fpflags = 0; |
| 909 | thread0.td_pcb->pcb_fpusaved = &thread0.td_pcb->pcb_fpustate; |
| 910 | thread0.td_pcb->pcb_vfpcpu = UINT_MAX; |
| 911 | thread0.td_frame = &proc0_tf; |
| 912 | pcpup->pc_curpcb = thread0.td_pcb; |
| 913 | } |
| 914 | |
| 915 | typedef struct { |
| 916 | uint32_t type; |
no test coverage detected