[CRIU] [PATCH 8/7] page-xfer: Introduce fully asynchronous read

Pavel Emelyanov xemul at virtuozzo.com
Wed Nov 16 07:59:05 PST 2016


>> @@ -411,7 +428,7 @@ static int maybe_read_page_remote(struct page_read *pr, unsigned long vaddr,
>>  	/* We always do PR_ASAP mode here (FIXME?) */
>>  	ret = request_remote_pages(pr->pid, vaddr, nr);
>>  	if ((ret < 0) || (flags & PR_ASYNC))
>> -		return ret;
>> +		return page_server_start_async_read(buf, nr, read_page_complete, pr);
> 
> I'm not sure I get this. If request_remote_pages returned error why would
> we want to start async read?

Good catch :) It shouldn't look like this, but instead

if (ret < 0)
	return ret;
if (flags & PR_ASYNC)
	return page_server_start_async_read(...);

...

-- Pavel


More information about the CRIU mailing list