Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm
[cascardo/linux.git] / arch / s390 / mm / gmap.c
index af0ae6d..2ce6bb3 100644 (file)
@@ -109,7 +109,7 @@ EXPORT_SYMBOL_GPL(gmap_create);
 static void gmap_flush_tlb(struct gmap *gmap)
 {
        if (MACHINE_HAS_IDTE)
-               __tlb_flush_asce(gmap->mm, gmap->asce);
+               __tlb_flush_idte(gmap->asce);
        else
                __tlb_flush_global();
 }
@@ -560,6 +560,9 @@ int __gmap_link(struct gmap *gmap, unsigned long gaddr, unsigned long vmaddr)
        VM_BUG_ON(pgd_none(*pgd));
        pud = pud_offset(pgd, vmaddr);
        VM_BUG_ON(pud_none(*pud));
+       /* large puds cannot yet be handled */
+       if (pud_large(*pud))
+               return -EFAULT;
        pmd = pmd_offset(pud, vmaddr);
        VM_BUG_ON(pmd_none(*pmd));
        /* large pmds cannot yet be handled */