Commit c907796d authored by Mike Rapoport's avatar Mike Rapoport Committed by Andrei Vagin

lazy-pages: make uffd_{copy,zero} return 0 on success

In early days of uffd.c return value from uffd_copy was used to count
transferred pages. Since this is not the case anymore we can use 0 as
success.

travis-ci: success for uffd: A new set of improvements
Signed-off-by: 's avatarMike Rapoport <rppt@linux.vnet.ibm.com>
Signed-off-by: 's avatarPavel Emelyanov <xemul@virtuozzo.com>
parent b72d5f2d
...@@ -544,7 +544,7 @@ static int uffd_copy(struct lazy_pages_info *lpi, __u64 address, int nr_pages) ...@@ -544,7 +544,7 @@ static int uffd_copy(struct lazy_pages_info *lpi, __u64 address, int nr_pages)
lpi->copied_pages += nr_pages; lpi->copied_pages += nr_pages;
return uffdio_copy.copy; return 0;
} }
static int uffd_zero(struct lazy_pages_info *lpi, __u64 address, int nr_pages) static int uffd_zero(struct lazy_pages_info *lpi, __u64 address, int nr_pages)
...@@ -566,7 +566,7 @@ static int uffd_zero(struct lazy_pages_info *lpi, __u64 address, int nr_pages) ...@@ -566,7 +566,7 @@ static int uffd_zero(struct lazy_pages_info *lpi, __u64 address, int nr_pages)
return -1; return -1;
} }
return len; return 0;
} }
static int uffd_handle_pages(struct lazy_pages_info *lpi, __u64 address, int nr) static int uffd_handle_pages(struct lazy_pages_info *lpi, __u64 address, int nr)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment