We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2d8b22d commit db080f9Copy full SHA for db080f9
arch/parisc/lib/memcpy.c
@@ -56,7 +56,7 @@
56
#ifdef __KERNEL__
57
#include <linux/module.h>
58
#include <linux/compiler.h>
59
-#include <asm/uaccess.h>
+#include <linux/uaccess.h>
60
#define s_space "%%sr1"
61
#define d_space "%%sr2"
62
#else
@@ -524,4 +524,17 @@ EXPORT_SYMBOL(copy_to_user);
524
EXPORT_SYMBOL(copy_from_user);
525
EXPORT_SYMBOL(copy_in_user);
526
EXPORT_SYMBOL(memcpy);
527
+
528
+long probe_kernel_read(void *dst, const void *src, size_t size)
529
+{
530
+ unsigned long addr = (unsigned long)src;
531
532
+ if (size < 0 || addr < PAGE_SIZE)
533
+ return -EFAULT;
534
535
+ /* check for I/O space F_EXTEND(0xfff00000) access as well? */
536
537
+ return __probe_kernel_read(dst, src, size);
538
+}
539
540
#endif
0 commit comments