diff options
Diffstat (limited to 'mm')
-rw-r--r-- | mm/mmap.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -570,9 +570,9 @@ again: remove_next = 1 + (end > next->vm_end); | |||
570 | 570 | ||
571 | /* | 571 | /* |
572 | * When changing only vma->vm_end, we don't really need | 572 | * When changing only vma->vm_end, we don't really need |
573 | * anon_vma lock: but is that case worth optimizing out? | 573 | * anon_vma lock. |
574 | */ | 574 | */ |
575 | if (vma->anon_vma) | 575 | if (vma->anon_vma && (insert || importer || start != vma->vm_start)) |
576 | anon_vma = vma->anon_vma; | 576 | anon_vma = vma->anon_vma; |
577 | if (anon_vma) { | 577 | if (anon_vma) { |
578 | spin_lock(&anon_vma->lock); | 578 | spin_lock(&anon_vma->lock); |