Mike Rapoport 9d95aa4bad userfaultfd_zeropage: return -ENOSPC in case mm has gone
In the non-cooperative userfaultfd case, the process exit may race with
outstanding mcopy_atomic called by the uffd monitor.  Returning -ENOSPC
instead of -EINVAL when mm is already gone will allow uffd monitor to
distinguish this case from other error conditions.

Unfortunately I overlooked userfaultfd_zeropage when updating
userfaultd_copy().

Link: http://lkml.kernel.org/r/1501136819-21857-1-git-send-email-rppt@linux.vnet.ibm.com
Fixes: 96333187ab162 ("userfaultfd_copy: return -ENOSPC in case mm has gone")
Signed-off-by: Mike Rapoport <rppt@linux.vnet.ibm.com>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Cc: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
Cc: Pavel Emelyanov <xemul@virtuozzo.com>
Cc: Michal Hocko <mhocko@kernel.org>
Cc: <stable@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2017-08-02 17:16:12 -07:00
..
2017-07-11 06:08:58 -04:00
2017-07-11 06:06:17 -04:00
2017-07-17 14:54:59 +02:00
2017-07-17 19:23:18 -07:00
2017-07-25 08:51:57 -07:00
2017-07-06 16:24:35 -07:00
2017-07-28 14:44:56 -07:00
2017-07-07 20:09:10 -04:00
2017-07-06 03:31:46 -04:00
2017-07-06 03:31:46 -04:00
2017-04-17 12:52:27 -04:00
2017-07-07 19:38:17 -07:00
2017-07-07 13:48:18 -07:00
2017-07-14 22:57:32 -07:00
2017-06-22 11:44:55 -04:00
2017-07-06 03:27:09 -04:00
2017-07-06 03:27:09 -04:00
2017-05-08 17:15:12 -07:00
2017-06-09 16:28:01 -04:00
2017-07-11 06:09:21 -04:00
2017-07-05 18:44:23 -04:00