aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux
diff options
context:
space:
mode:
authorHauke Mehrtens <hauke@hauke-m.de>2019-06-20 11:15:28 +0200
committerHauke Mehrtens <hauke@hauke-m.de>2019-06-20 12:53:53 +0200
commitdc60dc133ac0e82dfcd41fc18af74a58aff7ba35 (patch)
tree5f0d98ecf8fd1dbca8a93b6b1f0b418d3c252462 /target/linux
parentfa1ee2bd2b8281450a95f4e8eefae3290ae17cac (diff)
downloadupstream-dc60dc133ac0e82dfcd41fc18af74a58aff7ba35.tar.gz
upstream-dc60dc133ac0e82dfcd41fc18af74a58aff7ba35.tar.bz2
upstream-dc60dc133ac0e82dfcd41fc18af74a58aff7ba35.zip
brcm2708: Adapt patches to kernel update
In kernel 4.4.182 get_user_pages() does not get the write and force parameter any more, but one flags parameter with WRITE and FORCE attributes. This adapts the patches to use the changed API and fixes the compile problems with the brcm2708 target. This fixes the following compile problem: drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.c: In function 'dump_phys_mem': drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.c:1501:3: warning: passing argument 7 of 'get_user_pages' from incompatible pointer type [-Wincompatible-pointer-types] pages, /* pages (array of page pointers) */ ^ In file included from drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.c:42:0: include/linux/mm.h:1200:6: note: expected 'struct vm_area_struct **' but argument is of type 'struct page **' long get_user_pages(struct task_struct *tsk, struct mm_struct *mm, ^ drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.c:1495:7: error: too many arguments to function 'get_user_pages' rc = get_user_pages(current, /* task */ ^ In file included from drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.c:42:0: include/linux/mm.h:1200:6: note: declared here long get_user_pages(struct task_struct *tsk, struct mm_struct *mm, ^ scripts/Makefile.build:277: recipe for target 'drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.o' failed Fixes: 6c5c3a2edccf ("kernel: Update to version 4.4.182") Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Diffstat (limited to 'target/linux')
-rw-r--r--target/linux/brcm2708/patches-4.4/0036-bcm2708-vchiq-driver.patch10
1 files changed, 4 insertions, 6 deletions
diff --git a/target/linux/brcm2708/patches-4.4/0036-bcm2708-vchiq-driver.patch b/target/linux/brcm2708/patches-4.4/0036-bcm2708-vchiq-driver.patch
index 7247fa6951..f53b065ec7 100644
--- a/target/linux/brcm2708/patches-4.4/0036-bcm2708-vchiq-driver.patch
+++ b/target/linux/brcm2708/patches-4.4/0036-bcm2708-vchiq-driver.patch
@@ -1848,7 +1848,7 @@ vchiq: hack: Add include depecated dma include file
+#endif /* VCHIQ_2835_H */
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_2835_arm.c
-@@ -0,0 +1,586 @@
+@@ -0,0 +1,585 @@
+/**
+ * Copyright (c) 2010-2012 Broadcom. All rights reserved.
+ *
@@ -2274,8 +2274,7 @@ vchiq: hack: Add include depecated dma include file
+ actual_pages = get_user_pages(task, task->mm,
+ (unsigned long)buf & ~(PAGE_SIZE - 1),
+ num_pages,
-+ (type == PAGELIST_READ) /*Write */ ,
-+ 0 /*Force */ ,
++ (type == PAGELIST_READ) ? FOLL_WRITE : 0 /*Flags */ ,
+ pages,
+ NULL /*vmas */);
+ up_read(&task->mm->mmap_sem);
@@ -2437,7 +2436,7 @@ vchiq: hack: Add include depecated dma include file
+}
--- /dev/null
+++ b/drivers/misc/vc04_services/interface/vchiq_arm/vchiq_arm.c
-@@ -0,0 +1,2903 @@
+@@ -0,0 +1,2902 @@
+/**
+ * Copyright (c) 2014 Raspberry Pi (Trading) Ltd. All rights reserved.
+ * Copyright (c) 2010-2012 Broadcom. All rights reserved.
@@ -3917,8 +3916,7 @@ vchiq: hack: Add include depecated dma include file
+ current->mm, /* mm */
+ (unsigned long)virt_addr, /* start */
+ num_pages, /* len */
-+ 0, /* write */
-+ 0, /* force */
++ 0, /* flags */
+ pages, /* pages (array of page pointers) */
+ NULL); /* vmas */
+ up_read(&current->mm->mmap_sem);