mm/hmm: replace the block argument to hmm_range_fault with a flags value

This allows easier expansion to other flags, and also makes the callers a
little easier to read.

Link: https://lore.kernel.org/r/20190726005650.2566-4-rcampbell@nvidia.com
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Ralph Campbell <rcampbell@nvidia.com>
Reviewed-by: Jason Gunthorpe <jgg@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
This commit is contained in:
Christoph Hellwig
2019-07-25 17:56:46 -07:00
committed by Jason Gunthorpe
parent d2e8d55116
commit 9a4903e49e
4 changed files with 48 additions and 41 deletions

View File

@@ -832,7 +832,7 @@ retry:
down_read(&mm->mmap_sem);
r = hmm_range_fault(range, true);
r = hmm_range_fault(range, 0);
if (unlikely(r < 0)) {
if (likely(r == -EAGAIN)) {
/*