Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 449140 - x11-drivers/nvidia-drivers-304.64 with linux 3.7.x - kernel/nv-linux.h:1561:2: error: #error "NV_INIT_WORK_ARGUMENT_COUNT value unrecognized!
Summary: x11-drivers/nvidia-drivers-304.64 with linux 3.7.x - kernel/nv-linux.h:1561:2...
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: x86 Linux
: Normal normal
Assignee: Doug Goldstein (RETIRED)
URL: http://slackblogs.blogspot.com/2012/1...
Whiteboard:
Keywords:
: 450546 454054 (view as bug list)
Depends on:
Blocks:
 
Reported: 2012-12-29 07:40 UTC by Russell Dwiggins
Modified: 2013-01-26 15:57 UTC (History)
6 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
patch for nvidia-drivers-304.64 agains kernel 3.7 (file_449140.txt,1.72 KB, text/plain)
2012-12-29 07:42 UTC, Russell Dwiggins
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Russell Dwiggins 2012-12-29 07:40:54 UTC
nvidia-drivers is not compiling on kernel 3.7 on my system.  Looking into it via google, I discovered a patch at the link provided.  When applied, nvidia-drivers compiles successfully.

Reproducible: Always

Steps to Reproduce:
1. Update to kernel 3.7
2. Attempt to emerge nvidia-drivers
3. merge fails
Actual Results:  
merge fails

Expected Results:  
successful merge

The patch:

Index: kernel/conftest.sh
===================================================================
--- kernel/conftest.sh.orig
+++ kernel/conftest.sh
@@ -20,6 +20,7 @@ ARCH=$3
 ISYSTEM=`$CC -print-file-name=include 2> /dev/null`
 SOURCES=$4
 HEADERS=$SOURCES/include
+HEADERSA=$SOURCES/include/uapi
 OUTPUT=$5
 XEN_PRESENT=1
 
@@ -118,7 +119,7 @@ build_cflags() {
         fi
     fi
 
-    CFLAGS="$CFLAGS $OUTPUT_CFLAGS -I$HEADERS $AUTOCONF_CFLAGS"
+    CFLAGS="$CFLAGS $OUTPUT_CFLAGS -I$HEADERS -I$HEADERSA $AUTOCONF_CFLAGS"
 
     test_xen
 
@@ -146,10 +147,10 @@ build_cflags() {
         fi
     fi
 
-    CFLAGS="$BASE_CFLAGS $MACH_CFLAGS $OUTPUT_CFLAGS -I$HEADERS $AUTOCONF_CFLAGS"
+    CFLAGS="$BASE_CFLAGS $MACH_CFLAGS $OUTPUT_CFLAGS -I$HEADERS -I$HEADERSA $AUTOCONF_CFLAGS"
 
     if [ "$ARCH" = "i386" -o "$ARCH" = "x86_64" ]; then
-        CFLAGS="$CFLAGS -I$SOURCES/arch/x86/include -I$OUTPUT/arch/x86/include/generated"
+        CFLAGS="$CFLAGS -I$SOURCES/arch/x86/include -I$SOURCES/arch/x86/include/uapi -I$OUTPUT/arch/x86/include/generated -I$OUTPUT/arch/x86/include/generated/uapi"
     elif [ "$ARCH" = "arm" ]; then
         CFLAGS="$CFLAGS -I$SOURCES/arch/arm/include -I$OUTPUT/arch/arm/include/generated"
     fi
Index: kernel/nv-mmap.c
===================================================================
--- kernel/nv-mmap.c.orig
+++ kernel/nv-mmap.c
@@ -14,6 +14,11 @@
 #include "os-interface.h"
 #include "nv-linux.h"
 
+/* Fix needed for change in VM_xxx flags */
+#ifndef VM_RESERVED
+# define VM_RESERVED (VM_DONTEXPAND | VM_DONTDUMP)
+#endif
+
 /*
  * The 'struct vm_operations' open() callback is called by the Linux
  * kernel when the parent VMA is split or copied, close() when the
Comment 1 Russell Dwiggins 2012-12-29 07:42:36 UTC
Created attachment 333660 [details]
patch for nvidia-drivers-304.64 agains kernel 3.7
Comment 2 Kacper Kowalik (Xarthisius) (RETIRED) gentoo-dev 2012-12-29 12:32:33 UTC
Our policy is not to patch drivers for new kernels by ourselves. Instead we wait for nvidia's official release that supports given kernel. In the meantime you can use epatch_user functionality to fix it locally on your boxes (see [1]) Thank you for your report and understanding.
Best regards,
Kacper Kowalik

[1] http://www.gentoo.org/doc/en/handbook/handbook-amd64.xml?part=3&chap=6
Comment 3 Kacper Kowalik (Xarthisius) (RETIRED) gentoo-dev 2013-01-06 16:38:16 UTC
*** Bug 450546 has been marked as a duplicate of this bug. ***
Comment 4 Jeroen Roovers (RETIRED) gentoo-dev 2013-01-26 15:57:34 UTC
*** Bug 454054 has been marked as a duplicate of this bug. ***