summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2020-06-09 07:34:17 +0300
committerLinus Torvalds <torvalds@linux-foundation.org>2020-06-09 19:39:15 +0300
commitc4cb164426aebd635baa53685b0ebf1a127e9803 (patch)
treebec4ea8f9f94a2fdf67880b1e950abe55bf2cbb2 /kernel
parentbd88bb5d4007949be7154deae7cef7173c751a95 (diff)
downloadlinux-c4cb164426aebd635baa53685b0ebf1a127e9803.tar.xz
maccess: rename strncpy_from_unsafe_strict to strncpy_from_kernel_nofault
This matches the naming of strncpy_from_user_nofault, and also makes it more clear what the function is supposed to do. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Cc: Alexei Starovoitov <ast@kernel.org> Cc: Daniel Borkmann <daniel@iogearbox.net> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20200521152301.2587579-8-hch@lst.de Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/trace/bpf_trace.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/trace/bpf_trace.c b/kernel/trace/bpf_trace.c
index 334db5a299a0..879ee676bf5a 100644
--- a/kernel/trace/bpf_trace.c
+++ b/kernel/trace/bpf_trace.c
@@ -240,7 +240,7 @@ bpf_probe_read_kernel_str_common(void *dst, u32 size, const void *unsafe_ptr,
* is returned that can be used for bpf_perf_event_output() et al.
*/
ret = compat ? strncpy_from_unsafe(dst, unsafe_ptr, size) :
- strncpy_from_unsafe_strict(dst, unsafe_ptr, size);
+ strncpy_from_kernel_nofault(dst, unsafe_ptr, size);
if (unlikely(ret < 0))
out:
memset(dst, 0, size);
@@ -415,7 +415,7 @@ fmt_str:
break;
#endif
case 'k':
- strncpy_from_unsafe_strict(buf, unsafe_ptr,
+ strncpy_from_kernel_nofault(buf, unsafe_ptr,
sizeof(buf));
break;
case 'u':