lazy-pages: handle_exit: set uffd to negative value instead of 0

The only use for the userfault file descriptor after the process exited is
for debug logs. Using negative value instead of 0 makes logs more readable.

Signed-off-by: Mike Rapoport <rppt@linux.vnet.ibm.com>
Signed-off-by: Andrei Vagin <avagin@virtuozzo.com>
This commit is contained in:
Mike Rapoport 2018-05-15 23:42:23 +03:00 committed by Andrei Vagin
parent c23f16c28a
commit 43da190cfc

View file

@ -789,7 +789,7 @@ static int handle_exit(struct lazy_pages_info *lpi)
return -1;
free_iovs(lpi);
close(lpi->lpfd.fd);
lpi->lpfd.fd = 0;
lpi->lpfd.fd = -lpi->lpfd.fd;
lpi->exited = true;
/* keep it for tracking in-flight requests and for the summary */