Score:2

Wi-fi card has stopped working after fan reinstall

sn flag

I'm running 22.04.1 on a Lenovo X220 laptop. I was having some trouble with a faulty fan, and just replaced it with a new one. When I put everything back together and booted it up, my fan issues were solved, but wi-fi seems not to work anymore.

I'm concerned that either:

  1. I somehow damaged the wi-fi card when taking the computer apart, or
  2. My OS has mysteriously forgotten about the card and somehow needs to be reminded.

Any ideas on how to tell the difference between these two things? Here's what I know so far:

lspci -k shows two entries that seem relevant:

00:19.0 Ethernet controller: Intel Corporation 82579LM Gigabit Network Connection (Lewisville) (rev 04)
    Subsystem: Lenovo ThinkPad T520
    Kernel driver in use: e1000e
    Kernel modules: e1000e

for my ethernet (which works just fine), and

03:00.0 Network controller: Intel Corporation Centrino Advanced-N 6205 [Taylor Peak] (rev 34)
    Subsystem: Intel Corporation Centrino Advanced-N 6205 (802.11a/b/g/n)
    Kernel driver in use: iwlwifi
    Kernel modules: iwlwifi

for the wi-fi. I get something similar from lshw:

           *-network
                description: Network controller
                product: Centrino Advanced-N 6205 [Taylor Peak]
                vendor: Intel Corporation
                physical id: 0
                bus info: pci@0000:03:00.0
                version: 34
                width: 64 bits
                clock: 33MHz
                capabilities: pm msi pciexpress bus_master cap_list
                configuration: driver=iwlwifi latency=0
                resources: irq:30 memory:d2400000-d2401fff

It looks like my firmware is OK:

$ sudo dmesg | grep iwlwifi
[   15.853806] iwlwifi 0000:03:00.0: can't disable ASPM; OS doesn't have ASPM control
[   16.302507] iwlwifi 0000:03:00.0: loaded firmware version 18.168.6.1 6000g2a-6.ucode op_mode iwldvm

I don't know if the ASPM thing is a big deal; I ran sudo fwts aspm and it gave some warnings about L0s not enabled but no obvious failures.

However, it seems like nmcli doesn't know about the wi-fi card. If I unplug the ethernet cable (since it's not relevant here), I get:

np0s25: unavailable
        "Intel 82579LM"
        ethernet (e1000e), F0:DE:F1:62:D6:31, hw, mtu 1500

lo: unmanaged
        "lo"
        loopback (unknown), 00:00:00:00:00:00, sw, mtu 65536

Any ideas about what might be wrong here?

UPDATE: I ran the wireless-info script from this post and pasted the results at: https://pastebin.com/dEbb2i4a

mchid avatar
bo flag
To get the most helpful information needed you can run the [Wireless Info Script](https://askubuntu.com/a/425180/167115) and then post the output here or to [pastebin](http://pastebin.com/) if it's too long to post in your question.
Terrance avatar
id flag
Did you accidentally unplug the 2 antenna lines to the wifi card?
cjolley avatar
sn flag
@mchid -- Thanks for the suggestion! I just ran the script and posted results at https://pastebin.com/dEbb2i4a
cjolley avatar
sn flag
@Terrance -- Those are the black and gray wires that snap onto the wifi card, right? (You can see them around minute 4 in this video: https://www.youtube.com/watch?v=iJs01Q8EuDw) I disconnected them so that I could get to the fan, then snapped them back in when I put everything back together. Is there anything else special that needs to happen with those wires?
Terrance avatar
id flag
Yep, those are those wires. I would also try reseating the card. Also, you might need a magnifying glass to look at the connectors for the antenna wires as those things are way too easy to break or crush. Look for any physical damage to the card and cables. Also, the black wire goes to the AUX connection.
cjolley avatar
sn flag
No luck... cables and connectors looked fine (even with a magnifying glass); removing the card and putting it back in didn't have any effect.
mchid avatar
bo flag
Do you remember the name of the interface (i.e., `wlp1s0` or `wlan0`, etc)? It looks like the device has been deleted. Although, this usually resolves with a reboot, it also says managed=false in one of your config files. Anyhow, if this is the case, the following command or something very similar using the correct device name should add the device `sudo iw phy phy0 interface add wlp1s0 type namaged`
mchid avatar
bo flag
I also noticed that `iwldvm` is mentioned in dmesg but it's not listed for lsmod so you might want to enable that module if nothing else works: `sudo modprobe iwldvm`
mchid avatar
bo flag
Also also, phy name should be `phy0` and I think you should be able to verify this by running `iw list` and the first device listed should be `phy0` or something similar. Again, you might want to look into this if the `iw` command above doesn't work and then adjust the command accordingly.
cjolley avatar
sn flag
Thanks for the ideas, @mchid! `iw list` actually gives me nothing at all; it seems not to know anything about the physical device. The `iw` command you suggested returns a "command failed: No such file or directory (-2)" error -- I assume this is because that phy name doesn't correspond to anything.
mchid avatar
bo flag
@cjolley `lshw` shows the device so the system knows that it's there (sort of). What about after you enable the module `sudo modprobe iwldvm`? Then, check if it's actually enabled with `lsmod iwldvm` and if so, then try `iw list` again if it doesn't show up in NetworkManager automatically.
mchid avatar
bo flag
@cjolley If `iwldvm` doesn't load, run `dmesg -T | grep iwldvm` and `dmesg | grep iwl` to check for errors. That module should be loaded and I'm pretty sure you should experience all the same symptoms if `iwldvm` is not loaded. I tested it on a different card that uses `iwlwifi` with the `iwlmvm` firmware and then removed `iwlmvm` and ran the wireless script, checked `iw list`, no response from rfkill — all the same symptoms.
cjolley avatar
sn flag
`sudo modprobe iwldvm` gives me an error: `modprobe: ERROR: could not insert 'iwldvm': Input/output error`. The `dmesg` output only mentions `iwldvm` in the lines I pasted above in the original post. I'm starting to wonder if this is some kind of kernel issue.
cjolley avatar
sn flag
Got it! I had to downgrade my kernel from `5.15.0-56-generic` to `5.15.0-53-generic`, and then it all started working again. It looks like what was going on was some kind of conflict between that kernel and `iwldvm`, maybe?
Score:2
sn flag

Not sure if this fix will help anyone else, but I tried booting into a previous kernel version and everything worked. I followed the instructions here to set GRUB to boot into 5.15.0-53-generic by default (instead of 5.15.0-56-generic).

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.