Lines Matching refs:lvl
77 u16 max, lvl; member
100 int lvl; in nvkm_vmm_trace() local
101 for (lvl = it->max; lvl >= 0; lvl--) { in nvkm_vmm_trace()
102 if (lvl >= it->lvl) in nvkm_vmm_trace()
103 buf += sprintf(buf, "%05x:", it->pte[lvl]); in nvkm_vmm_trace()
122 it->flush = min(it->flush, it->max - it->lvl); in nvkm_vmm_flush_mark()
141 const int type = desc[it->lvl].type == SPT; in nvkm_vmm_unref_pdes()
142 struct nvkm_vmm_pt *pgd = it->pt[it->lvl + 1]; in nvkm_vmm_unref_pdes()
143 struct nvkm_vmm_pt *pgt = it->pt[it->lvl]; in nvkm_vmm_unref_pdes()
146 u32 pdei = it->pte[it->lvl + 1]; in nvkm_vmm_unref_pdes()
149 it->lvl++; in nvkm_vmm_unref_pdes()
151 const struct nvkm_vmm_desc_func *func = desc[it->lvl].func; in nvkm_vmm_unref_pdes()
153 TRA(it, "PDE unmap %s", nvkm_vmm_desc_type(&desc[it->lvl - 1])); in nvkm_vmm_unref_pdes()
189 TRA(it, "PDE free %s", nvkm_vmm_desc_type(&desc[it->lvl - 1])); in nvkm_vmm_unref_pdes()
193 it->lvl--; in nvkm_vmm_unref_pdes()
285 it->lvl++; in nvkm_vmm_unref_ptes()
287 it->lvl--; in nvkm_vmm_unref_ptes()
415 const struct nvkm_vmm_desc *desc = &it->desc[it->lvl - 1]; in nvkm_vmm_ref_hwpt()
430 it->lvl--; in nvkm_vmm_ref_hwpt()
478 it->desc[it->lvl].func->pde(it->vmm, pgd, pdei); in nvkm_vmm_ref_hwpt()
486 const struct nvkm_vmm_desc *desc = &it->desc[it->lvl - 1]; in nvkm_vmm_ref_swpt()
518 for (it.lvl = 0; desc[it.lvl].bits; it.lvl++) { in nvkm_vmm_iter()
519 it.pte[it.lvl] = bits & ((1 << desc[it.lvl].bits) - 1); in nvkm_vmm_iter()
520 bits >>= desc[it.lvl].bits; in nvkm_vmm_iter()
522 it.max = --it.lvl; in nvkm_vmm_iter()
525 it.lvl = 0; in nvkm_vmm_iter()
528 it.lvl = it.max; in nvkm_vmm_iter()
532 struct nvkm_vmm_pt *pgt = it.pt[it.lvl]; in nvkm_vmm_iter()
539 for (; it.lvl; it.lvl--) { in nvkm_vmm_iter()
540 const u32 pdei = it.pte[it.lvl]; in nvkm_vmm_iter()
548 it.pt[it.lvl - 1] = pgt = pgd->pde[pdei]; in nvkm_vmm_iter()
556 if (ref && !pgt->refs[desc[it.lvl - 1].type == SPT]) { in nvkm_vmm_iter()
575 it.pte[it.lvl] += ptes; in nvkm_vmm_iter()
578 while (it.pte[it.lvl] == (1 << desc[it.lvl].bits)) { in nvkm_vmm_iter()
579 it.pte[it.lvl++] = 0; in nvkm_vmm_iter()
580 it.pte[it.lvl]++; in nvkm_vmm_iter()