pxa168_eth: fix mdiobus_scan() error check
[cascardo/linux.git] / mm / memory-failure.c
index 5a544c6..ca5acee 100644 (file)
@@ -538,7 +538,7 @@ static int delete_from_lru_cache(struct page *p)
                /*
                 * drop the page count elevated by isolate_lru_page()
                 */
-               page_cache_release(p);
+               put_page(p);
                return 0;
        }
        return -EIO;
@@ -888,7 +888,15 @@ int get_hwpoison_page(struct page *page)
                }
        }
 
-       return get_page_unless_zero(head);
+       if (get_page_unless_zero(head)) {
+               if (head == compound_head(page))
+                       return 1;
+
+               pr_info("MCE: %#lx cannot catch tail\n", page_to_pfn(page));
+               put_page(head);
+       }
+
+       return 0;
 }
 EXPORT_SYMBOL_GPL(get_hwpoison_page);