summaryrefslogtreecommitdiffstats
path: root/mm/maccess.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2020-06-09 06:34:20 +0200
committerLinus Torvalds <torvalds@linux-foundation.org>2020-06-09 18:39:15 +0200
commit02dddb160ec1dccb51e75f3113654a090bc3963a (patch)
tree2ea80889a6ac1af4d7fcf50d11f15a661112d674 /mm/maccess.c
parentmaccess: rename strncpy_from_unsafe_strict to strncpy_from_kernel_nofault (diff)
downloadlinux-02dddb160ec1dccb51e75f3113654a090bc3963a.tar.xz
linux-02dddb160ec1dccb51e75f3113654a090bc3963a.zip
maccess: rename strnlen_unsafe_user to strnlen_user_nofault
This matches the naming of strnlen_user, 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-9-hch@lst.de Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to '')
-rw-r--r--mm/maccess.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/mm/maccess.c b/mm/maccess.c
index 50b27fbe5cf8..88ab30c054a9 100644
--- a/mm/maccess.c
+++ b/mm/maccess.c
@@ -260,7 +260,7 @@ long strncpy_from_user_nofault(char *dst, const void __user *unsafe_addr,
}
/**
- * strnlen_unsafe_user: - Get the size of a user string INCLUDING final NUL.
+ * strnlen_user_nofault: - Get the size of a user string INCLUDING final NUL.
* @unsafe_addr: The string to measure.
* @count: Maximum count (including NUL)
*
@@ -275,7 +275,7 @@ long strncpy_from_user_nofault(char *dst, const void __user *unsafe_addr,
* Unlike strnlen_user, this can be used from IRQ handler etc. because
* it disables pagefaults.
*/
-long strnlen_unsafe_user(const void __user *unsafe_addr, long count)
+long strnlen_user_nofault(const void __user *unsafe_addr, long count)
{
mm_segment_t old_fs = get_fs();
int ret;