mm: make compound_head() robust
[linux-2.6-block.git] / mm / huge_memory.c
index 73266ee7274c650c06925456a18bc8fb6fb407c5..e1ccc83f73d3b3cdaf0f07fd6db346d44d1d7476 100644 (file)
@@ -1755,8 +1755,7 @@ static void __split_huge_page_refcount(struct page *page,
                                      (1L << PG_unevictable)));
                page_tail->flags |= (1L << PG_dirty);
 
-               /* clear PageTail before overwriting first_page */
-               smp_wmb();
+               clear_compound_head(page_tail);
 
                if (page_is_young(page))
                        set_page_young(page_tail);