summaryrefslogtreecommitdiff
path: root/arch/s390/mm/Makefile
diff options
context:
space:
mode:
authorRick Edgecombe <rick.p.edgecombe@intel.com>2023-07-07 02:38:58 +0300
committerDave Hansen <dave.hansen@linux.intel.com>2023-08-03 01:01:51 +0300
commitc6b53dcec07c842af75123d9b29684bdbd36a407 (patch)
tree33567f59d47efd79f97bed34171fae30c1e49194 /arch/s390/mm/Makefile
parent54acee601b87cfe43e17f6812449e5eb3eab39f9 (diff)
downloadlinux-c6b53dcec07c842af75123d9b29684bdbd36a407.tar.xz
x86/shstk: Don't retry vm_munmap() on -EINTR
The existing comment around handling vm_munmap() failure when freeing a shadow stack is wrong. It asserts that vm_munmap() returns -EINTR when the mmap lock is only being held for a short time, and so the caller should retry. Based on this wrong understanding, unmap_shadow_stack() will loop retrying vm_munmap(). What -EINTR actually means in this case is that the process is going away (see ae79878), and the whole MM will be torn down soon. In order to facilitate this, the task should not linger in the kernel, but actually do the opposite. So don't loop in this scenario, just abandon the operation and let exit_mmap() clean it up. Also, update the comment to reflect the actual meaning of the error code. Signed-off-by: Rick Edgecombe <rick.p.edgecombe@intel.com> Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com> Link: https://lore.kernel.org/all/20230706233858.446232-1-rick.p.edgecombe%40intel.com
Diffstat (limited to 'arch/s390/mm/Makefile')
0 files changed, 0 insertions, 0 deletions