1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
|
--- vmmon-only/linux/hostif.c 2016-12-12 09:17:44.438182532 -0700
+++ vmmon-only/linux/hostif.c 2016-12-12 09:19:24.066254301 -0700
@@ -1172,7 +1172,11 @@
#else
retval = get_user_pages(current, current->mm, (unsigned long)uvAddr,
#endif
- numPages, 0, 0, ppages, NULL);
+ numPages, 0,
+#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 9, 0)
+ 0,
+#endif
+ ppages, NULL);
up_read(¤t->mm->mmap_sem);
return retval != numPages;
--- vmnet-only/userif.c 2016-12-12 09:27:12.445246854 -0700
+++ vmnet-only/userif.c 2016-12-12 09:27:30.654298646 -0700
@@ -118,7 +118,13 @@
#else
retval = get_user_pages(current, current->mm, addr,
#endif
- 1, 1, 0, &page, NULL);
+ 1,
+#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 9, 0)
+ 1, 0,
+#else
+ FOLL_WRITE,
+#endif
+ &page, NULL);
up_read(¤t->mm->mmap_sem);
if (retval != 1) {
--- vmci-only/linux/driver.c 2016-12-12 09:38:13.076847013 -0700
+++ vmci-only/linux/driver.c 2016-12-12 09:38:45.638087445 -0700
@@ -1473,7 +1473,13 @@
#else
retval = get_user_pages(current, current->mm, addr,
#endif
- 1, 1, 0, &page, NULL);
+ 1,
+#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 9, 0)
+ 1, 0,
+#else
+ FOLL_WRITE,
+#endif
+ &page, NULL);
up_read(¤t->mm->mmap_sem);
if (retval != 1) {
--- vmci-only/linux/vmciKernelIf.c 2016-12-12 09:38:20.678904322 -0700
+++ vmci-only/linux/vmciKernelIf.c 2016-12-12 09:39:59.129587451 -0700
@@ -2061,7 +2061,11 @@
(VA)produceUVA,
#endif
produceQ->kernelIf->numPages,
- 1, 0,
+#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 9, 0)
+ 1, 0,
+#else
+ FOLL_WRITE,
+#endif
produceQ->kernelIf->u.h.headerPage,
NULL);
if (retval < produceQ->kernelIf->numPages) {
@@ -2079,7 +2083,11 @@
(VA)consumeUVA,
#endif
consumeQ->kernelIf->numPages,
- 1, 0,
+#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 9, 0)
+ 1, 0,
+#else
+ FOLL_WRITE,
+#endif
consumeQ->kernelIf->u.h.headerPage,
NULL);
if (retval < consumeQ->kernelIf->numPages) {
|