Results 1 to 6 of 6
I am following the instructions to install the nvidia driver from Nvidia Driver Install - The Debian/Nvidia way - MEPIS Documentation Wiki
It falls over as it can't find package ...
- 01-05-2008 #1Just Joined!
- Join Date
- Sep 2006
- Posts
- 8
compiling nvidia driver on testing (lenny)
I am following the instructions to install the nvidia driver from Nvidia Driver Install - The Debian/Nvidia way - MEPIS Documentation Wiki
It falls over as it can't find package 'nvidia-kernel-source'
Indeed, this package exists only in etch and in sid (Debian -- Details of package nvidia-kernel-source in sid)
What is the correct thing to do ?
- 01-05-2008 #2Just Joined!
- Join Date
- Sep 2006
- Posts
- 8
According to the gents in #debian on freenode, you need to backport.
Make sure /etc/apt/sources.list has a deb-src entry that points to sid.
Get the package source by issusing
apt-get source nvidia-graphics-drivers
This source package contains nvidia-kernel-source and nvidia-kernel-source (amongst others)
One thing to do before building the source package is tp modify debian/control.in so nvidia-glx depends on your xserver-xorg-core(lenny) and not >= 2:1.4.(sid)
Then issue:
dkpg-buildpackage
and install the deb packages.
Now you can return to the original instructions (Nvidia Driver Install - The Debian/Nvidia way - MEPIS Documentation Wiki)
and it should all work.
Any comments appreciated
- 01-06-2008 #3
It should work but make sure edit sources.list file correctly.
It is amazing what you can accomplish if you do not care who gets the credit.
New Users: Read This First
- 01-06-2008 #4
why don't you just download the driver from the nvidia site? The one in the repository is not the latest.
- 01-14-2008 #5Linux Newbie
- Join Date
- Aug 2006
- Location
- england
- Posts
- 138
i used the one from nvidia no install probs except had to change gcc version
- 04-06-2008 #6Just Joined!
- Join Date
- Apr 2008
- Posts
- 1
Patch Nvidia source
Another possibility: patch Nvidia sources instead of modifying control.in
I tried to install the accelerated Nvidia drivers on a system with Debian lenny according to
NvidiaGraphicsDrivers - Debian Wiki
(I used the debian specific method)
Unfortunately there are problems with the current debian package from Nvidia (version 169.09). It has a conflict with the X server of lenny.
The older version (1.0.8776) will produce compiler error with kernel 2.6.23 and newer.
So I made a patch for version 1.0.8776 that it compiles with newer kernels.
* Install nvidia-glx_1.0.8776-4_i386.deb, nvidia-kernel-source_1.0.8776-4_i386.deb,
This will install a source tarball in /usr/src/nvidia-kernel-source.tar.gz. Unpack it in /usr/src. For example, to unpack the source tarball of the current driver:
$ cd /usr/src
# tar -zxf nvidia-kernel-source_1.0.8776-4_i386.tar.gz
* Apply patch below:
Copy everything below "------------------" into a file (e.g. nvpatch)
cd to /usr/lib/modules where the proprietary extension nvidia-kernel is located
patch -p1 < nvpatch
* Build the kernel and the nvidia kernel module:
$ cd /usr/src/linux
# make-kpkg clean
# make-kpkg kernel_image modules_image
* Install the new kernel and kernel module:
$ cd /usr/src
# dpkg -i /path/kernel-image-*.deb /path/nvidia-kernel-*.deb
-------------------------------------------------------------------
diff -Nru modules/nvidia-kernel/nv/nv-linux.h modules_lennypatch/nvidia-kernel/nv/nv-linux.h
--- modules/nvidia-kernel/nv/nv-linux.h 2007-01-05 04:51:29.000000000 +0000
+++ modules_lennypatch/nvidia-kernel/nv/nv-linux.h 2008-03-09 15:01:46.000000000 +0000
@@ -31,6 +31,16 @@
# error This driver does not support development kernels!
#endif
+// #include "conftest.h"
+
+// #if defined(KERNEL_2_4)
+#if 1
+#define NV_KMEM_CACHE_CREATE_PRESENT
+#define NV_KMEM_CACHE_CREATE_ARGUMENT_COUNT 6
+#define NV_IRQ_HANDLER_T_TAKES_PTREGS
+#endif
+
+
#if defined (CONFIG_SMP) && !defined (__SMP__)
#define __SMP__
#endif
@@ -506,17 +516,40 @@
free_pages(ptr, order); \
}
+/*
#define NV_KMEM_CACHE_CREATE(kmem_cache, name, type) \
{ \
kmem_cache = kmem_cache_create(name, sizeof(type), \
0, 0, NULL, NULL); \
}
+*/
+#if defined(NV_KMEM_CACHE_CREATE_PRESENT)
+#if (NV_KMEM_CACHE_CREATE_ARGUMENT_COUNT == 6)
+// taken
+#define NV_KMEM_CACHE_CREATE(kmem_cache, name, type) \
+ { \
+ kmem_cache = kmem_cache_create(name, sizeof(type), \
+ 0, 0, /* NULL, */ NULL); \
+ }
+#elif (NV_KMEM_CACHE_CREATE_ARGUMENT_COUNT == 5)
+#define NV_KMEM_CACHE_CREATE(kmem_cache, name, type) \
+ { \
+ kmem_cache = kmem_cache_create(name, sizeof(type), \
+ 0, 0, NULL); \
+ }
+#else
+//#error "NV_KMEM_CACHE_CREATE_ARGUMENT_COUNT value unrecognized!"
+#endif
#define NV_KMEM_CACHE_DESTROY(kmem_cache) \
{ \
kmem_cache_destroy(kmem_cache); \
kmem_cache = NULL; \
}
+#else
+//#error "NV_KMEM_CACHE_CREATE() undefined (kmem_cache_create() unavailable)!"
+#endif
+
#define NV_KMEM_CACHE_ALLOC(ptr, kmem_cache, type) \
{ \
diff -Nru modules/nvidia-kernel/nv/nv.c modules_lennypatch/nvidia-kernel/nv/nv.c
--- modules/nvidia-kernel/nv/nv.c 2007-01-05 04:51:29.000000000 +0000
+++ modules_lennypatch/nvidia-kernel/nv/nv.c 2008-03-09 15:06:24.000000000 +0000
@@ -99,7 +99,8 @@
int nv_use_cpa = 1;
#endif
-static kmem_cache_t *nv_pte_t_cache = NULL;
+// V8776: static kmem_cache_t *nv_pte_t_cache = NULL;
+static void *nv_pte_t_cache = NULL;
// allow an easy way to convert all debug printfs related to events
// back and forth between 'info' and 'errors'
@@ -1453,8 +1454,9 @@
if (apm_nv_dev[i] != NULL) pm_unregister(apm_nv_dev[i]);
#endif
- if (unregister_chrdev(nv_major, "nvidia") < 0)
- nv_printf(NV_DBG_ERRORS, "NVRM: unregister nv chrdev failed\n");
+ /* if (unregister_chrdev(nv_major, "nvidia") < 0) */
+ // nv_printf(NV_DBG_ERRORS, "NVRM: unregister nv chrdev failed\n");
+ unregister_chrdev(nv_major, "nvidia");
for (i = 0; i < num_nv_devices; i++)
{
@@ -1478,8 +1480,9 @@
nv_printf(NV_DBG_INFO, "NVRM: nvidia_exit_module\n");
- if (unregister_chrdev(nv_major, "nvidia") < 0)
- nv_printf(NV_DBG_ERRORS, "NVRM: unregister nv chrdev failed\n");
+ /* if (unregister_chrdev(nv_major, "nvidia") < 0) */
+ // nv_printf(NV_DBG_ERRORS, "NVRM: unregister nv chrdev failed\n");
+ unregister_chrdev(nv_major, "nvidia");
for (i = 0; i < num_nv_devices; i++)
{




