Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 590144

Summary: x11-drivers/nvidia-drivers-367.35-r1 with linux kernel 4.7
Product: Gentoo Linux Reporter: Mario Bachmann <grafgrimm77>
Component: Current packagesAssignee: Jeroen Roovers (RETIRED) <jer>
Status: RESOLVED DUPLICATE    
Severity: normal CC: mail
Priority: Normal    
Version: unspecified   
Hardware: AMD64   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Mario Bachmann 2016-07-31 15:41:48 UTC
emerge =x11-drivers/nvidia-drivers-367.35-r1 fails with a compile error when compiling against linux kernel 4.7 (Vanilla). 

Reproducible: Always

Steps to Reproduce:
1. compile linux kernel 4.7
2. rm /usr/src/linux; ln -s /usr/src/linux-4.7.0 /usr/src/linux
3. emerge -v1 nvidia-drivers (version 367.35-r1)
Actual Results:  
compile error (radix... in uvm_linux.h)

Expected Results:  
should compile

mkdir -p /etc/portage/patches/x11-drivers/nvidia-drivers-367.35-r1/

nano -w /etc/portage/patches/x11-drivers/nvidia-drivers-367.35-r1/nvidia_kernel_4.7.patch

--- kernel/nvidia-uvm/uvm_linux.ORG	2016-07-31 17:19:39.937893990 +0200
+++ kernel/nvidia-uvm/uvm_linux.h	2016-07-31 17:04:52.449876540 +0200
@@ -554,13 +554,6 @@
     INIT_RADIX_TREE(tree, GFP_NOWAIT);
 }
 
-static bool radix_tree_empty(struct radix_tree_root *tree)
-{
-    void *dummy;
-    return radix_tree_gang_lookup(tree, &dummy, 0, 1) == 0;
-}
-
-
 #if !defined(NV_USLEEP_RANGE_PRESENT)
 static void __sched usleep_range(unsigned long min, unsigned long max)
 {
--- kernel/nvidia-drm/nvidia-drm-fb.ORG	2016-07-31 17:20:08.470026235 +0200
+++ kernel/nvidia-drm/nvidia-drm-fb.c	2016-07-31 17:13:29.952154347 +0200
@@ -114,7 +114,7 @@
      * We don't support any planar format, pick up first buffer only.
      */
 
-    gem = drm_gem_object_lookup(dev, file, cmd->handles[0]);
+    gem = drm_gem_object_lookup(file, cmd->handles[0]);
 
     if (gem == NULL)
     {
--- kernel/nvidia-drm/nvidia-drm-gem.ORG	2016-07-31 17:20:32.970139834 +0200
+++ kernel/nvidia-drm/nvidia-drm-gem.c	2016-07-31 17:14:21.308406161 +0200
@@ -408,7 +408,7 @@
 
     mutex_lock(&dev->struct_mutex);
 
-    gem = drm_gem_object_lookup(dev, file, handle);
+    gem = drm_gem_object_lookup(file, handle);
 
     if (gem == NULL)
     {
Comment 1 Jeroen Roovers (RETIRED) gentoo-dev 2016-07-31 23:31:59 UTC

*** This bug has been marked as a duplicate of bug 586066 ***