Re: [PATCH] mm: softdirty: unmapped addresses between VMAs are clean
From: Andrew Morton <akpm@linux-foundation.org>
Date: 2014-09-11 19:54:38
Also in:
lkml
From: Andrew Morton <akpm@linux-foundation.org>
Date: 2014-09-11 19:54:38
Also in:
lkml
On Wed, 10 Sep 2014 22:41:04 -0700 Peter Feiner [off-list ref] wrote:
On Wed, Sep 10, 2014 at 04:36:28PM -0700, Andrew Morton wrote:quoted
On Wed, 10 Sep 2014 16:24:46 -0700 Peter Feiner [off-list ref] wrote:quoted
@@ -1048,32 +1048,51 @@ static int pagemap_pte_range(pmd_t *pmd, unsigned long addr, unsigned long end, + while (1) { + unsigned long vm_start = end;Did you really mean to do that? If so, perhaps a little comment to explain how it works?It's the same idea that I used in the pagemap_pte_hole patch that I submitted today: if vma is NULL, then we fill in the pagemap from (addr) to (end) with non-present pagemap entries. Should I submit a v2 with a comment?
I spent quite some time staring at that code wondering wtf, so anything you can do to clarify it would be good. I think a better name would be plain old "start", to communicate that it's just a local convenience variable. "vm_start" means "start of a vma" and that isn't accurate in this context; in fact it is misleading. -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>