Lines Matching refs:p
352 u32 *buf, *p; in cps_gen_entry_code() local
374 p = buf = kcalloc(max_instrs, sizeof(u32), GFP_KERNEL); in cps_gen_entry_code()
392 UASM_i_LA(&p, t0, (long)mips_cps_pm_save); in cps_gen_entry_code()
393 uasm_i_jalr(&p, v0, t0); in cps_gen_entry_code()
394 uasm_i_nop(&p); in cps_gen_entry_code()
402 UASM_i_LA(&p, r_pcohctl, (long)addr_gcr_cl_coherence()); in cps_gen_entry_code()
406 uasm_i_sync(&p, stype_ordering); in cps_gen_entry_code()
407 uasm_build_label(&l, p, lbl_incready); in cps_gen_entry_code()
408 uasm_i_ll(&p, t1, 0, r_nc_count); in cps_gen_entry_code()
409 uasm_i_addiu(&p, t2, t1, 1); in cps_gen_entry_code()
410 uasm_i_sc(&p, t2, 0, r_nc_count); in cps_gen_entry_code()
411 uasm_il_beqz(&p, &r, t2, lbl_incready); in cps_gen_entry_code()
412 uasm_i_addiu(&p, t1, t1, 1); in cps_gen_entry_code()
415 uasm_i_sync(&p, stype_ordering); in cps_gen_entry_code()
421 uasm_il_beq(&p, &r, t1, r_online, lbl_disable_coherence); in cps_gen_entry_code()
422 uasm_i_nop(&p); in cps_gen_entry_code()
431 uasm_i_addiu(&p, t1, zero, -1); in cps_gen_entry_code()
432 uasm_build_label(&l, p, lbl_poll_cont); in cps_gen_entry_code()
433 uasm_i_lw(&p, t0, 0, r_nc_count); in cps_gen_entry_code()
434 uasm_il_bltz(&p, &r, t0, lbl_secondary_cont); in cps_gen_entry_code()
435 uasm_i_ehb(&p); in cps_gen_entry_code()
436 uasm_i_yield(&p, zero, t1); in cps_gen_entry_code()
437 uasm_il_b(&p, &r, lbl_poll_cont); in cps_gen_entry_code()
438 uasm_i_nop(&p); in cps_gen_entry_code()
444 uasm_i_addiu(&p, t0, zero, TCHALT_H); in cps_gen_entry_code()
445 uasm_i_mtc0(&p, t0, 2, 4); in cps_gen_entry_code()
446 uasm_build_label(&l, p, lbl_secondary_hang); in cps_gen_entry_code()
447 uasm_il_b(&p, &r, lbl_secondary_hang); in cps_gen_entry_code()
448 uasm_i_nop(&p); in cps_gen_entry_code()
457 uasm_build_label(&l, p, lbl_disable_coherence); in cps_gen_entry_code()
460 cps_gen_cache_routine(&p, &l, &r, &cpu_data[cpu].icache, in cps_gen_entry_code()
464 cps_gen_cache_routine(&p, &l, &r, &cpu_data[cpu].dcache, in cps_gen_entry_code()
468 uasm_i_sync(&p, stype_memory); in cps_gen_entry_code()
469 uasm_i_ehb(&p); in cps_gen_entry_code()
476 uasm_i_addiu(&p, t0, zero, 1 << cpu_data[cpu].core); in cps_gen_entry_code()
477 uasm_i_sw(&p, t0, 0, r_pcohctl); in cps_gen_entry_code()
478 uasm_i_lw(&p, t0, 0, r_pcohctl); in cps_gen_entry_code()
481 uasm_i_sync(&p, stype_intervention); in cps_gen_entry_code()
482 uasm_i_ehb(&p); in cps_gen_entry_code()
485 uasm_i_sw(&p, zero, 0, r_pcohctl); in cps_gen_entry_code()
486 uasm_i_lw(&p, t0, 0, r_pcohctl); in cps_gen_entry_code()
489 err = cps_gen_flush_fsb(&p, &l, &r, &cpu_data[cpu], in cps_gen_entry_code()
508 UASM_i_LA(&p, t0, (long)addr_cpc_cl_cmd()); in cps_gen_entry_code()
509 uasm_i_addiu(&p, t1, zero, cpc_cmd); in cps_gen_entry_code()
510 uasm_i_sw(&p, t1, 0, t0); in cps_gen_entry_code()
514 uasm_build_label(&l, p, lbl_hang); in cps_gen_entry_code()
515 uasm_il_b(&p, &r, lbl_hang); in cps_gen_entry_code()
516 uasm_i_nop(&p); in cps_gen_entry_code()
527 uasm_i_sync(&p, stype_memory); in cps_gen_entry_code()
528 uasm_i_ehb(&p); in cps_gen_entry_code()
538 cps_gen_set_top_bit(&p, &l, &r, r_nc_count, in cps_gen_entry_code()
546 uasm_build_label(&l, p, lbl_secondary_cont); in cps_gen_entry_code()
549 uasm_i_wait(&p, 0); in cps_gen_entry_code()
557 uasm_i_addiu(&p, t0, zero, CM_GCR_Cx_COHERENCE_COHDOMAINEN_MSK); in cps_gen_entry_code()
558 uasm_i_sw(&p, t0, 0, r_pcohctl); in cps_gen_entry_code()
559 uasm_i_lw(&p, t0, 0, r_pcohctl); in cps_gen_entry_code()
562 uasm_i_sync(&p, stype_memory); in cps_gen_entry_code()
563 uasm_i_ehb(&p); in cps_gen_entry_code()
567 uasm_build_label(&l, p, lbl_decready); in cps_gen_entry_code()
568 uasm_i_sync(&p, stype_ordering); in cps_gen_entry_code()
569 uasm_i_ll(&p, t1, 0, r_nc_count); in cps_gen_entry_code()
570 uasm_i_addiu(&p, t2, t1, -1); in cps_gen_entry_code()
571 uasm_i_sc(&p, t2, 0, r_nc_count); in cps_gen_entry_code()
572 uasm_il_beqz(&p, &r, t2, lbl_decready); in cps_gen_entry_code()
573 uasm_i_andi(&p, v0, t1, (1 << fls(smp_num_siblings)) - 1); in cps_gen_entry_code()
576 uasm_i_sync(&p, stype_ordering); in cps_gen_entry_code()
585 cps_gen_set_top_bit(&p, &l, &r, r_nc_count, lbl_set_cont); in cps_gen_entry_code()
595 uasm_build_label(&l, p, lbl_secondary_cont); in cps_gen_entry_code()
598 uasm_i_sync(&p, stype_ordering); in cps_gen_entry_code()
602 uasm_i_jr(&p, ra); in cps_gen_entry_code()
603 uasm_i_nop(&p); in cps_gen_entry_code()
607 BUG_ON((p - buf) > max_instrs); in cps_gen_entry_code()
615 local_flush_icache_range((unsigned long)buf, (unsigned long)p); in cps_gen_entry_code()