Lines Matching defs:proc_info
94 struct per_proc_info *proc_info,
119 struct per_proc_info *proc_info;
121 proc_info = getPerProc();
126 if (proc_info->save_tbu != 0 || proc_info->save_tbl != 0) {
128 mttbu(proc_info->save_tbu);
129 mttb(proc_info->save_tbl);
132 proc_info->rtcPop = EndOfAllTime; /* forget any existing decrementer setting */
135 proc_info->cpu_type = CPU_TYPE_POWERPC;
136 proc_info->cpu_subtype = (cpu_subtype_t)proc_info->pf.rptdProc;
137 proc_info->cpu_threadtype = CPU_THREADTYPE_NONE;
138 proc_info->running = TRUE;
150 struct per_proc_info *proc_info;
154 proc_info = getPerProc();
157 if (proc_info != mproc_info) {
165 PE_cpu_machine_init(proc_info->cpu_id, !(proc_info->cpu_flags & BootDone));
167 if (proc_info->hibernate) {
175 proc_info->hibernate = 0;
186 if (proc_info != mproc_info) {
193 if (proc_info != mproc_info)
195 proc_info->cpu_flags |= BootDone|SignalReady;
196 if (proc_info != mproc_info) {
197 if (proc_info->ppXFlags & SignalReadyWait) {
198 (void)hw_atomic_and(&proc_info->ppXFlags, ~SignalReadyWait);
199 thread_wakeup(&proc_info->cpu_flags);
215 struct per_proc_info *proc_info = NULL;
219 if ((proc_info = (struct per_proc_info*)kalloc(sizeof(struct per_proc_info))) == (struct per_proc_info*)0)
222 kfree(proc_info, sizeof(struct per_proc_info));
227 kfree(proc_info, sizeof(struct per_proc_info));
232 bzero((void *)proc_info, sizeof(struct per_proc_info));
235 proc_info->pp2ndPage = (addr64_t)pmap_find_phys(kernel_pmap,
236 ((addr64_t)(unsigned int)proc_info) + 0x1000)
238 proc_info->next_savearea = (uint64_t)save_get_init();
239 proc_info->pf = BootProcInfo.pf;
240 proc_info->istackptr = (vm_offset_t)interrupt_stack + INTSTACK_SIZE - FM_SIZE;
241 proc_info->intstack_top_ss = proc_info->istackptr;
242 proc_info->debstackptr = (vm_offset_t)debugger_stack + KERNEL_STACK_SIZE - FM_SIZE;
243 proc_info->debstack_top_ss = proc_info->debstackptr;
245 queue_init(&proc_info->rtclock_timer.queue);
246 proc_info->rtclock_timer.deadline = EndOfAllTime;
248 return proc_info;
259 struct per_proc_info *proc_info
262 if (proc_info->cpu_number == master_cpu)
264 kfree((void *)(proc_info->intstack_top_ss - INTSTACK_SIZE + FM_SIZE), INTSTACK_SIZE);
265 kfree((void *)(proc_info->debstack_top_ss - KERNEL_STACK_SIZE + FM_SIZE), KERNEL_STACK_SIZE);
266 kfree((void *)proc_info, sizeof(struct per_proc_info)); /* Release the per_proc */
276 struct per_proc_info *proc_info
287 proc_info->cpu_number = cpu;
288 PerProcTable[cpu].ppe_vaddr = proc_info;
289 PerProcTable[cpu].ppe_paddr = (addr64_t)pmap_find_phys(kernel_pmap, (addr64_t)(unsigned int)proc_info) << PAGE_SHIFT;
305 struct per_proc_info *proc_info;
309 proc_info = PerProcTable[cpu].ppe_vaddr;
312 PE_cpu_machine_init(proc_info->cpu_id, !(proc_info->cpu_flags & BootDone));
314 proc_info->cpu_flags |= BootDone|SignalReady;
318 proc_info->cpu_flags &= BootDone;
319 proc_info->interrupts_enabled = 0;
320 proc_info->pending_ast = AST_NONE;
321 proc_info->istackptr = proc_info->intstack_top_ss;
322 proc_info->rtcPop = EndOfAllTime;
323 proc_info->FPU_owner = NULL;
324 proc_info->VMX_owner = NULL;
325 proc_info->pms.pmsStamp = 0; /* Dummy transition time */
326 proc_info->pms.pmsPop = EndOfAllTime; /* Set the pop way into the future */
327 proc_info->pms.pmsState = pmsParked; /* Park the stepper */
328 proc_info->pms.pmsCSetCmd = pmsCInit; /* Set dummy initial hardware state */
329 mp = (mapping_t *)(&proc_info->ppUMWmp);
333 if (proc_info->start_paddr == EXCEPTION_VECTOR(T_RESET)) {
358 ml_get_timebase((unsigned long long *)&proc_info->ruptStamp);
362 ret = PE_cpu_start(proc_info->cpu_id,
363 proc_info->start_paddr, (vm_offset_t)proc_info);
366 if (proc_info->start_paddr == EXCEPTION_VECTOR(T_RESET)) {
375 if (!((*(volatile short *)&proc_info->cpu_flags) & SignalReady)) {
376 (void)hw_atomic_or(&proc_info->ppXFlags, SignalReadyWait);
377 thread_sleep_simple_lock((event_t)&proc_info->cpu_flags,
425 struct per_proc_info *proc_info;
430 proc_info = getPerProc();
432 proc_info->running = FALSE;
434 if (proc_info->cpu_number != master_cpu) {
435 timer_queue_shutdown(&proc_info->rtclock_timer.queue);
436 proc_info->rtclock_timer.deadline = EndOfAllTime;
439 fowner = proc_info->FPU_owner; /* Cache this */
442 proc_info->FPU_owner = NULL; /* Set no fpu owner now */
444 fowner = proc_info->VMX_owner; /* Cache this */
446 proc_info->VMX_owner = NULL; /* Set no vector owner now */
448 if (proc_info->cpu_number == master_cpu) {
449 proc_info->cpu_flags &= BootDone;
450 proc_info->interrupts_enabled = 0;
451 proc_info->pending_ast = AST_NONE;
453 if (proc_info->start_paddr == EXCEPTION_VECTOR(T_RESET)) {
481 proc_info->save_tbu = mftbu();
482 proc_info->save_tbl = mftb();
483 } while (mftbu() != proc_info->save_tbu);
485 PE_cpu_machine_quiesce(proc_info->cpu_id);
586 struct per_proc_info *proc_info;
591 proc_info = getPerProc();
596 if(!hw_lock_mbits(&proc_info->MPsigpStat, (MPsigpMsgp | MPsigpAck), (MPsigpBusy | MPsigpPass),
601 holdStat = proc_info->MPsigpStat; /* Snarf stat word */
602 holdParm0 = proc_info->MPsigpParm0; /* Snarf parameter */
603 holdParm1 = proc_info->MPsigpParm1; /* Snarf parameter */
604 holdParm2 = proc_info->MPsigpParm2; /* Snarf parameter */
608 proc_info->MPsigpStat = holdStat & ~(MPsigpMsgp | MPsigpAck | MPsigpFunc); /* Release lock */
620 proc_info->hwCtr.numSIGPast++; /* Count this one */
624 ast_check((processor_t)proc_info->processor);
629 proc_info->hwCtr.numSIGPcpureq++; /* Count this one */
634 cpu_timebase_signal_handler(proc_info, (struct SIGtimebase *)holdParm2);
674 proc_info->hwCtr.numSIGPdebug++; /* Count this one */
675 proc_info->debugger_is_slave++; /* Bump up the count to show we're here */
681 proc_info->hwCtr.numSIGPwake++; /* Count this one */
685 proc_info->hwCtr.numSIGPcall++; /* Count this one */
759 struct per_proc_info *proc_info,
764 if(proc_info->time_base_enable != (void(*)(cpu_id_t, boolean_t ))NULL)
765 proc_info->time_base_enable(proc_info->cpu_id, FALSE);
784 if(proc_info->time_base_enable != (void(*)(cpu_id_t, boolean_t ))NULL)
785 proc_info->time_base_enable(proc_info->cpu_id, TRUE);
801 struct per_proc_info *proc_info;
811 proc_info = PerProcTable[slot_num].ppe_vaddr;
812 tcpu_type = proc_info->cpu_type;
813 tcpu_subtype = proc_info->cpu_subtype;