[CRIU] [PATCH v4 0/3] page-read: Add async mode

Mike Rapoport rppt at linux.vnet.ibm.com
Sun Nov 13 01:38:50 PST 2016


For lazy pages reading we need the ability to do ->read_pages callback
but not expect that it would return any data in the buffer.

Also, for regular restore, we don't need the data in memory immediately,
but agree to wait.

So here is the async page-read mode. For local case it's not truly async,
as it still calls blocking read() syscall. But in Linux kernel there's
no method for doing asynchronous read from page cache.

v4:
* restore Pavel's original no-lseek patch

v3:
* Update the lseek patch to cope with random accesses
* Split asynchronous implementation into smaller functions

v2: 
* Lost limits.h in pagemap.c for IOV_MAX (compilation).

Pavel Emelyanov (3):
  page-read: Do not lseek file to get its current position
  page-read: Add async arg to ->read_pages callback
  page-read: Implement asynchronous mode of reading pages (v2)

 criu/include/pagemap.h |  11 +++-
 criu/mem.c             |   7 +-
 criu/pagemap.c         | 172 +++++++++++++++++++++++++++++++++++++++++++++----
 criu/shmem.c           |   2 +-
 criu/uffd.c            |   2 +-
 5 files changed, 176 insertions(+), 18 deletions(-)

-- 
1.9.1



More information about the CRIU mailing list