diff options
author | Waldemar Brodkorb <wbx@uclibc-ng.org> | 2016-09-29 14:45:57 +0200 |
---|---|---|
committer | Waldemar Brodkorb <wbx@uclibc-ng.org> | 2016-09-29 14:46:19 +0200 |
commit | dd02220dc1f33d963fe873be903c9c90e9485f92 (patch) | |
tree | 82028d51075aeacc115adfc3233280271ed852d7 /package/cryptodev-linux | |
parent | 0947725eba6a82214d7212be891f7e25e43b5289 (diff) |
cryptodev-linux: add upstream patch for newer kernels
Diffstat (limited to 'package/cryptodev-linux')
-rw-r--r-- | package/cryptodev-linux/patches/patch-zc_c | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/package/cryptodev-linux/patches/patch-zc_c b/package/cryptodev-linux/patches/patch-zc_c new file mode 100644 index 000000000..d16051b4a --- /dev/null +++ b/package/cryptodev-linux/patches/patch-zc_c @@ -0,0 +1,25 @@ +--- cryptodev-linux-1.8.orig/zc.c 2015-11-28 02:07:11.000000000 +0100 ++++ cryptodev-linux-1.8/zc.c 2016-09-29 03:07:39.505502335 +0200 +@@ -59,7 +59,12 @@ int __get_userbuf(uint8_t __user *addr, + } + + down_read(&mm->mmap_sem); +- ret = get_user_pages(task, mm, ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 6, 0)) ++ ret = get_user_pages_remote( ++#else ++ ret = get_user_pages( ++#endif ++ task, mm, + (unsigned long)addr, pgcount, write, 0, pg, NULL); + up_read(&mm->mmap_sem); + if (ret != pgcount) +@@ -119,7 +124,7 @@ void release_user_pages(struct csession + else + ses->readonly_pages--; + +- page_cache_release(ses->pages[i]); ++ put_page(ses->pages[i]); + } + ses->used_pages = 0; + } |