mm: free compound page with correct order
[pandora-kernel.git] / mm / memory.c
index e229970..3e50383 100644 (file)
@@ -1147,6 +1147,7 @@ again:
                                print_bad_pte(vma, addr, ptent, page);
                        if (unlikely(!__tlb_remove_page(tlb, page))) {
                                force_flush = 1;
+                               addr += PAGE_SIZE;
                                break;
                        }
                        continue;
@@ -2053,7 +2054,8 @@ static int do_wp_page(struct mm_struct *mm, struct vm_area_struct *vma,
        old_page = vm_normal_page(vma, address, orig_pte);
        if (!old_page) {
                /*
-                * VM_MIXEDMAP !pfn_valid() case
+                * VM_MIXEDMAP !pfn_valid() case, or VM_SOFTDIRTY clear on a
+                * VM_PFNMAP VMA.
                 *
                 * We should not cow pages in a shared writeable mapping.
                 * Just mark the pages writable as we can't do any dirty