Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1738429 > unrolled thread

[PATCH 4.13 002/109] <linux/uaccess.h>: Fix copy_in_user() declaration

Started byGreg Kroah-Hartman <gregkh@linuxfoundation.org>
First post2017-09-24 22:50 +0200
Last post2017-09-24 22:50 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  [PATCH 4.13 002/109] <linux/uaccess.h>: Fix copy_in_user() declaration Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2017-09-24 22:50 +0200

#1738429 — [PATCH 4.13 002/109] <linux/uaccess.h>: Fix copy_in_user() declaration

FromGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Date2017-09-24 22:50 +0200
Subject[PATCH 4.13 002/109] <linux/uaccess.h>: Fix copy_in_user() declaration
Message-ID<utm0K-4Xd-131@gated-at.bofh.it>
4.13-stable review patch.  If anyone has any objections, please let me know.

------------------

From: Bart Van Assche <bart.vanassche@wdc.com>

commit f58e76c1c551c7577b25a6fe493d82f5214331b7 upstream.

copy_in_user() copies data from user-space address @from to user-
space address @to. Hence declare both @from and @to as user-space
pointers.

Fixes: commit d597580d3737 ("generic ...copy_..._user primitives")
Signed-off-by: Bart Van Assche <bart.vanassche@wdc.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

---
 include/linux/uaccess.h |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/include/linux/uaccess.h
+++ b/include/linux/uaccess.h
@@ -156,7 +156,7 @@ copy_to_user(void __user *to, const void
 }
 #ifdef CONFIG_COMPAT
 static __always_inline unsigned long __must_check
-copy_in_user(void __user *to, const void *from, unsigned long n)
+copy_in_user(void __user *to, const void __user *from, unsigned long n)
 {
 	might_fault();
 	if (access_ok(VERIFY_WRITE, to, n) && access_ok(VERIFY_READ, from, n))

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web