Public bug reported:

Trying to build an external module with gcc 7.3.0 fails with an error
similar to:

 CC [M]  /home/user/....../ApiFunc.o
In file included from ./include/linux/mmdebug.h:5:0,
                from ./include/linux/gfp.h:5,
                from ./include/linux/slab.h:15,
                from /home/user/......./ApiFunc.c:51:
./include/linux/bug.h:5:10: fatal error: asm/bug.h: No such file or directory
#include <asm/bug.h>
         ^~~~~~~~~~~
compilation terminated.

This problem is already fixed in the linux kernel starting from version 4.17
We need to backport the following patch to Ubuntu kernel:
https://patchwork.kernel.org/patch/10309291/

Tested by me that it helps.

ProblemType: Bug
DistroRelease: Ubuntu 18.04
Package: linux-image-4.15.0-45-generic 4.15.0-45.48
ProcVersionSignature: Ubuntu 4.15.0-45.48-generic 4.15.18
Uname: Linux 4.15.0-45-generic x86_64
ApportVersion: 2.20.9-0ubuntu7.5
Architecture: amd64
AudioDevicesInUse:
 USER        PID ACCESS COMMAND
 /dev/snd/controlC0:  julia      1360 F.... pulseaudio
CurrentDesktop: ubuntu:GNOME
Date: Fri Feb  8 12:17:00 2019
InstallationDate: Installed on 2018-12-28 (41 days ago)
InstallationMedia: Ubuntu 18.04.1 LTS "Bionic Beaver" - Release amd64 (20180725)
MachineType: LENOVO 20M5003QRT
ProcEnviron:
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=ru_RU.UTF-8
 SHELL=/bin/bash
ProcFB: 0 inteldrmfb
ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-4.15.0-45-generic 
root=UUID=4384c2b9-39c0-41fe-a898-ef2c212df2e3 ro quiet splash vt.handoff=1
RelatedPackageVersions:
 linux-restricted-modules-4.15.0-45-generic N/A
 linux-backports-modules-4.15.0-45-generic  N/A
 linux-firmware                             1.173.3
SourcePackage: linux
UpgradeStatus: No upgrade log present (probably fresh install)
dmi.bios.date: 08/03/2018
dmi.bios.vendor: LENOVO
dmi.bios.version: R0RET31W (1.14 )
dmi.board.asset.tag: Not Available
dmi.board.name: 20M5003QRT
dmi.board.vendor: LENOVO
dmi.board.version: Not Defined
dmi.chassis.asset.tag: No Asset Information
dmi.chassis.type: 10
dmi.chassis.vendor: LENOVO
dmi.chassis.version: None
dmi.modalias: 
dmi:bvnLENOVO:bvrR0RET31W(1.14):bd08/03/2018:svnLENOVO:pn20M5003QRT:pvrThinkPadL380:rvnLENOVO:rn20M5003QRT:rvrNotDefined:cvnLENOVO:ct10:cvrNone:
dmi.product.family: ThinkPad L380
dmi.product.name: 20M5003QRT
dmi.product.version: ThinkPad L380
dmi.sys.vendor: LENOVO

** Affects: linux (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: amd64 apport-bug bionic

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1815176

Title:
  Out-of-tree kernel modules can't be built

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1815176/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to