]> git.pld-linux.org Git - packages/ixgbe.git/commitdiff
- fix building with linux 4.7 and compatiility with linux 4.6 master auto/th/ixgbe-4.4.6-2
authorJan Rękorajski <baggins@pld-linux.org>
Mon, 1 Aug 2016 18:59:41 +0000 (20:59 +0200)
committerJan Rękorajski <baggins@pld-linux.org>
Mon, 1 Aug 2016 18:59:41 +0000 (20:59 +0200)
- rel 2

ixgbe.spec
linux-4.6.patch [new file with mode: 0644]

index 50cbb909ba577daf33c9a953539cf5cdd98b995e..097b9075de4b12027e04e5af3dd9bd25f1110882 100644 (file)
@@ -4,7 +4,7 @@
 # nothing to be placed to debuginfo package
 %define                _enable_debug_packages  0
 
-%define                rel     1
+%define                rel     2
 %define                pname   ixgbe
 Summary:       Intel(R) 10 Gigabit driver for Linux
 Summary(pl.UTF-8):     Sterownik do karty Intel(R) 10 Gigabit
@@ -15,6 +15,7 @@ License:      GPL v2
 Group:         Base/Kernel
 Source0:       http://downloads.sourceforge.net/e1000/%{pname}-%{version}.tar.gz
 # Source0-md5: e11e83c96afe846b5ee72c309a58e11f
+Patch0:                linux-4.6.patch
 URL:           http://sourceforge.net/projects/e1000/
 %{expand:%buildrequires_kernel kernel%%{_alt_kernel}-module-build >= 3:2.6.20.2}
 BuildRequires: rpmbuild(macros) >= 1.701
@@ -77,6 +78,7 @@ EOF\
 
 %prep
 %setup -q -n %{pname}-%{version}
+%patch0 -p1
 
 cp src/Makefile src/Makefile.%{name}
 cat > src/Makefile <<'EOF'
diff --git a/linux-4.6.patch b/linux-4.6.patch
new file mode 100644 (file)
index 0000000..2f2bc10
--- /dev/null
@@ -0,0 +1,14 @@
+--- ixgbe-4.4.6/src/ixgbe_main.c.orig  2016-06-02 00:50:01.000000000 +0200
++++ ixgbe-4.4.6/src/ixgbe_main.c       2016-08-01 20:57:46.424973720 +0200
+@@ -1656,7 +1656,11 @@
+       /* Even if we own the page, we are not allowed to use atomic_set()
+        * This would break get_page_unless_zero() users.
+        */
++#if (LINUX_VERSION_CODE < KERNEL_VERSION(4,6,0))
+       atomic_inc(&page->_count);
++#else
++      page_ref_inc(page);
++#endif
+       return true;
+ }
This page took 0.085131 seconds and 4 git commands to generate.