diff options
author | Christoph Hellwig <hch@lst.de> | 2020-03-16 14:53:09 +0100 |
---|---|---|
committer | Jason Gunthorpe <jgg@mellanox.com> | 2020-03-26 18:33:37 +0100 |
commit | f8c888a304e12074d941428b4aa1b13f04dd54ee (patch) | |
tree | 6dfac480663f9f33acf2aac80311d68b98d224d1 /scripts | |
parent | mm/hmm: simplify hmm_vma_walk_hugetlb_entry() (diff) | |
download | linux-f8c888a304e12074d941428b4aa1b13f04dd54ee.tar.xz linux-f8c888a304e12074d941428b4aa1b13f04dd54ee.zip |
mm/hmm: don't handle the non-fault case in hmm_vma_walk_hole_()
Setting a pfns entry to NONE before returning -EBUSY is a bug that will
cause corruption of the input flags on the next loop.
There is just a single caller using hmm_vma_walk_hole_() for the non-fault
case. Use hmm_pfns_fill() to fill the whole pfn array with zeroes in the
only caller for the non-fault case and remove the non-fault path from
hmm_vma_walk_hole_(). This avoids setting NONE before returning -EBUSY.
Also rename the function to hmm_vma_fault() to better describe what it
does.
Fixes: 2aee09d8c116 ("mm/hmm: change hmm_vma_fault() to allow write fault on page basis")
Link: https://lore.kernel.org/r/20200316135310.899364-5-hch@lst.de
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Jason Gunthorpe <jgg@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions