[Bug 2007365] Re: rtl8821ce fails to build when CONFIG_CFG80211 is not enabled for linux-kvm

Roxana Nicolescu 2007365 at bugs.launchpad.net
Thu May 11 15:45:39 UTC 2023


I tested the package on a generic 5.15 kernel and I realized it won't build at all because the exclusive kernel rule won't match 5.15 anymore because of the extra space added.
A new fix is required to solve this.

I attached a new debdiff with the proper fix.

Tested on a VM with 5.15.0-57-generic: It should build 
ubuntu at jammy:~/rtl$ sudo dpkg -i rtl8821ce-dkms_5.5.2.1-0ubuntu11~0.22.04.3_all.deb 
(Reading database ... 81589 files and directories currently installed.)
Preparing to unpack rtl8821ce-dkms_5.5.2.1-0ubuntu11~0.22.04.3_all.deb ...
Module rtl8821ce-5.5.2.1 for kernel 5.15.0-57-generic (x86_64).
Before uninstall, this module version was ACTIVE on this kernel.

rtl8821ce.ko:
 - Uninstallation
   - Deleting from: /lib/modules/5.15.0-57-generic/updates/dkms/
 - Original module
   - No original module was found for this module on this kernel.
   - Use the dkms install command to reinstall any previous module version.

/etc/modprobe.d/dkms.conf: removed 'blacklist rtw88_8821ce'
depmod...
Deleting module rtl8821ce-5.5.2.1 completely from the DKMS tree.
Unpacking rtl8821ce-dkms (5.5.2.1-0ubuntu11~0.22.04.3) over (5.5.2.1-0ubuntu11~0.22.04.3) ...
Setting up rtl8821ce-dkms (5.5.2.1-0ubuntu11~0.22.04.3) ...
Loading new rtl8821ce-5.5.2.1 DKMS files...
Building for 5.15.0-57-generic
Building initial module for 5.15.0-57-generic
EFI variables are not supported on this system
/sys/firmware/efi/efivars not found, aborting.
Done.

rtl8821ce.ko:
Running module version sanity check.
 - Original module
   - No original module exists within this kernel
 - Installation
   - Installing to /lib/modules/5.15.0-57-generic/updates/dkms/

/etc/modprobe.d/dkms.conf: added 'blacklist rtw88_8821ce'
depmod...


Also tested on a VM with linux-kvm. I should not build because modules is not there
ubuntu at jammy:~$ sudo dpkg -i rtl8821ce-dkms_5.5.2.1-0ubuntu11~0.22.04.3_all.deb 
(Reading database ... 223166 files and directories currently installed.)
Preparing to unpack rtl8821ce-dkms_5.5.2.1-0ubuntu11~0.22.04.3_all.deb ...
Deleting module rtl8821ce-5.5.2.1 completely from the DKMS tree.
Unpacking rtl8821ce-dkms (5.5.2.1-0ubuntu11~0.22.04.3) over (5.5.2.1-0ubuntu11~0.22.04.2) ...
Setting up rtl8821ce-dkms (5.5.2.1-0ubuntu11~0.22.04.3) ...
Loading new rtl8821ce-5.5.2.1 DKMS files...
Building for 5.15.0-1033-kvm 
Building initial module for 5.15.0-1033-kvm
Error! The /var/lib/dkms/rtl8821ce/5.5.2.1/5.15.0-1033-kvm/x86_64/dkms.conf for module rtl8821ce includes a BUILD_EXCLUSIVE directive which does not match this kernel/arch.
The /var/lib/dkms/rtl8821ce/5.5.2.1/5.15.0-1033-kvm/x86_64/dkms.conf for module rtl8821ce includes a BUILD_EXCLUSIVE directive which does not match this kernel/arch/config.
This indicates that it should not be built.
Skipped.

and on jammy:5.19. It should not build because it's a 5.19 not 5.15
kernel:

ubuntu at jammy:~$ sudo dpkg -i rtl8821ce-dkms_5.5.2.1-0ubuntu11~0.22.04.3_all.deb
Selecting previously unselected package rtl8821ce-dkms.
(Reading database ... 99576 files and directories currently installed.)
Preparing to unpack rtl8821ce-dkms_5.5.2.1-0ubuntu11~0.22.04.3_all.deb ...
Unpacking rtl8821ce-dkms (5.5.2.1-0ubuntu11~0.22.04.3) ...
Setting up rtl8821ce-dkms (5.5.2.1-0ubuntu11~0.22.04.3) ...
Loading new rtl8821ce-5.5.2.1 DKMS files...
Building for 5.19.0-1025-aws
Building initial module for 5.19.0-1025-aws
Error! The /var/lib/dkms/rtl8821ce/5.5.2.1/5.19.0-1025-aws/x86_64/dkms.conf for module rtl8821ce includes a BUILD_EXCLUSIVE directive which does not match this kernel/arch.
This indicates that it should not be built.
Skipped.


** Attachment added: "debdiff"
   https://bugs.launchpad.net/ubuntu/+source/rtl8821ce/+bug/2007365/+attachment/5672517/+files/debdiff

-- 
You received this bug notification because you are a member of Ubuntu
Sponsors Team, which is subscribed to the bug report.
https://bugs.launchpad.net/bugs/2007365

Title:
  rtl8821ce fails to build when CONFIG_CFG80211 is not enabled for
  linux-kvm

Status in ubuntu-kernel-tests:
  New
Status in rtl8821ce package in Ubuntu:
  Confirmed
Status in rtl8821ce source package in Jammy:
  Won't Fix

Bug description:
  [SRU Justification]

  Impact:
  jammy:linux-kvm does not have CONFIG_CFG80211 enabled.
  Module rtl8821ce-dkms requires it, otherwise build will fail.
  Build was not performed before because of this rule:

  # Only build on wifi enabled kernels
  if ! grep -q '^CONFIG_CFG80211=[ym]$' $kernel_source_dir/.config; then
  BUILD_EXCLUSIVE_KERNEL="^$"
  fi

  But in the last update: 5.5.2.1-0ubuntu11~0.22.04.1 this was overridden by
  BUILD_EXCLUSIVE_KERNEL="^5.15.*"
  instead of appending the new exclude rule.

  This lead to new regression in autopkgtest for jammy:linux-
  kvm-5.15.0-1029.34.

  Fix:
  Append the last rule:

  BUILD_EXCLUSIVE_KERNEL+=" ^5.15.*"

  Tescase:
  autopkgtest rtl8821ce fails during build with the error from below

  Regression potential:
  None. Build is skipped so no tests are performed.

  ...
  ERROR: modpost: "cfg80211_rx_mgmt_khz" [/var/lib/dkms/rtl8821ce/5.5.2.1/build/rtl8821ce.ko] undefined!
  ERROR: modpost: "cfg80211_mgmt_tx_status" [/var/lib/dkms/rtl8821ce/5.5.2.1/build/rtl8821ce.ko] undefined!
  ERROR: modpost: "wiphy_apply_custom_regulatory" [/var/lib/dkms/rtl8821ce/5.5.2.1/build/rtl8821ce.ko] undefined!
  ERROR: modpost: "__cfg80211_alloc_reply_skb" [/var/lib/dkms/rtl8821ce/5.5.2.1/build/rtl8821ce.ko] undefined!
  ERROR: modpost: "cfg80211_new_sta" [/var/lib/dkms/rtl8821ce/5.5.2.1/build/rtl8821ce.ko] undefined!
  ERROR: modpost: "cfg80211_inform_bss_frame_data" [/var/lib/dkms/rtl8821ce/5.5.2.1/build/rtl8821ce.ko] undefined!
  ERROR: modpost: "cfg80211_unlink_bss" [/var/lib/dkms/rtl8821ce/5.5.2.1/build/rtl8821ce.ko] undefined!
  ERROR: modpost: "cfg80211_connect_done" [/var/lib/dkms/rtl8821ce/5.5.2.1/build/rtl8821ce.ko] undefined!
  ERROR: modpost: "cfg80211_put_bss" [/var/lib/dkms/rtl8821ce/5.5.2.1/build/rtl8821ce.ko] undefined!
  ERROR: modpost: "cfg80211_roamed" [/var/lib/dkms/rtl8821ce/5.5.2.1/build/rtl8821ce.ko] undefined!
  WARNING: modpost: suppressed 18 unresolved symbol warnings because there were too many)
  make[2]: *** [scripts/Makefile.modpost:133: /var/lib/dkms/rtl8821ce/5.5.2.1/build/Module.symvers] Error 1
  make[2]: *** Deleting file '/var/lib/dkms/rtl8821ce/5.5.2.1/build/Module.symvers'
  make[1]: *** [Makefile:1821: modules] Error 2
  make[1]: Leaving directory '/usr/src/linux-headers-5.15.0-1029-kvm'
  make: *** [Makefile:2262: modules] Error 2
  ====================
  ./rtl8821ce/5.5.2.1/build/make.log
  autopkgtest [02:46:16]: test dkms-autopkgtest: -----------------------]
  dkms-autopkgtest     FAIL non-zero exit status 1
  autopkgtest [02:46:17]: test dkms-autopkgtest:  - - - - - - - - - - results - - - - - - - - - -
  autopkgtest [02:46:17]: @@@@@@@@@@@@@@@@@@@@ summary
  dkms-autopkgtest     FAIL non-zero exit status 1
  Creating nova instance adt-jammy-amd64-rtl8821ce-20230214-023910-lrg-root1 from image adt/ubuntu-jammy-amd64-server-20230213.img (UUID ed711e13-2823-486e-8ade-d9996e82af9a)...

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu-kernel-tests/+bug/2007365/+subscriptions




More information about the Ubuntu-sponsors mailing list