Lines Matching refs:tce
32 #include <asm/tce.h>
335 ret = anon_inode_getfd("kvm-spapr-tce", &kvm_spapr_tce_fops,
354 static long kvmppc_tce_to_ua(struct kvm *kvm, unsigned long tce,
357 unsigned long gfn = tce >> PAGE_SHIFT;
365 (tce & ~(PAGE_MASK | TCE_PCI_READ | TCE_PCI_WRITE));
371 unsigned long tce)
373 unsigned long gpa = tce & ~(TCE_PCI_READ | TCE_PCI_WRITE);
374 enum dma_data_direction dir = iommu_tce_direction(tce);
385 if (kvmppc_tce_to_ua(stt->kvm, tce, &ua))
411 unsigned long idx, unsigned long tce)
423 if (!tce)
432 tbl[idx % TCES_PER_PAGE] = tce;
573 unsigned long ioba, unsigned long tce)
581 /* udbg_printf("H_PUT_TCE(): liobn=0x%lx ioba=0x%lx, tce=0x%lx\n", */
582 /* liobn, ioba, tce); */
594 ret = kvmppc_tce_validate(stt, tce);
598 dir = iommu_tce_direction(tce);
600 if ((dir != DMA_NONE) && kvmppc_tce_to_ua(vcpu->kvm, tce, &ua)) {
622 kvmppc_tce_put(stt, entry, tce);
639 u64 tce;
669 if (get_user(tce, tces + i)) {
673 tce = be64_to_cpu(tce);
675 ret = kvmppc_tce_validate(stt, tce);
691 if (get_user(tce, tces + i)) {
695 tce = be64_to_cpu(tce);
697 if (kvmppc_tce_to_ua(vcpu->kvm, tce, &ua)) {
705 iommu_tce_direction(tce));
714 kvmppc_tce_put(stt, entry + i, tce);