Lines Matching refs:tfh
326 struct gru_tlb_fault_handle *tfh, in gru_preload_tlb() argument
346 if (ret || tfh_write_only(tfh, gpa, GAA_RAM, vaddr, asid, write, in gru_preload_tlb()
351 atomic ? "atomic" : "non-atomic", gru->gs_gid, gts, tfh, in gru_preload_tlb()
370 struct gru_tlb_fault_handle *tfh, in gru_try_dropin() argument
389 cbe = gru_tfh_to_cbe(tfh); in gru_try_dropin()
398 if (tfh->status != TFHSTATUS_EXCEPTION) { in gru_try_dropin()
399 gru_flush_cache(tfh); in gru_try_dropin()
401 if (tfh->status != TFHSTATUS_EXCEPTION) in gru_try_dropin()
405 if (tfh->state == TFHSTATE_IDLE) in gru_try_dropin()
407 if (tfh->state == TFHSTATE_MISS_FMM && cbk) in gru_try_dropin()
410 write = (tfh->cause & TFHCAUSE_TLB_MOD) != 0; in gru_try_dropin()
411 vaddr = tfh->missvaddr; in gru_try_dropin()
412 asid = tfh->missasid; in gru_try_dropin()
413 indexway = tfh->indexway; in gru_try_dropin()
441 gru_preload_tlb(gru, gts, atomic, vaddr, asid, write, tlb_preload_count, tfh, cbe); in gru_try_dropin()
447 tfh_write_restart(tfh, gpa, GAA_RAM, vaddr, asid, write, in gru_try_dropin()
452 atomic ? "atomic" : "non-atomic", gru->gs_gid, gts, tfh, vaddr, asid, in gru_try_dropin()
460 gru_dbg(grudev, "FAILED no_asid tfh: 0x%p, vaddr 0x%lx\n", tfh, vaddr); in gru_try_dropin()
462 tfh_user_polling_mode(tfh); in gru_try_dropin()
464 gru_flush_cache(tfh); in gru_try_dropin()
470 tfh_user_polling_mode(tfh); in gru_try_dropin()
473 gru_dbg(grudev, "FAILED upm tfh: 0x%p, vaddr 0x%lx\n", tfh, vaddr); in gru_try_dropin()
478 gru_flush_cache(tfh); in gru_try_dropin()
481 gru_dbg(grudev, "FAILED fmm tfh: 0x%p, state %d\n", tfh, tfh->state); in gru_try_dropin()
486 gru_flush_cache(tfh); in gru_try_dropin()
492 tfh, tfh->status, tfh->state); in gru_try_dropin()
497 gru_flush_cache(tfh); in gru_try_dropin()
502 gru_dbg(grudev, "FAILED idle tfh: 0x%p, state %d\n", tfh, tfh->state); in gru_try_dropin()
507 tfh_exception(tfh); in gru_try_dropin()
510 gru_dbg(grudev, "FAILED inval tfh: 0x%p, vaddr 0x%lx\n", tfh, vaddr); in gru_try_dropin()
516 tfh_user_polling_mode(tfh); in gru_try_dropin()
518 gru_flush_cache(tfh); in gru_try_dropin()
522 tfh, vaddr); in gru_try_dropin()
537 struct gru_tlb_fault_handle *tfh = NULL; in gru_intr() local
567 tfh = get_tfh_by_index(gru, cbrnum); in gru_intr()
568 prefetchw(tfh); /* Helps on hdw, required for emulator */ in gru_intr()
576 ctxnum = tfh->ctxnum; in gru_intr()
592 gru_try_dropin(gru, gts, tfh, NULL); in gru_intr()
595 tfh_user_polling_mode(tfh); in gru_intr()
627 struct gru_tlb_fault_handle *tfh, in gru_user_dropin() argument
637 prefetchw(tfh); /* Helps on hdw, required for emulator */ in gru_user_dropin()
638 ret = gru_try_dropin(gts->ts_gru, gts, tfh, cb); in gru_user_dropin()
652 struct gru_tlb_fault_handle *tfh; in gru_handle_user_call_os() local
690 tfh = get_tfh_by_index(gts->ts_gru, cbrnum); in gru_handle_user_call_os()
693 ret = gru_user_dropin(gts, tfh, cbk); in gru_handle_user_call_os()