kernel module failed to build [ Bad return status for module build on kernel: 5.8.0-25-generic (x86_64)]

Bug #1901196 reported by Ayush Kumar
22
This bug affects 5 people
Affects Status Importance Assigned to Milestone
nvidia-graphics-drivers-340 (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

While installing Nvidia-340 driver, I am getting the following error.

Setting up nvidia-340 (340.108-0ubuntu5) ...
dpkg: error: version '-' has bad syntax: revision number is empty
dpkg: error: version '-' has bad syntax: revision number is empty
dpkg: error: version '-' has bad syntax: revision number is empty
update-initramfs: deferring update (trigger activated)
INFO:Enable nvidia-340
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/lenovo_thinkpad
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/put_your_quirks_here
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/dell_latitude
Removing old nvidia-340-340.108 DKMS files...
Loading new nvidia-340-340.108 DKMS files...
Building for 5.8.0-25-generic
Building for architecture x86_64
Building initial module for 5.8.0-25-generic
Error! Bad return status for module build on kernel: 5.8.0-25-generic (x86_64)
Consult /var/lib/dkms/nvidia-340/340.108/build/make.log for more information.
dpkg: error processing package nvidia-340 (--configure):
 installed nvidia-340 package post-installation script subprocess returned error exit status 10
Processing triggers for libc-bin (2.32-0ubuntu3) ...
Processing triggers for initramfs-tools (0.137ubuntu12) ...
update-initramfs: Generating /boot/initrd.img-5.8.0-25-generic
Errors were encountered while processing:
 nvidia-340
E: Sub-process /usr/bin/dpkg returned an error code (1)

Revision history for this message
Ayush Kumar (thelivingdodo001) wrote :
Revision history for this message
Ayush Kumar (thelivingdodo001) wrote :

Forgot to specify some things.
Operating system: Ubuntu 20.10
Kernel: 5.8.0-25-generic
GPU card: g-105m

Revision history for this message
Leonardo (leoen25demayo) wrote :

Hello, I'm the same. I started researching and tried:
sudo dkms --verbose build -m nvidia-340 -v 340.108
and it returned the same error.

Since I still have an old kernel installed I tried:
sudo dkms --verbose build -m nvidia-340 -v 340.108 -k 5.4.0-26-generic

and it worked perfect, just for that kernel.

I don't have much knowledge, and I don't know where the error can be with the 5.8.0-25-generic kernel.

Note: I just upgraded Ubuntu to Groovy, everything worked fine except nvidia-340.

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in nvidia-graphics-drivers-340 (Ubuntu):
status: New → Confirmed
Revision history for this message
Leonardo (leoen25demayo) wrote :

I tried:

cd /usr/src/linux-headers-5.8.0-25-generic
sudo make oldconfig

   YACC scripts / kconfig / parser.tab. [Ch]
   HOSTCC scripts / kconfig / lexer.lex.o
   HOSTCC scripts / kconfig / parser.tab.o
   HOSTCC scripts / kconfig / preprocess.o
   HOSTCC scripts / kconfig / symbol.o
   HOSTCC scripts / kconfig / util.o
   HOSTLD scripts / kconfig / conf
scripts / kconfig / conf --oldconfig Kconfig
#
# configuration written to .config
#

And later:
sudo make prepare

    scripts / kconfig / conf --syncconfig Kconfig
    make [1]: *** There is no rule to build the target 'arch / x86 / tools / relocs_32.c', necessary for 'arch / x86 / tools / relocs_32.o'. High.
    make: *** [arch / x86 / Makefile: 211: archscripts] Error 2

Is it here the bug?

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.