nvidia-kernels' nvidia.o module will not load into development-sources-2.6.6_rc1 can the following patch be applied to these sources so this works. Have tested, patch applies cleanly and solution works. __this-module breaks because it was moved out of modules in this kernel sometime. http://www.kernel.org/pub/linux/kernel/people/akpm/patches/2.6/2.6.5/2.6.5-mm4/broken-out/move-__this_module-to-modpost.patch See http://forums.gentoo.org/viewtopic.php?t=161788 for thread on solution.
This patch made it into 2.6.6-rc1. It breaks the nvidia kernel module. So the solution is to reverse this patch, not apply it. Or fix nvidia-kernel...
It looks like from this thread http://www.nvnews.net/vbulletin/showthread.php?s=9291d46e52a2029dc894b20084892899&t=27557 that the 1.0-5341 drivers from nVidia fix this issue. I will attempt to test this evening and will post results here. Also I will file a bug report to have an ebuild made for the new driver. Regards, BonezTheGoon
I've mucked with version 5341 of the drivers (modified ebuild and patches from 5336-r2) it works with 2.6.6-r1 provided you revert the move-__this_module-to-modpost.patch it does not work with 2.6.6-r2 no matter what I do .. reverting the patch on it fails using 4K or 8K makes no difference and the use register parameters are not set. although I've seen BonezTheGoon report it works .. I'm wondering what he did to make it so..
Today this raised on lkml: From: Antony Suter <suterant@users.sourceforge.net ----------------------------- By default, my distro was using the make file "makefile" and it stopped working. I switched to using "Makefile.kbuild", which is oriented to 2.6 kernels, and it works again. Comments within Makefile.kbuild touch on changes to module handling in 2.6 compared to 2.4. -----------------------------
Created attachment 30261 [details] nvidia-kernel-1.0.5336-r3.ebuild Ok. This ebuild now uses the .kbuild file supplied with the nvidia driver rather than our own from files/. It apparently no longer has sandbox issues. Also had to make a few other changes to make it work. I'll post a diff in a second.
Oops. I should add that the purpose of this whole thing is that you don't need to revert out the move-__this_module patch, this ebuild works out of the box. At least it does for me :)
Created attachment 30262 [details, diff] nvidia-kernel-1.0.5336-r3.diff Here's the damage which I've caused over the -r2 ebuild :)
I just tested this ebuild. I had to put revert the move-__this_module-to-modpost patch again.
Another tester reports sandbox errors on compile... Seems like the kbuild wanted to read/write to /usr/src/linux/.__modpost.cmd Does anyone know of any modules that by default want to compile themselves in the kernel tree (like this kbuild does) - and if so, how have they got around the sandboxing issues?
yup sand box errors and one other thing it wants the correct kernel version running too .. I built the '2.6.6-rc2' and had /usr/src/linux pointing to it. but the ebuild looked at the running version for the source 2.6.6-rc1 a reboot fixed that then using FEATURES="-sandbox -userpriv -usersandbox" allowed the compile to finish and install .. runs fine now with 2.6.6_rc2 now. by the way this was done not with 5336-r3 but the build renamed to nvidia-kernel-5341-r3 as I already had that running. I suspect it should work as advertised for 5336-r3 with the same issues.
also move_.. etc. patch reversing was not required.
The sandbox issue is totally related to the idea that Modules should be built outside the kernel source directory (even the kernel build should not write to /usr/src/linux, but some other location). Latexer and johnm were working on this before, it actually works in the most recent development sources. However you cannot just call make module, you need to do something like make IGNORE_CC_MISMATCH="yes" K="/usr/src/linux" M="/path/to/build/under" M in our case should really be ${S}, well most of the time anyway. I havent had too much time to test the 5431 release or 2.6.6-rc2 but I shall be doing so over the course of this evening. Progress to follow.
Thanks for the compiling tips. I did suspect sandboxing problems, but as it worked for me without having to take off sandbox, I decided to post it. I have spoken to latexer, and his koutput work seems to combat this exact problem. The thing is, I see the problem in the short time: 2.6.6 will be out today or tomorrow, and we don't currently provide an nvidia module which will work with it. If you download the nvidia package and run it independantly, apparently it will install a working module (I say apparently because I haven't tried it, this is just what a user told me). If we turn off sandboxing, the ebuild I posted appears to work (just not for Jason!). So we are close. I also tested with 5341, with exactly the same results. Bumping the existing -r2 ebuild brings up the same problem (Invalid module format), using an ebuild like the -r3 one I posted works. Are you saying that using these additional make parameters, we will avoid all sandboxing problems? If so, I think that is the short term solution we are looking for.
Hmm - take a look in /usr/portage/net-fs/shfs/shfs-0.32-e1.ebuild They seem to have a similar scenario - they have to fixup $ARCH, but they also have to do some building in the kernel directory. That ebuild simply uses "addwrite" on the kernel source directory, a quick grep through /usr/portage shows other ebuilds are using that approach too. Shall we settle for this?
Allright, seen as though the patch has entered into linus' tree we have very few options at the moment. With the new 2.6.6 kernels comes the ability to specify M="/path" which builds all objects under /path, however it is unrealistic to expect users to upgrade to 2.6.6 when released just to use nvidia drivers. Further more the M= feature requires some kmod eclass changes, and hence kernel ebuild modifications, to interact with sys-kernel/config-kernel more correctly. However this is not going to be ready for 2.6.6. XFree devs basically the thinking goes that unless you strongly object we are going to migrate over to using the kbuild makefile (as it works without the kernel patch being reversed), and add addwrite /usr/src/linux so sandbox does not kill the build process. I would really love a better way to do this, short of blocking nvidia-kernel with 2.6.6, or similar restrictive measures, however I do not have one.
Sorry one extra possibility would be to provide a extra check specifically for 2.6.6 and then use the M= fucntionality where M="${S}" (This _should_ work but would need to be tested, im dubious about using an unproven system in the live tree).
If you're going to add /usr/src/linux to sandbox, you need to print an ewarn about that before the build starts.
Created attachment 30322 [details] nvidia-kernel-1.0.5336-r3.ebuild #2 (using addwrite) Ok, this ebuild is like the first but a little cleaner. It uses addwrite to avoid sandbox issues, and prints a warning first (thanks spyderous). I'll take cyfreds idea from #16 and produce another ebuild for that in a few minutes.
Created attachment 30331 [details] nvidia-kernel-1.0.5336-r3.ebuild #2 (using M="${S}") This ebuild is the alternative approach - it will build as it used to, unless built on 2.6.6 or newer. In this case, it will use the new M="..." parameter to make, in order to build the module in the workdir (this kills any sandboxing issues). Either of these last ebuilds 2 will solve the problem. To reiterate, the problem is: 2.6.6 contains a patch which breaks the nvidia drivers (build is ok, but the module doesnt load), unless they are built using the newer Makefiles. As 2.6.6 is coming out probably tomorrow, we should get this fixed up ASAP. Personally, I think the M="{S}" is the *better* solution (until koutput is ready), but it would require more testing. Given the very short timeframe that we have here, I'd push for going for the more simplistic "addwrite" ebuild for now. Please choose and commit ASAP :)
OK ebuild in comment # 19 works provided you have rebooted into your new kernel .. same issues for the one in comment #18 needs to be running in the new kernel .. this is not how it has worked in the past .. both ebuild styles fail until after a reboot into a new kernel.. The current ebuilds allow you to just change where /usr/src/linux points and it picks off the correct location .. these new ebuilds don't do that and thus require the reboot .. Either change the build to work the old way with respect to finding the correct source tree using /usr/src/linux or warn the user to reboot into the new kernel prior to emergeing the nvidia-kernel drivers
additional weirdness .. if you have two very closely related kernels such as development-sources-2.6.6_rc3 (running) and mm-sources-2.6.6_rc3-r1 (new kernel pointed at by /usr/src/linux) then the nvidia-kernel module will seem to compile but .. it will load on reboot but X will fail to run .. because it got compiled against the running kernel instead of where you thought it did .. with the ebuild version used in Comment # 18 .. you have to modprobe -r nvidia and then re-emerge nvidia-kernel with the desired kernel running ..
Created attachment 30627 [details] nvidia-kernel-1.0.5336-r3.ebuild #3 (using addwrite) Updated addwrite ebuild, solves the issue described in comment #20 by using the SYSSRC parameter with make (the nvidia kbuild makefile listens to this)
Created attachment 30628 [details] nvidia-kernel-1.0.5336-r3.ebuild #3 (using M="${S}") Updated M="${S}" ebuild, solves the issue described in comment #20 by using the SYSSRC parameter with make (the nvidia kbuild makefile listens to this)
works fine now .. both versions
I ran into this problem and have tried the ebuild in comment number 20, it errors out for me with open_wr: /usr/src/linux-2.6.6-rc1/.__modpost.cmd Should I be doing something special in order to get the "M=${S}" trick to work?
Sorry meant to say comment #23
Hmm.. It looks like the newer kbuild stuff was not present in 2.6.6-rc1 If you retest using -rc2 or -rc3 you should not have this problem. And you don't need to do anything special to get the M= bit to take effect. Xfree guys, are you happy to accept the driver like this, or should I add in the extra check for -rc1 with the M="${S}" ebuild?
Um 2.6.6_rc1 here has the kbuild support. Can we wait until 2.6.6 final is released before adding this support? Id like to also consolidate the processes so there is only one ebuild.
note / fyi dispite all claims to the contrary nividia driver verison 5341 does not appear to be a 4K stack driver .. as I found out when trying to use it with mm-sources-2.6.6_rc3-r2 (cobbled together my own ebuild) which has the 4K stack permanently selected .. hard patched no toggle in the make file .. nvidia 5341 module seg faults and will not load .. 5336 nvidia module loads and hard locks the machine when starting X .. you have been warned .. now will nvidia now release a working 4K stack driver or will all us nvidia users have to stay at mm-sources-2.6.6_rc3-r1 or below
okay my converted 5336 to 5341 version of these drivers works with development-sources-2.6.6 and win4lin-sources-2.6.6 (my own modified ebuild) provided 8k kernel stack is selected. Does not work with mm-sources-2.6.6-mm1, compiles okay but does not load seg faults .. you see the turtle .. oh dear me .. ;^)
same here with 5341. I don't care, it's not official. Kill it. 5336 works ok with 2.6.6-mm1 (4k-stacks reverted.)
i've recently tried 2.6.6-mm1 + 5336. it doesn't work. wether with 8k nor with 4k stack size.
sorry, just found out, that i used the wrong kernel. i had no luck switching 4k-stacks in 2.6.6-mm1, is there no option? the nvidia module will work ok, but starting X will result in a deadlock.
Allright 2.6.6 has been released, so im going to update my kernel to that system and test the ebuild I have cobled together out of the two posted here AND the kmod.eclass. I'm not putting into the mirrors though until I have tested all permutations of usage.. that is 1) 2.6.6 Kernel -> Kouput 2) 2.6.6 Kernel with SYSSRC_OUPUT set -> Koutput 3) 2.6.5 Kernel -> addwrite 2.4 Kernels should still work as they use the .nvidia makefile and a working unmodified build process. Please be patient this should go into the tree in a few hours.
OK the ebuild just went into CVS as nvidia-kernel-5336-r3 Changing to TEST REQUEST Please test this ebuild with your kernel and comment. If no one has any problems then we can close the bug.
i guess it will not work with 2.6.6-mm1, because there's no way to set the 4k/8k-stacks.
Not if 4K stacks are selected and non-configurable no. I understand Andrews' point in forcing this issue, but I dont feel nVidia is going to roll out a driver just because the kernel team decided it didnt want an option. Big business doesnt quite work that way.
emerge nvidia-kernel-1.0.5336-r3 on linux 2.6.6 with gcc 3.4, failed,here is the error message: rm -f -f nv.o os-agp.o os-interface.o os-registry.o nv.o os-agp.o os-interface.o os-registry.o nvidia.mod.o rm -f -f build-in.o nv-linux.o *.d .*.{cmd,flags} rm -f -f nvidia.{o,ko,mod.{o,c}} nv_compiler.h *~ make[1]: Entering directory `/usr/src/linux-2.6.6' echo \#define NV_COMPILER \"`gcc -v 2>&1 | tail -n 1`\" > /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv_compiler.h CC [M] /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.o In file included from include/linux/list.h:7, from include/linux/wait.h:14, from include/asm/semaphore.h:41, from include/linux/sched.h:18, from include/linux/module.h:10, from /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv-linux.h:52, from /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:14: include/linux/prefetch.h: In function `prefetch_range': include/linux/prefetch.h:62: warning: pointer of type `void *' used in arithmetic /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c: In function `nvos_malloc_pages': /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:389: warning: use of cast expressions as lvalues is deprecated /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c: In function `nvos_create_alloc': /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:517: warning: use of cast expressions as lvalues is deprecated /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:527: warning: use of cast expressions as lvalues is deprecated /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c: At top level: /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:1207: warning: initialization from incompatible pointer type /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c: In function `nv_alloc_file_private': /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:1215: warning: use of cast expressions as lvalues is deprecated /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:1226: warning: use of cast expressions as lvalues is deprecated /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c: In function `nv_kern_open': /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:1287: warning: use of cast expressions as lvalues is deprecated /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c: In function `nv_kern_ctl_open': /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:1936: warning: use of cast expressions as lvalues is deprecated /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c: At top level: /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2032: error: conflicting types for 'nv_set_hotkey_occurred_flag' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:350: error: previous declaration of 'nv_set_hotkey_occurred_flag' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2032: error: conflicting types for 'nv_set_hotkey_occurred_flag' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:350: error: previous declaration of 'nv_set_hotkey_occurred_flag' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2219: error: conflicting types for 'nv_find_nv_mapping' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:339: error: previous declaration of 'nv_find_nv_mapping' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2219: error: conflicting types for 'nv_find_nv_mapping' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:339: error: previous declaration of 'nv_find_nv_mapping' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2291: error: conflicting types for 'nv_find_agp_kernel_mapping' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:341: error: previous declaration of 'nv_find_agp_kernel_mapping' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2291: error: conflicting types for 'nv_find_agp_kernel_mapping' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:341: error: previous declaration of 'nv_find_agp_kernel_mapping' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2367: error: conflicting types for 'nv_get_kern_phys_address' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:342: error: previous declaration of 'nv_get_kern_phys_address' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2367: error: conflicting types for 'nv_get_kern_phys_address' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:342: error: previous declaration of 'nv_get_kern_phys_address' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2397: error: conflicting types for 'nv_get_user_phys_address' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:343: error: previous declaration of 'nv_get_user_phys_address' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2397: error: conflicting types for 'nv_get_user_phys_address' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:343: error: previous declaration of 'nv_get_user_phys_address' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2428: error: conflicting types for 'nv_alloc_pages' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:353: error: previous declaration of 'nv_alloc_pages' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2428: error: conflicting types for 'nv_alloc_pages' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:353: error: previous declaration of 'nv_alloc_pages' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2616: error: conflicting types for 'nv_free_pages' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:354: error: previous declaration of 'nv_free_pages' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2616: error: conflicting types for 'nv_free_pages' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:354: error: previous declaration of 'nv_free_pages' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2714: error: conflicting types for 'nv_lock_rm' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:345: error: previous declaration of 'nv_lock_rm' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2714: error: conflicting types for 'nv_lock_rm' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:345: error: previous declaration of 'nv_lock_rm' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2734: error: conflicting types for 'nv_unlock_rm' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:346: error: previous declaration of 'nv_unlock_rm' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2734: error: conflicting types for 'nv_unlock_rm' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:346: error: previous declaration of 'nv_unlock_rm' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2748: error: conflicting types for 'nv_lock_heap' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:347: error: previous declaration of 'nv_lock_heap' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2748: error: conflicting types for 'nv_lock_heap' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:347: error: previous declaration of 'nv_lock_heap' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2758: error: conflicting types for 'nv_unlock_heap' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:348: error: previous declaration of 'nv_unlock_heap' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2758: error: conflicting types for 'nv_unlock_heap' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:348: error: previous declaration of 'nv_unlock_heap' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2774: error: conflicting types for 'nv_post_event' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:363: error: previous declaration of 'nv_post_event' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2774: error: conflicting types for 'nv_post_event' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:363: error: previous declaration of 'nv_post_event' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2812: error: conflicting types for 'nv_get_event' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:364: error: previous declaration of 'nv_get_event' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2812: error: conflicting types for 'nv_get_event' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:364: error: previous declaration of 'nv_get_event' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2855: error: conflicting types for 'nv_agp_init' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:356: error: previous declaration of 'nv_agp_init' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2855: error: conflicting types for 'nv_agp_init' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:356: error: previous declaration of 'nv_agp_init' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2917: error: conflicting types for 'nv_agp_teardown' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:357: error: previous declaration of 'nv_agp_teardown' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2917: error: conflicting types for 'nv_agp_teardown' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:357: error: previous declaration of 'nv_agp_teardown' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2958: error: conflicting types for 'nv_agp_translate_address' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:358: error: previous declaration of 'nv_agp_translate_address' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2958: error: conflicting types for 'nv_agp_translate_address' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:358: error: previous declaration of 'nv_agp_translate_address' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2990: error: conflicting types for 'nv_int10h_call' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:351: error: previous declaration of 'nv_int10h_call' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2990: error: conflicting types for 'nv_int10h_call' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:351: error: previous declaration of 'nv_int10h_call' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2999: error: conflicting types for 'nv_start_rc_timer' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:360: error: previous declaration of 'nv_start_rc_timer' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:2999: error: conflicting types for 'nv_start_rc_timer' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:360: error: previous declaration of 'nv_start_rc_timer' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:3020: error: conflicting types for 'nv_stop_rc_timer' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:361: error: previous declaration of 'nv_stop_rc_timer' was here /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:3020: error: conflicting types for 'nv_stop_rc_timer' /var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.h:361: error: previous declaration of 'nv_stop_rc_timer' was here make[2]: *** [/var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.o] ?? 1 make[1]: *** [/var/tmp/portage/nvidia-kernel-1.0.5336-r3/work/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv] Error 2 make[1]: Leaving directory `/usr/src/linux-2.6.6' nvidia.ko failed to build! make: *** [module] Error 1
I cant reproduce that with gcc-3.4.0-r1 are you using this version or the gcc-3.4.0 version. Please try -r1 if you are not using it. If thats the build you're using please open a different bug. I specifically want this one for testing with GCC 3.3.3 (or lower as 3.4 is still masked).
Ebuild works fine with 2.6.6 and 2.6.6-mm2 for me.
-r3 as it is in portage, fixes it. I'm removing myself from this bug.
nvidia-kernel-1.0.5336-r3 ebuild works for me with kernel 2.6.6 and gcc-3.3.2-r5
Closing. Solution appears feasible.