Problem compiling legacy 304.137 kernel modules on recent kernel 4.19.7

Hello Community,

I’ve got an NVIDIA GeForce 6150 LE in my dad’s rather old Siemens Fujitsu ESPRIMO pc.
My distro is Opensuse Thumbleweed with the 4.19.7 kernel.
For the moment it runs with the “nouveau” driver and is usable, but I know it would be better with the NVIDIA drivers.
I downloaded the following legacy installer package from NVIDIA : NVIDIA-Linux-x86_64-304.137.run.
There was support until 2017 so it gave me some hope, though I know my kernel may be too bleeding edge.

Maybe some bright member/support-person can find a workaround/patch to fix this.

This is the contents of the nvidia-installer.log : (1st error in bold for clarity)

idia-installer log file ‘/var/log/nvidia-installer.log’
creation time: Sun Dec 16 20:50:05 2018
installer version: 304.137

PATH: /sbin:/usr/sbin:/usr/local/sbin:/root/bin:/usr/local/bin:/usr/bin:/bin

nvidia-installer command line:
./nvidia-installer
-a
-e
–x-module-path=/usr/lib64/xorg/modules

chdir(“./”)
Unable to load: nvidia-installer ncurses v6 user interface

Using: nvidia-installer ncurses user interface
→ Searching for system utilities:
→ found ldconfig : /sbin/ldconfig
→ found ldd : /usr/bin/ldd
→ found ld : /usr/bin/ld
→ found objcopy : /usr/bin/objcopy
→ found grep : /usr/bin/grep
→ found dmesg : /usr/bin/dmesg
→ found tail : /usr/bin/tail
→ found cut : /usr/bin/cut
→ found tr : /usr/bin/tr
→ found sed : /usr/bin/sed
→ found chcon : /usr/bin/chcon
→ found pkg-config : /usr/bin/pkg-config
→ found X : /usr/bin/X
→ Searching for module utilities:
→ found insmod : /sbin/insmod
→ found modprobe : /sbin/modprobe
→ found rmmod : /sbin/rmmod
→ found lsmod : /sbin/lsmod
→ found depmod : /sbin/depmod
→ License accepted by command line option.
→ Installing NVIDIA driver version 304.137.
→ Run distribution-provided pre-install script /usr/lib/nvidia/pre-install? (Answer: Yes)
→ Running distribution scripts
executing: ‘/usr/lib/nvidia/pre-install’…
grep: /etc/sysconfig/kernel: No such file or directory
→ done.
→ Kernel module installation path (Answer: ‘/lib/modules/4.19.7-1-default/kernel/drivers/video’)
→ Kernel module installation path: /lib/modules/4.19.7-1-default/kernel/drivers/video
→ No precompiled kernel interface was found to match your kernel; this means that the installer will need to compile a new kernel interface.
→ Checking development tools:
→ found cc : /usr/bin/cc
→ found make : /usr/bin/make
→ Performing CC sanity check with CC=“cc”.
→ Performing CC version check with CC=“cc”.
→ Kernel source path (Answer: ‘/lib/modules/4.19.7-1-default/source’)
→ Kernel source path: ‘/lib/modules/4.19.7-1-default/source’
→ Kernel output path: ‘/lib/modules/4.19.7-1-default/build’
→ Performing rivafb check.
→ Performing nvidiafb check.
→ Performing Xen check.
→ Cleaning kernel module build directory.
executing: ‘cd ./kernel; make clean’…
→ Building kernel module:
executing: ‘cd ./kernel; make module SYSSRC=/lib/modules/4.19.7-1-default/source SYSOUT=/lib/modules/4.19.7-1-default/build’…
NVIDIA: calling KBUILD…
make -C /lib/modules/4.19.7-1-default/build KBUILD_SRC=/usr/src/linux-4.19.7-1
-f /usr/src/linux-4.19.7-1/Makefile modules
test -e include/generated/autoconf.h -a -e include/config/auto.conf || (
echo >&2;
echo >&2 " ERROR: Kernel configuration is invalid.“;
echo >&2 " include/generated/autoconf.h or include/config/auto.conf are missing.”;
echo >&2 " Run ‘make oldconfig && make prepare’ on kernel src to fix it.";
echo >&2 ;
/bin/false)
mkdir -p /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/.tmp_versions ; rm -f /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/.tmp_versions/*
make -f /usr/src/linux-4.19.7-1/scripts/Makefile.build obj=/root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel
(cat /dev/null; echo kernel//root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nvidia.ko;) > /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/modules.order
cc -Wp,-MD,/root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/.nv.o.d -nostdinc -isystem /usr/lib64/gcc/x86_64-suse-linux/8/include -I/usr/src/linux-4.19.7-1/arch/x86/include -I./arch/x86/include/generated -I/usr/src/linux-4.19.7-1/include -I./include -I/usr/src/linux-4.19.7-1/arch/x86/include/uapi -I./arch/x86/include/generated/uapi -I/usr/src/linux-4.19.7-1/include/uapi -I./include/generated/uapi -include /usr/src/linux-4.19.7-1/include/linux/kconfig.h -include /usr/src/linux-4.19.7-1/include/linux/compiler_types.h -I/root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel -I/root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -fshort-wchar -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -fno-PIE -DCC_HAVE_ASM_GOTO -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m64 -falign-jumps=1 -falign-loops=1 -mno-80387 -mno-fp-ret-in-387 -mpreferred-stack-boundary=3 -mskip-rax-setup -mtune=generic -mno-red-zone -mcmodel=kernel -funit-at-a-time -DCONFIG_X86_X32_ABI -DCONFIG_
AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_FXSAVEQ=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_AVX512=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -mindirect-branch=thunk-extern -mindirect-branch-register -fno-delete-null-pointer-checks -Wno-frame-address -Wno-format-truncation -Wno-format-overflow -Wno-int-in-bool-context -O2 --param=allow-store-data-races=0 -Wframe-larger-than=2048 -fstack-protector -Wno-unused-but-set-variable -Wno-unused-const-variable -fno-var-tracking-assignments -g -gdwarf-4 -pg -mrecord-mcount -mfentry -DCC_USING_FENTRY -fno-inline-functions-called-once -Wdeclaration-after-statement -Wno-pointer-sign -Wno-stringop-truncation -fno-strict-overflow -fno-merge-all-constants -fmerge-constants -fno-stack-check -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -Werror=designated-init -f
macro-prefix-map=/usr/src/linux-4.19.7-1/= -Wno-packed-not-aligned -I/root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel -Wall -MD -Wsign-compare -Wno-cast-qual -Wno-error -D__KERNEL__ -DMODULE -DNVRM -DNV_VERSION_STRING="304.137" -Wno-unused-function -Wuninitialized -mno-red-zone -mcmodel=kernel -UDEBUG -U_DEBUG -DNDEBUG -DMODULE -DKBUILD_BASENAME=‘“nv”’ -DKBUILD_MODNAME=‘“nvidia”’ -c -o /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/.tmp_nv.o /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv.c
In file included from /usr/src/linux-4.19.7-1/include/linux/byteorder/little_endian.h:11,
from /usr/src/linux-4.19.7-1/arch/x86/include/uapi/asm/byteorder.h:5,
from /usr/src/linux-4.19.7-1/include/asm-generic/bitops/le.h:6,
from /usr/src/linux-4.19.7-1/arch/x86/include/asm/bitops.h:521,
from /usr/src/linux-4.19.7-1/include/linux/bitops.h:19,
from /usr/src/linux-4.19.7-1/include/linux/kernel.h:11,
from /usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:45,
from /usr/src/linux-4.19.7-1/arch/x86/include/asm/current.h:6,
from /usr/src/linux-4.19.7-1/include/linux/sched.h:12,
from /usr/src/linux-4.19.7-1/include/linux/utsname.h:6,
from /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv-linux.h:40,
from /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv.c:13:
/usr/src/linux-4.19.7-1/include/linux/byteorder/generic.h: In function ‘cpu_to_be32_array’:
/usr/src/linux-4.19.7-1/include/linux/byteorder/generic.h:195:16: warning: comparison of integer expressions of different signedness: ‘int’ and ‘size_t’ {aka ‘long unsigned int’} [-Wsign-compare]
for (i = 0; i < len; i++)
^
/usr/src/linux-4.19.7-1/include/linux/byteorder/generic.h: In function ‘be32_to_cpu_array’:
/usr/src/linux-4.19.7-1/include/linux/byteorder/generic.h:203:16: warning: comparison of integer expressions of different signedness: ‘int’ and ‘size_t’ {aka ‘long unsigned int’} [-Wsign-compare]
for (i = 0; i < len; i++)
^
In file included from /usr/src/linux-4.19.7-1/arch/x86/include/asm/current.h:5,
from /usr/src/linux-4.19.7-1/include/linux/sched.h:12,
from /usr/src/linux-4.19.7-1/include/linux/utsname.h:6,
from /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv-linux.h:40,
from /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv.c:13:
/usr/src/linux-4.19.7-1/include/linux/thread_info.h: In function ‘check_copy_size’:
/usr/src/linux-4.19.7-1/include/linux/thread_info.h:141:29: warning: comparison of integer expressions of different signedness: ‘int’ and ‘size_t’ {aka ‘long unsigned int’} [-Wsign-compare]
if (unlikely(sz >= 0 && sz < bytes)) {
^
/usr/src/linux-4.19.7-1/include/linux/compiler.h:77:42: note: in definition of macro ‘unlikely’
# define unlikely(x) __builtin_expect(!!(x), 0)
^
/usr/src/linux-4.19.7-1/include/asm-generic/qrwlock.h: In function ‘queued_write_trylock’:
/usr/src/linux-4.19.7-1/include/asm-generic/qrwlock.h:75:36: warning: comparison of integer expressions of different signedness: ‘int’ and ‘u32’ {aka ‘unsigned int’} [-Wsign-compare]
cnts, cnts | _QW_LOCKED) == cnts);
^~
/usr/src/linux-4.19.7-1/include/linux/compiler.h:76:40: note: in definition of macro ‘likely’
# define likely(x) __builtin_expect(!!(x), 1)
^
/usr/src/linux-4.19.7-1/include/linux/mmzone.h: In function ‘next_zones_zonelist’:
/usr/src/linux-4.19.7-1/include/linux/mmzone.h:984:44: warning: comparison of integer expressions of different signedness: ‘int’ and ‘enum zone_type’ [-Wsign-compare]
if (likely(!nodes && zonelist_zone_idx(z) <= highest_zoneidx))
^~
/usr/src/linux-4.19.7-1/include/linux/compiler.h:76:40: note: in definition of macro ‘likely’
# define likely(x) __builtin_expect(!!(x), 1)
^
In file included from /usr/src/linux-4.19.7-1/arch/x86/include/asm/current.h:6,
from /usr/src/linux-4.19.7-1/include/linux/sched.h:12,
from /usr/src/linux-4.19.7-1/include/linux/utsname.h:6,
from /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv-linux.h:40,
from /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv.c:13:
/usr/src/linux-4.19.7-1/include/linux/percpu-refcount.h: In function ‘percpu_ref_get_many’:
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:131:31: warning: comparison of integer expressions of different signedness: ‘long unsigned int’ and ‘int’ [-Wsign-compare]
((val) == 1 || (val) == -1)) ?
^~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:420:34: note: in expansion of macro ‘percpu_add_op’
#define this_cpu_add_1(pcp, val) percpu_add_op((pcp), val)
^~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:379:11: note: in expansion of macro ‘this_cpu_add_1’
case 1: stem##1(variable, VA_ARGS);break;
^~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:511:33: note: in expansion of macro ‘__pcpu_size_call’
#define this_cpu_add(pcp, val) _pcpu_size_call(this_cpu_add, pcp, val)
^~~~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-refcount.h:183:3: note: in expansion of macro ‘this_cpu_add’
this_cpu_add(*percpu_count, nr);
^~~~~~~~~~~~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:131:31: warning: comparison of integer expressions of different signedness: ‘long unsigned int’ and ‘int’ [-Wsign-compare]
((val) == 1 || (val) == -1)) ?
^~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:421:34: note: in expansion of macro ‘percpu_add_op’
#define this_cpu_add_2(pcp, val) percpu_add_op((pcp), val)
^~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:380:11: note: in expansion of macro ‘this_cpu_add_2’
case 2: stem##2(variable, VA_ARGS);break;
^~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:511:33: note: in expansion of macro ‘__pcpu_size_call’
#define this_cpu_add(pcp, val) _pcpu_size_call(this_cpu_add, pcp, val)
^~~~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-refcount.h:183:3: note: in expansion of macro ‘this_cpu_add’
this_cpu_add(*percpu_count, nr);
^~~~~~~~~~~~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:131:31: warning: comparison of integer expressions of different signedness: ‘long unsigned int’ and ‘int’ [-Wsign-compare]
((val) == 1 || (val) == -1)) ?
^~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:422:34: note: in expansion of macro ‘percpu_add_op’
#define this_cpu_add_4(pcp, val) percpu_add_op((pcp), val)
^~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:381:11: note: in expansion of macro ‘this_cpu_add_4’
case 4: stem##4(variable, VA_ARGS);break;
^~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:511:33: note: in expansion of macro ‘__pcpu_size_call’
#define this_cpu_add(pcp, val) _pcpu_size_call(this_cpu_add, pcp, val)
^~~~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-refcount.h:183:3: note: in expansion of macro ‘this_cpu_add’
this_cpu_add(*percpu_count, nr);
^~~~~~~~~~~~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:131:31: warning: comparison of integer expressions of different signedness: ‘long unsigned int’ and ‘int’ [-Wsign-compare]
((val) == 1 || (val) == -1)) ?
^~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:480:35: note: in expansion of macro ‘percpu_add_op’
#define this_cpu_add_8(pcp, val) percpu_add_op((pcp), val)
^~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:382:11: note: in expansion of macro ‘this_cpu_add_8’
case 8: stem##8(variable, VA_ARGS);break;
^~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:511:33: note: in expansion of macro ‘__pcpu_size_call’
#define this_cpu_add(pcp, val) _pcpu_size_call(this_cpu_add, pcp, val)
^~~~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-refcount.h:183:3: note: in expansion of macro ‘this_cpu_add’
this_cpu_add(*percpu_count, nr);
^~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-refcount.h: In function ‘percpu_ref_put_many’:
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:131:31: warning: comparison of integer expressions of different signedness: ‘long unsigned int’ and ‘int’ [-Wsign-compare]
((val) == 1 || (val) == -1)) ?
^~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:420:34: note: in expansion of macro ‘percpu_add_op’
#define this_cpu_add_1(pcp, val) percpu_add_op((pcp), val)
^~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:379:11: note: in expansion of macro ‘this_cpu_add_1’
case 1: stem##1(variable, VA_ARGS);break;
^~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:511:33: note: in expansion of macro ‘__pcpu_size_call’
#define this_cpu_add(pcp, val) _pcpu_size_call(this_cpu_add, pcp, val)
^~~~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:521:33: note: in expansion of macro ‘this_cpu_add’
#define this_cpu_sub(pcp, val) this_cpu_add(pcp, -(typeof(pcp))(val))
^~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-refcount.h:282:3: note: in expansion of macro ‘this_cpu_sub’
this_cpu_sub(*percpu_count, nr);
^~~~~~~~~~~~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:131:31: warning: comparison of integer expressions of different signedness: ‘long unsigned int’ and ‘int’ [-Wsign-compare]
((val) == 1 || (val) == -1)) ?
^~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:421:34: note: in expansion of macro ‘percpu_add_op’
#define this_cpu_add_2(pcp, val) percpu_add_op((pcp), val)
^~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:380:11: note: in expansion of macro ‘this_cpu_add_2’
case 2: stem##2(variable, VA_ARGS);break;
^~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:511:33: note: in expansion of macro ‘__pcpu_size_call’
#define this_cpu_add(pcp, val) _pcpu_size_call(this_cpu_add, pcp, val)
^~~~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:521:33: note: in expansion of macro ‘this_cpu_add’
#define this_cpu_sub(pcp, val) this_cpu_add(pcp, -(typeof(pcp))(val))
^~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-refcount.h:282:3: note: in expansion of macro ‘this_cpu_sub’
this_cpu_sub(*percpu_count, nr);
^~~~~~~~~~~~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:131:31: warning: comparison of integer expressions of different signedness: ‘long unsigned int’ and ‘int’ [-Wsign-compare]
((val) == 1 || (val) == -1)) ?
^~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:422:34: note: in expansion of macro ‘percpu_add_op’
#define this_cpu_add_4(pcp, val) percpu_add_op((pcp), val)
^~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:381:11: note: in expansion of macro ‘this_cpu_add_4’
case 4: stem##4(variable, VA_ARGS);break;
^~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:511:33: note: in expansion of macro ‘__pcpu_size_call’
#define this_cpu_add(pcp, val) _pcpu_size_call(this_cpu_add, pcp, val)
^~~~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:521:33: note: in expansion of macro ‘this_cpu_add’
#define this_cpu_sub(pcp, val) this_cpu_add(pcp, -(typeof(pcp))(val))
^~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-refcount.h:282:3: note: in expansion of macro ‘this_cpu_sub’
this_cpu_sub(*percpu_count, nr);
^~~~~~~~~~~~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:131:31: warning: comparison of integer expressions of different signedness: ‘long unsigned int’ and ‘int’ [-Wsign-compare]
((val) == 1 || (val) == -1)) ?
^~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:480:35: note: in expansion of macro ‘percpu_add_op’
#define this_cpu_add_8(pcp, val) percpu_add_op((pcp), val)
^~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:382:11: note: in expansion of macro ‘this_cpu_add_8’
case 8: stem##8(variable, VA_ARGS);break;
^~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:511:33: note: in expansion of macro ‘__pcpu_size_call’
#define this_cpu_add(pcp, val) _pcpu_size_call(this_cpu_add, pcp, val)
^~~~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:521:33: note: in expansion of macro ‘this_cpu_add’
#define this_cpu_sub(pcp, val) this_cpu_add(pcp, -(typeof(pcp))(val))
^~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-refcount.h:282:3: note: in expansion of macro ‘this_cpu_sub’
this_cpu_sub(*percpu_count, nr);
^~~~~~~~~~~~
In file included from /usr/src/linux-4.19.7-1/include/linux/page_ref.h:7,
from /usr/src/linux-4.19.7-1/include/linux/mm.h:26,
from /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv-linux.h:82,
from /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv.c:13:
/usr/src/linux-4.19.7-1/include/linux/page-flags.h: In function ‘PagePoisoned’:
/usr/src/linux-4.19.7-1/include/linux/page-flags.h:162:21: warning: comparison of integer expressions of different signedness: ‘long unsigned int’ and ‘long int’ [-Wsign-compare]
return page->flags == PAGE_POISON_PATTERN;
^~
In file included from /usr/src/linux-4.19.7-1/arch/x86/include/asm/current.h:6,
from /usr/src/linux-4.19.7-1/include/linux/sched.h:12,
from /usr/src/linux-4.19.7-1/include/linux/utsname.h:6,
from /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv-linux.h:40,
from /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv.c:13:
/usr/src/linux-4.19.7-1/include/linux/percpu-rwsem.h: In function ‘percpu_up_read_preempt_enable’:
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:131:31: warning: comparison of integer expressions of different signedness: ‘unsigned int’ and ‘int’ [-Wsign-compare]
((val) == 1 || (val) == -1)) ?
^~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:401:34: note: in expansion of macro ‘percpu_add_op’
#define raw_cpu_add_1(pcp, val) percpu_add_op((pcp), val)
^~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:379:11: note: in expansion of macro ‘raw_cpu_add_1’
case 1: stem##1(variable, VA_ARGS);break;
^~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:424:32: note: in expansion of macro ‘__pcpu_size_call’
#define raw_cpu_add(pcp, val) _pcpu_size_call(raw_cpu_add, pcp, val)
^~~~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:460:2: note: in expansion of macro ‘raw_cpu_add’
raw_cpu_add(pcp, val);
^~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:498:34: note: in expansion of macro ‘__this_cpu_add’
#define __this_cpu_sub(pcp, val) __this_cpu_add(pcp, -(typeof(pcp))(val))
^~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:500:30: note: in expansion of macro ‘__this_cpu_sub’
#define __this_cpu_dec(pcp) __this_cpu_sub(pcp, 1)
^~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-rwsem.h:97:3: note: in expansion of macro ‘__this_cpu_dec’
__this_cpu_dec(*sem->read_count);
^~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:131:31: warning: comparison of integer expressions of different signedness: ‘unsigned int’ and ‘int’ [-Wsign-compare]
((val) == 1 || (val) == -1)) ?
^~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:402:34: note: in expansion of macro ‘percpu_add_op’
#define raw_cpu_add_2(pcp, val) percpu_add_op((pcp), val)
^~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:380:11: note: in expansion of macro ‘raw_cpu_add_2’
case 2: stem##2(variable, VA_ARGS);break;
^~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:424:32: note: in expansion of macro ‘__pcpu_size_call’
#define raw_cpu_add(pcp, val) _pcpu_size_call(raw_cpu_add, pcp, val)
^~~~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:460:2: note: in expansion of macro ‘raw_cpu_add’
raw_cpu_add(pcp, val);
^~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:498:34: note: in expansion of macro ‘__this_cpu_add’
#define __this_cpu_sub(pcp, val) __this_cpu_add(pcp, -(typeof(pcp))(val))
^~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:500:30: note: in expansion of macro ‘__this_cpu_sub’
#define __this_cpu_dec(pcp) __this_cpu_sub(pcp, 1)
^~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-rwsem.h:97:3: note: in expansion of macro ‘__this_cpu_dec’
__this_cpu_dec(*sem->read_count);
^~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:131:31: warning: comparison of integer expressions of different signedness: ‘unsigned int’ and ‘int’ [-Wsign-compare]
((val) == 1 || (val) == -1)) ?
^~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:403:34: note: in expansion of macro ‘percpu_add_op’
#define raw_cpu_add_4(pcp, val) percpu_add_op((pcp), val)
^~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:381:11: note: in expansion of macro ‘raw_cpu_add_4’
case 4: stem##4(variable, VA_ARGS);break;
^~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:424:32: note: in expansion of macro ‘__pcpu_size_call’
#define raw_cpu_add(pcp, val) _pcpu_size_call(raw_cpu_add, pcp, val)
^~~~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:460:2: note: in expansion of macro ‘raw_cpu_add’
raw_cpu_add(pcp, val);
^~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:498:34: note: in expansion of macro ‘__this_cpu_add’
#define __this_cpu_sub(pcp, val) __this_cpu_add(pcp, -(typeof(pcp))(val))
^~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:500:30: note: in expansion of macro ‘__this_cpu_sub’
#define __this_cpu_dec(pcp) __this_cpu_sub(pcp, 1)
^~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-rwsem.h:97:3: note: in expansion of macro ‘__this_cpu_dec’
__this_cpu_dec(*sem->read_count);
^~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:131:31: warning: comparison of integer expressions of different signedness: ‘unsigned int’ and ‘int’ [-Wsign-compare]
((val) == 1 || (val) == -1)) ?
^~
/usr/src/linux-4.19.7-1/arch/x86/include/asm/percpu.h:471:35: note: in expansion of macro ‘percpu_add_op’
#define raw_cpu_add_8(pcp, val) percpu_add_op((pcp), val)
^~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:382:11: note: in expansion of macro ‘raw_cpu_add_8’
case 8: stem##8(variable, VA_ARGS);break;
^~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:424:32: note: in expansion of macro ‘__pcpu_size_call’
#define raw_cpu_add(pcp, val) _pcpu_size_call(raw_cpu_add, pcp, val)
^~~~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:460:2: note: in expansion of macro ‘raw_cpu_add’
raw_cpu_add(pcp, val);
^~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:498:34: note: in expansion of macro ‘__this_cpu_add’
#define __this_cpu_sub(pcp, val) __this_cpu_add(pcp, -(typeof(pcp))(val))
^~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-defs.h:500:30: note: in expansion of macro ‘__this_cpu_sub’
#define __this_cpu_dec(pcp) __this_cpu_sub(pcp, 1)
^~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/percpu-rwsem.h:97:3: note: in expansion of macro ‘__this_cpu_dec’
__this_cpu_dec(sem->read_count);
^~~~~~~~~~~~~~
In file included from /usr/src/linux-4.19.7-1/arch/x86/include/asm/paravirt.h:17,
from /usr/src/linux-4.19.7-1/arch/x86/include/asm/irqflags.h:68,
from /usr/src/linux-4.19.7-1/include/linux/irqflags.h:16,
from /usr/src/linux-4.19.7-1/include/linux/rcupdate.h:39,
from /usr/src/linux-4.19.7-1/include/linux/rculist.h:11,
from /usr/src/linux-4.19.7-1/include/linux/pid.h:5,
from /usr/src/linux-4.19.7-1/include/linux/sched.h:14,
from /usr/src/linux-4.19.7-1/include/linux/utsname.h:6,
from /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv-linux.h:40,
from /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv.c:13:
/usr/src/linux-4.19.7-1/include/linux/vmstat.h: In function ‘zone_numa_state_snapshot’:
/usr/src/linux-4.19.7-1/include/linux/cpumask.h:243:9: warning: comparison of integer expressions of different signedness: ‘int’ and ‘unsigned int’ [-Wsign-compare]
(cpu) < nr_cpu_ids;)
^
/usr/src/linux-4.19.7-1/include/linux/cpumask.h:778:36: note: in expansion of macro ‘for_each_cpu’
#define for_each_online_cpu(cpu) for_each_cpu((cpu), cpu_online_mask)
^~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/vmstat.h:156:2: note: in expansion of macro ‘for_each_online_cpu’
for_each_online_cpu(cpu)
^~~~~~~~~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/vmstat.h: In function ‘zone_page_state_snapshot’:
/usr/src/linux-4.19.7-1/include/linux/cpumask.h:243:9: warning: comparison of integer expressions of different signedness: ‘int’ and ‘unsigned int’ [-Wsign-compare]
(cpu) < nr_cpu_ids;)
^
/usr/src/linux-4.19.7-1/include/linux/cpumask.h:778:36: note: in expansion of macro ‘for_each_cpu’
#define for_each_online_cpu(cpu) for_each_cpu((cpu), cpu_online_mask)
^~~~~~~~~~~~
/usr/src/linux-4.19.7-1/include/linux/vmstat.h:221:2: note: in expansion of macro ‘for_each_online_cpu’
for_each_online_cpu(cpu)
^~~~~~~~~~~~~~~~~~~
In file included from /usr/src/linux-4.19.7-1/include/linux/efi.h:20,
from /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv-linux.h:193,
from /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv.c:13:
/usr/src/linux-4.19.7-1/include/linux/rtc.h: In function ‘rtc_tv_nsec_ok’:
/usr/src/linux-4.19.7-1/include/linux/rtc.h:245:22: warning: comparison of integer expressions of different signedness: ‘long int’ and ‘long unsigned int’ [-Wsign-compare]
if (to_set->tv_nsec < TIME_SET_NSEC_FUZZ) {
^
/usr/src/linux-4.19.7-1/include/linux/rtc.h:250:22: warning: comparison of integer expressions of different signedness: ‘long int’ and ‘long unsigned int’ [-Wsign-compare]
if (to_set->tv_nsec > NSEC_PER_SEC - TIME_SET_NSEC_FUZZ) {
^
/root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv.c: In function ‘nv_start_rc_timer’:
/root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv.c:3032:5: error: implicit declaration of function ‘init_timer’; did you mean ‘init_timers’? [-Werror=implicit-function-declaration]
init_timer(&nvl->rc_timer);

^~~~~~~~~~
init_timers
/root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv.c:3033:28: error: assignment to ‘void (
)(struct timer_list )’ from incompatible pointer type ‘void ()(long unsigned int)’ [-Werror=incompatible-pointer-types]
nvl->rc_timer.function = nv_kern_rc_timer;
^
/root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv.c:3034:18: error: ‘struct timer_list’ has no member named ‘data’
nvl->rc_timer.data = (unsigned long) nv;
^
cc1: some warnings being treated as errors
make[4]: *** [/usr/src/linux-4.19.7-1/scripts/Makefile.build:305: /root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel/nv.o] Error 1
make[3]: *** [/usr/src/linux-4.19.7-1/Makefile:1532: module/root/Eigen_config/NVIDIA-Linux-x86_64-304.137/kernel] Error 2
make[2]: *** [Makefile:146: sub-make] Error 2
NVIDIA: left KBUILD.
nvidia.ko failed to build!
make[1]: *** [Makefile:261: module] Error 1
make: *** [makefile:59: module] Error 2
→ Error.
ERROR: Unable to build the NVIDIA kernel module.
ERROR: Installation has failed. Please see the file ‘/var/log/nvidia-installer.log’ for details. You may find suggestions on fixing installation problems in the README available on the Linux driver download page at www.nvidia.com.
→ No distribution failed-install script found.

Grtz,
Guy.

No chance. 304 has only support for Xserver 1.19, current distros ship 1.20 and there’s no patching way around it. Use something like Ubuntu 16.04, that should work.

Interesting, thx for your answer, my distro shipped xorg-x11-server-1.20.3-2.1.x86_64 indeed.
So just out of luck here.
Oh well, I’ll stick to the nouveau driver for the time being.