4

My question is two fold.

  1. Why does a kernel update knock out my WIFI? I am interested in the details please, the mechanism that is at work to knock it out.

  2. Is there a way I can keep this from happening? Again details, I have no computer skills I don't know scripts etc.

Background Information

I have experienced three times that a kernel update has knocked out my wifi on this same computer. 20.04 LTS

  1. The first time I found a solution on AU, can't find link anymore, via the Tomaspinho github driver page and #that worked. I downloaded the driver zip file manually, unzipped and renamed the folder from RTL8821CE-Master to RTL8821CE then cd Downloads/rtl8821ce/ Or Right clicked on folder opened terminal

sudo apt install bc module-assistant build-essential dkms

sudo m-a prepare

sudo ./dkms-install.sh

reboot

  1. The second time this happened the first solution didn't work. I found another solution via AU using the following commands:

sudo apt remove rtl8821ce-dkms && sudo apt install rtl8821ce-dkms

reboot

  1. The third time the kernel update knocked out my WIFI I used the second solution again but it failed, #did not work. I tried the first solution again - #that failed too.

After several hours of research to find a solution and found none I resolved to the notion that I will keep my phone tethered to my computer forever and just not deal with the situation going into the future. With that idea in mind I removed the driver one last time with the command:

sudo apt remove rtl8821ce-dkms

reboot

The WIFI is working now... How did that happen? I don't know.

5.13.0.39 was just installed as a regular update via Software Updater prior to this, occurred 04/07/22

SECUREBOOT IS OFF

I found 299 questions on AU concerning RTL8821CE many were the same type of question concerning install of the driver but none answered why the kernel update is knocking out the wifi on my machine.

Of the answers I tried None worked for me. But somehow the driver works after removing it - that I don't understand, which led me to ask this question above.

Of course if there is any information you need from my machine please let me know what and how to get it in the format you want it in, I will be happy to oblige.

Perhaps a journal of the commands I used over and again to show exactly what happened. Ask for it you shall have it, please specify the journal commands and format.

Ubuntu 20.04.4 LTS

HP Laptop 15-ef1082nr

FCC ID: TX2-rtl8821ce

IC: 6317A-rtl8821ce

**sudo lshw -C network
[sudo] password for x: 
  *-network                 
       description: Wireless interface
       product: RTL8821CE 802.11ac PCIe Wireless Network Adapter
       vendor: Realtek Semiconductor Co., Ltd.
       physical id: 0
       bus info: pci@0000:02:00.0
       logical name: wlo1
       version: 00
       serial: UN:ID:EN:TI:FI:ED
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless
       configuration: broadcast=yes driver=rtw_8821ce driverversion=5.13.0-39-generic firmware=N/A ip=192.168.0.161 latency=0 link=yes multicast=yes wireless=IEEE 802.11
       resources: irq:56 ioport:f000(size=256) memory:fce00000-fce0ffff

lspci -nnk | grep 0280 -A3
02:00.0 Network controller [0280]: Realtek Semiconductor Co., Ltd. RTL8821CE 802.11ac PCIe Wireless Network Adapter [10ec:c821]
    DeviceName: Realtek Chopard RTL8821CE 802.11ac 1x1 +BT 4.2 M.2 2230 PCI-e+USB WW
    Subsystem: Hewlett-Packard Company RTL8821CE 802.11ac PCIe Wireless Network Adapter [103c:831a]
    Kernel driver in use: rtw_8821ce

nmcli d
DEVICE  TYPE      STATE      CONNECTION 
wlo1    wifi      connected  my connection 
lo      loopback  unmanaged  --   

sudo dmesg | grep 8821
[    4.089669] Bluetooth: hci0: RTL: examining hci_ver=08 hci_rev=000c lmp_ver=08 lmp_subver=8821
[    4.096760] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_fw.bin
[    4.097817] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_config.bin
[    4.166208] rtw_8821ce 0000:02:00.0: enabling device (0000 -> 0003)
[    4.167688] rtw_8821ce 0000:02:00.0: Firmware version 24.8.0, H2C version 12
[    4.399449] 8821ce: loading out-of-tree module taints kernel.
[    4.414707] 8821ce: module verification failed: signature and/or required key missing - tainting kernel
[    4.519533] proc_dir_entry 'net/rtl8821ce' already registered
[    4.519561] Modules linked in: rtl8821ce(OE+) snd_hda_intel snd_intel_dspcfg snd_intel_sdw_acpi snd_hda_codec snd_hda_core 8821ce(OE) snd_hwdep snd_pcm snd_seq_midi snd_seq_midi_event amdgpu(+) intel_rapl_msr snd_rawmidi intel_rapl_common iommu_v2 rtw88_8821ce gpu_sched drm_ttm_helper rtw88_8821c ttm edac_mce_amd rtw88_pci btusb snd_seq drm_kms_helper btrtl btbcm snd_seq_device cec btintel snd_timer rtw88_core rc_core bluetooth kvm snd_rn_pci_acp3x i2c_algo_bit fb_sys_fops snd snd_pci_acp3x syscopyarea ecdh_generic sysfillrect ecc sysimgblt ccp joydev soundcore mac80211 crct10dif_pclmul ghash_clmulni_intel aesni_intel hp_wmi crypto_simd platform_profile sparse_keymap cryptd cfg80211 rapl input_leds uvcvideo libarc4 serio_raw hid_multitouch k10temp efi_pstore wmi_bmof videobuf2_vmalloc videobuf2_memops videobuf2_v4l2 videobuf2_common videodev mc hp_wireless mac_hid acpi_tad sch_fq_codel ipmi_devintf ipmi_msghandler msr parport_pc ppdev lp parport drm ip_tables x_tables autofs4
[    4.519748]  rtw_drv_proc_init+0x3b/0xc8 [rtl8821ce]
[    4.519884]  rtw_drv_entry+0x28/0x1000 [rtl8821ce]
[    4.520104] WARNING: CPU: 1 PID: 337 at /var/lib/dkms/rtl8821ce/5.5.2.1/build/os_dep/linux/rtw_proc.c:296 rtw_drv_proc_init+0x54/0xc8 [rtl8821ce]
[    4.520220] Modules linked in: rtl8821ce(OE+) snd_hda_intel snd_intel_dspcfg snd_intel_sdw_acpi snd_hda_codec snd_hda_core 8821ce(OE) snd_hwdep snd_pcm snd_seq_midi snd_seq_midi_event amdgpu(+) intel_rapl_msr snd_rawmidi intel_rapl_common iommu_v2 rtw88_8821ce gpu_sched drm_ttm_helper rtw88_8821c ttm edac_mce_amd rtw88_pci btusb snd_seq drm_kms_helper btrtl btbcm snd_seq_device cec btintel snd_timer rtw88_core rc_core bluetooth kvm snd_rn_pci_acp3x i2c_algo_bit fb_sys_fops snd snd_pci_acp3x syscopyarea ecdh_generic sysfillrect ecc sysimgblt ccp joydev soundcore mac80211 crct10dif_pclmul ghash_clmulni_intel aesni_intel hp_wmi crypto_simd platform_profile sparse_keymap cryptd cfg80211 rapl input_leds uvcvideo libarc4 serio_raw hid_multitouch k10temp efi_pstore wmi_bmof videobuf2_vmalloc videobuf2_memops videobuf2_v4l2 videobuf2_common videodev mc hp_wireless mac_hid acpi_tad sch_fq_codel ipmi_devintf ipmi_msghandler msr parport_pc ppdev lp parport drm ip_tables x_tables autofs4
[    4.520313] RIP: 0010:rtw_drv_proc_init+0x54/0xc8 [rtl8821ce]
[    4.520453]  rtw_drv_entry+0x28/0x1000 [rtl8821ce]
[    4.520667] Error: Driver 'rtl8821ce' is already registered, aborting...
[    4.608104] rtw_8821ce 0000:02:00.0 wlo1: renamed from wlan0
[    6.682777] rtw_8821ce 0000:02:00.0: start vif UN:ID:EN:TI:FI:ED on port 0
[   11.754652] rtw_8821ce 0000:02:00.0: sta UN:ID:EN:TI:FI:ED joined with macid 0 

uname -r
5.13.0-39-generic**

lsmod | grep 8821
8821ce               1794048  0
rtw88_8821ce           16384  0
rtw88_8821c            94208  1 rtw88_8821ce
rtw88_pci              24576  1 rtw88_8821ce
rtw88_core            200704  2 rtw88_pci,rtw88_8821c
cfg80211              888832  3 rtw88_core,mac80211,8821ce

sudo dkms status
[sudo] password for x: 
rtl8821ce, v5.5.2_34066.20200325, 5.13.0-39-generic, x86_64: built

Edit: I just want to fill in some pieces to the puzzle that led me to this unfortunate position so that others might learn from my mistake.

When this computer was new out of box I took out the SSD with Windows version "n" and replaced it with another empty new out of box SSD before ever powering on the device. I ran Ubuntu from USB Live to make sure it was in working order before installing Ubuntu 20.04.3 LTS. The WIFI worked during this Ubuntu Live test.

After the install WIFI was not available. I tethered using my phone and in haste used the first answer that met the apparent conditions. I installed the rtl8821ce driver and rebooted. This got my WIFI to work. But, this ultimately led to conflicts later as explained above.

Please use caution and patience before installing drivers, ask for help and wait for the good people of this community to help you. :)

With the steps and answer below I have a good working Wifi including the latest kernel update: 5.15.0-52 Initial kernel was 5.13.0.39

4
  • 1
    There's a driver for your WiFi in the repositories - rtl8821ce-dkms -. All it takes is installing it. Note the "dkms" means it'll be automatically built for newer kernels. That's all. Apr 8, 2022 at 8:57
  • The question is why is the kernel update knocking out the wifi. I will edit for clarity later. Apr 8, 2022 at 8:59
  • It isn't. I have the same device with the aforementioned package installed and it's running fine since the OS installation and SEVERAL kernel updates. Apr 8, 2022 at 9:03
  • I am using kernel 5.10.0-1057-oem on the laptop with rtl8821ce. The kernel driver rtw_8821ce. Wifi is functioning, bluetooth not. The bluetooth adapter is not always seen in bios as well. So, it can be bios issue, I think.
    – Mahler
    Apr 9, 2022 at 20:36

1 Answer 1

6

Your wifi is no longer working after a kernel update because the newest kernels include a built-in module rtw88_8821ce that doesn’t work very well and, moreover, conflicts with the driver that you previously downloaded and installed. Let’s remove it and blacklist it:

sudo -i
modprobe -r rtw88_8821ce
modprobe 8821ce
echo “blacklist rtw88_8821ce”  >>  /etc/modprobe.d/blacklist.conf
exit

Your wifi should now be working although it might take a reboot.

EDIT: You can verify which driver is in use by listing the modules in use and filtering for 8821:

lsmod | grep 8821

You can see what drivers that you installed by dkms:

sudo dkms status

With the result of these readings, I will suggest further steps in another edit.

This line from your dmesg suggests that two drivers are conflicting:

Error: Driver 'rtl8821ce' is already registered, aborting...

EDIT 2: In our chat, we discovered that there were three conflicting drivers present: 8821ce, rtl8821ce and the native in-kernel driver rtw88_8821ce.

We blacklisted two to see which of the three would properly drive your wireless device. We continued blacklisting and rebooting until we found that the best working driver was rtw88_8821ce. We left the blacklist.conf file in that state.

We then removed the other drivers from dkms. At the end, your wireless is working correctly.

10
  • Thanks for the information on the kernel, I looked around on bug sites and found issues into the long future including kernels 5.14, 5.15, 5.16 etc. An answer to my second question seems to be the blacklisting of all the future kernel drivers of type rtw_8821ce, is that correct? I mean once it is blacklisted that protects me from future over writes by new kernels, is that correct? A full wipe and reinstall of any Linux OS would require all of these steps to be repeated on a machine with IC RTL8821CE, is that correct? Apr 8, 2022 at 22:23
  • Your solution here Looks like I would need to re-install the tomaspinho driver after blacklisting the rtw_8821ce driver, is that correct? If not, that's even better. If so, would you mind including it into the answer you provided along with any new or specific information for anyone that has the IC RTL8821CE in their system. I could try but if I make an error it could affect many people. Thank you very much, I appreciate the time and effort you have provided to me. Apr 8, 2022 at 22:34
  • Please clarify where/how you installed the 8821ce driver mentioned in your log. "8821ce: loading out-of-tree module taints kernel." If you have it installed with dkms, there is no need to reinstall it at all.
    – chili555
    Apr 8, 2022 at 23:08
  • "once it is blacklisted that protects me from future over writes by new kernels, is that correct?" Correct. "A full wipe and reinstall of any Linux OS would require all of these steps to be repeated on a machine with IC RTL8821CE, is that correct?" That's also correct.
    – chili555
    Apr 8, 2022 at 23:10
  • 1
    I believe it will; the native in-kernel driver rtw88_8821ce is the default and there should be no other conflicts. You can try a live session to be sure.
    – chili555
    Dec 20, 2022 at 14:47

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .