linuxkpi: Add user_write_access_*

Needed by drm-kmod v5.8

Reviewed by:	bz
MFC after:	2 weeks
Sponsored by:	Beckhoff Automation GmbH & Co. KG
Differential Revision:	https://reviews.freebsd.org/D34284
This commit is contained in:
Emmanuel Vadot 2022-02-15 12:04:40 +01:00
parent bf7deecfe7
commit 4f689b302f

View File

@ -55,6 +55,9 @@ copy_from_user(void *to, const void *from, unsigned long n)
#define user_access_begin(ptr, len) access_ok(ptr, len)
#define user_access_end() do { } while (0)
#define user_write_access_begin(ptr, len) access_ok(ptr, len)
#define user_write_access_end() do { } while (0)
#define unsafe_get_user(x, ptr, err) do { \
if (unlikely(__get_user(x, ptr))) \
goto err; \