author: KP Singh <kpsingh@chromium.org> 2020-06-04 16:50:11 -0700
committer: Linus Torvalds <torvalds@linux-foundation.org> 2020-06-04 19:06:25 -0700
commit: 07887358993d48571f0f3a25cfce715564b35587
parent: 9ac17575804024fb3d5692cad7afc08929bab981
Commit Summary:
Diffstat:
1 file changed, 1 insertion, 0 deletions
diff --git a/lib/strncpy_from_user.c b/lib/strncpy_from_user.c
index b90ec550183a..34696a348864 100644
--- a/lib/strncpy_from_user.c
+++ b/lib/strncpy_from_user.c
@@ -98,6 +98,7 @@ long strncpy_from_user(char *dst, const char __user *src, long count)
{
unsigned long max_addr, src_addr;
+ might_fault();
if (unlikely(count <= 0))
return 0;