diff options
-rw-r--r-- | mm/rmap.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/mm/rmap.c b/mm/rmap.c index 9c3e77396d1a..83bfafabb47b 100644 --- a/mm/rmap.c +++ b/mm/rmap.c @@ -1564,10 +1564,9 @@ void __put_anon_vma(struct anon_vma *anon_vma) { struct anon_vma *root = anon_vma->root; + anon_vma_free(anon_vma); if (root != anon_vma && atomic_dec_and_test(&root->refcount)) anon_vma_free(root); - - anon_vma_free(anon_vma); } static struct anon_vma *rmap_walk_anon_lock(struct page *page, |