summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorKohei Suzuki2017-11-28 21:23:19 +0900
committerKohei Suzuki2017-11-28 21:23:19 +0900
commit64238448baca7452ab4d72634b41a64d5cce254d (patch)
tree63d8a23e5887e6355c1cdc9534ce7a48e65ed87b
parentfaa234291774153ea85c07b5b29f6b5a8bdb963a (diff)
downloadaur-64238448baca7452ab4d72634b41a64d5cce254d.tar.gz
Apply patch for Linux 4.12
-rw-r--r--.SRCINFO4
-rw-r--r--PKGBUILD9
-rw-r--r--linux-4.12-copy-user.patch20
3 files changed, 29 insertions, 4 deletions
diff --git a/.SRCINFO b/.SRCINFO
index fae84d8e998..ee11f464e05 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = pt1_drv-dkms-hg
pkgdesc = PT1/2 driver sources for DKMS
pkgver = r141.c8688d7d6382
- pkgrel = 2
+ pkgrel = 3
url = http://hg.honeyplanet.jp/pt1/
install = dkms.install
arch = i686
@@ -15,10 +15,12 @@ pkgbase = pt1_drv-dkms-hg
source = dkms.conf
source = 99-pt1_drv.rules
source = linux-4.2-vmalloc.patch
+ source = linux-4.12-copy-user.patch
sha1sums = SKIP
sha1sums = af3fc15f2b7e9e1fc9a8559546a0ed733f7115c6
sha1sums = ad3c58078fbd48b8f97ea24af2b084be29210b47
sha1sums = 547f63e6449a73e9072681babc89a7be12e2c07b
+ sha1sums = ad636e6a198628703b7d18c67f091f6271f7cd0f
pkgname = pt1_drv-dkms-hg
diff --git a/PKGBUILD b/PKGBUILD
index 0fb459e9a5a..f55493544e1 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=pt1_drv-dkms-hg
_pkgname=pt1_drv
pkgver=r141.c8688d7d6382
-pkgrel=2
+pkgrel=3
pkgdesc="PT1/2 driver sources for DKMS"
arch=('i686' 'x86_64')
url="http://hg.honeyplanet.jp/pt1/"
@@ -14,7 +14,8 @@ install=dkms.install
source=("$pkgname"::hg+'http://hg.honeyplanet.jp/pt1/'
dkms.conf
99-pt1_drv.rules
- linux-4.2-vmalloc.patch)
+ linux-4.2-vmalloc.patch
+ linux-4.12-copy-user.patch)
pkgver() {
cd "$srcdir/$pkgname"
@@ -24,6 +25,7 @@ pkgver() {
prepare() {
cd "$srcdir/$pkgname"
patch -Np1 -i "$srcdir/linux-4.2-vmalloc.patch"
+ patch -Np1 -i "$srcdir/linux-4.12-copy-user.patch"
}
build() {
@@ -43,4 +45,5 @@ package() {
sha1sums=('SKIP'
'af3fc15f2b7e9e1fc9a8559546a0ed733f7115c6'
'ad3c58078fbd48b8f97ea24af2b084be29210b47'
- '547f63e6449a73e9072681babc89a7be12e2c07b')
+ '547f63e6449a73e9072681babc89a7be12e2c07b'
+ 'ad636e6a198628703b7d18c67f091f6271f7cd0f')
diff --git a/linux-4.12-copy-user.patch b/linux-4.12-copy-user.patch
new file mode 100644
index 00000000000..abaab4f7b12
--- /dev/null
+++ b/linux-4.12-copy-user.patch
@@ -0,0 +1,20 @@
+diff -ur pt1_drv-dkms-hg.orig/driver/pt1_pci.c pt1_drv-dkms-hg/driver/pt1_pci.c
+--- pt1_drv-dkms-hg.orig/driver/pt1_pci.c 2017-11-28 21:15:03.501668869 +0900
++++ pt1_drv-dkms-hg/driver/pt1_pci.c 2017-11-28 21:21:15.294803923 +0900
+@@ -11,13 +11,16 @@
+ #include <linux/interrupt.h>
+ #include <linux/version.h>
+ #include <linux/mutex.h>
++#include <linux/uaccess.h>
+
+ #if LINUX_VERSION_CODE < KERNEL_VERSION(3,4,0)
+ #include <asm/system.h>
+ #endif
+ #include <asm/io.h>
+ #include <asm/irq.h>
++#if LINUX_VERSION_CODE < KERNEL_VERSION(4,12,0)
+ #include <asm/uaccess.h>
++#endif
+
+ #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,23)
+ #include <linux/freezer.h>