Skip to content

Instantly share code, notes, and snippets.

@laurelmay
Last active January 16, 2019 21:29
Show Gist options
  • Save laurelmay/2b82e33210f7a62c7e03c6327b646318 to your computer and use it in GitHub Desktop.
Save laurelmay/2b82e33210f7a62c7e03c6327b646318 to your computer and use it in GitHub Desktop.
Index: src/VBox/Runtime/r0drv/linux/memuserkernel-r0drv-linux.c
===================================================================
--- src/VBox/Runtime/r0drv/linux/memuserkernel-r0drv-linux.c (revision 76826)
+++ src/VBox/Runtime/r0drv/linux/memuserkernel-r0drv-linux.c (working copy)
@@ -66,7 +66,7 @@
RTR0DECL(bool) RTR0MemUserIsValidAddr(RTR3PTR R3Ptr)
{
IPRT_LINUX_SAVE_EFL_AC();
- bool fRc = access_ok(VERIFY_READ, (void *)R3Ptr, 1);
+ bool fRc = access_ok((void *)R3Ptr, 1);
IPRT_LINUX_RESTORE_EFL_AC();
return fRc;
}
@@ -82,7 +82,7 @@
return (uintptr_t)pv >= PAGE_OFFSET;
#else
# error "PORT ME"
- return !access_ok(VERIFY_READ, pv, 1);
+ return !access_ok(pv, 1);
#endif
}
RT_EXPORT_SYMBOL(RTR0MemKernelIsValidAddr);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment