Ubuntu 有时无法在从挂起状态唤醒时识别网卡

Ubuntu 有时无法在从挂起状态唤醒时识别网卡

问题

有时,当我将计算机从挂起状态唤醒时,它无法连接到 Wi-Fi,并且我的计算机似乎无法识别我的网卡。

更新2022-05-25:更换网卡后,此问题仍然存在。

故障排除工作

查看网络设置面板,未列出任何 Wi-Fi 网络。打开和关闭 Wi-Fi/网络无法解决问题。注销时,右上角指示栏中没有显示网络设置的符号。重新登录也无法解决问题。

重启电脑几乎总能解决问题。但是,第一次发生这种情况时,我重启电脑后,网络菜单中完全没有“启用 Wi-Fi”选项。我运行后,lshq -C network无线网卡旁边显示“未认领”。第二次重启后,网卡继续正常工作。

关于:@chili555 的评论

sudo dpkg -s linux-modules-extra-$(uname -r) | grep Status
Status: install ok installed

sudo modprobe ath9k没有产生任何输出。

更新时间:2022-05-03:问题变得更严重,卡反复掉线,重启也无法解决问题。dmesg每当卡掉线时都会显示芯片重置失败循环,在机器关机前也会短暂显示在屏幕上:


[20374.812295] ath: phy0: Unable to reset channel, reset status -22
[20374.886842] ath: phy0: DMA failed to stop in 10 ms AR_CR=0xffffffff AR_DIAG_SW=0xffffffff DMADBG_7=0xffffffff
[20374.999529] ath: phy0: Chip reset failed
[20374.999536] ath: phy0: Unable to reset channel, reset status -22
[20375.074303] ath: phy0: DMA failed to stop in 10 ms AR_CR=0xffffffff AR_DIAG_SW=0xffffffff DMADBG_7=0xffffffff
[20375.187186] ath: phy0: Chip reset failed
[20375.187192] ath: phy0: Unable to reset channel, reset status -22
[20375.262785] ath: phy0: DMA failed to stop in 10 ms AR_CR=0xffffffff AR_DIAG_SW=0xffffffff DMADBG_7=0xffffffff
[20375.377579] ath: phy0: Chip reset failed
[20375.377584] ath: phy0: Unable to reset channel, reset status -22
[20375.453445] ath: phy0: DMA failed to stop in 10 ms AR_CR=0xffffffff AR_DIAG_SW=0xffffffff DMADBG_7=0xffffffff
[20375.567989] ath: phy0: Chip reset failed

虽然我的台式电脑是固定的,但我确实将家里的 Wi-Fi 网络设置为自动频段选择。此 RedHat 错误报告表明问题发生在挂起状态下更改网络时(在移动笔记本电脑的情况下),所以我想知道问题的一部分是否是计算机在唤醒时尝试连接到与之前连接的不同的频段。

这个 Debian 主题是我能找到的唯一似乎描述了我所面临的完全相同的问题的东西,但没有任何建议(主要与笔记本电脑电源管理设置有关)有任何帮助。

我确实注意到,当我重新启动并输入磁盘解密密码时,fsck在启动操作系统之前,Ubuntu 徽标下方会短暂闪烁一个提示。我使用forcefsck提示,直到完成约 70%,然后启动操作系统,然后在我再次重新启动时完成剩余的 30%。这并没有解决问题。

更新 2022-05-25:我更换了一张新网卡(见下文的硬件规格)。这个问题发生的频率降低了,而且在重启后仍然没有消失,但这并没有完全解决问题,所以我怀疑问题出在其他地方。

当无线连接断开时,我的 CPU 使用率会反复飙升,因为(我猜)系统不断尝试重新连接但失败了。我的dmesg错误似乎也随着新网卡而发生了变化:

[66147.257420] iwlwifi 0000:04:00.0: SecBoot CPU1 Status: 0x776a, CPU2 Status: 0xb03
[66147.257439] iwlwifi 0000:04:00.0: UMAC PC: 0x8047f600
[66147.257455] iwlwifi 0000:04:00.0: LMAC PC: 0x0
[66147.257458] iwlwifi 0000:04:00.0: WRT: Collecting data: ini trigger 13 fired (delay=0ms).
[66147.257591] iwlwifi 0000:04:00.0: Loaded firmware version: 66.f1c864e0.0 ty-a0-gf-a0-66.ucode
[66147.257593] iwlwifi 0000:04:00.0: 0x00000000 | ADVANCED_SYSASSERT          
[66147.257595] iwlwifi 0000:04:00.0: 0x00000000 | trm_hw_status0
[66147.257597] iwlwifi 0000:04:00.0: 0x00000000 | trm_hw_status1
[66147.257598] iwlwifi 0000:04:00.0: 0x00000000 | branchlink2
[66147.257600] iwlwifi 0000:04:00.0: 0x00000000 | interruptlink1
[66147.257601] iwlwifi 0000:04:00.0: 0x00000000 | interruptlink2
[66147.257602] iwlwifi 0000:04:00.0: 0x00000000 | data1
[66147.257604] iwlwifi 0000:04:00.0: 0x00000000 | data2
[66147.257605] iwlwifi 0000:04:00.0: 0x00000000 | data3
[66147.257607] iwlwifi 0000:04:00.0: 0x00000000 | beacon time
[66147.257608] iwlwifi 0000:04:00.0: 0x00000000 | tsf low
[66147.257610] iwlwifi 0000:04:00.0: 0x00000000 | tsf hi
[66147.257611] iwlwifi 0000:04:00.0: 0x00000000 | time gp1
[66147.257613] iwlwifi 0000:04:00.0: 0x00000000 | time gp2
[66147.257614] iwlwifi 0000:04:00.0: 0x00000000 | uCode revision type
[66147.257615] iwlwifi 0000:04:00.0: 0x00000000 | uCode version major
[66147.257617] iwlwifi 0000:04:00.0: 0x00000000 | uCode version minor
[66147.257618] iwlwifi 0000:04:00.0: 0x00000000 | hw version
[66147.257620] iwlwifi 0000:04:00.0: 0x00000000 | board version
[66147.257621] iwlwifi 0000:04:00.0: 0x00000000 | hcmd
[66147.257623] iwlwifi 0000:04:00.0: 0x00000000 | isr0
[66147.257624] iwlwifi 0000:04:00.0: 0x00000000 | isr1
[66147.257626] iwlwifi 0000:04:00.0: 0x00000000 | isr2
[66147.257627] iwlwifi 0000:04:00.0: 0x00000000 | isr3
[66147.257629] iwlwifi 0000:04:00.0: 0x00000000 | isr4
[66147.257630] iwlwifi 0000:04:00.0: 0x00000000 | last cmd Id
[66147.257632] iwlwifi 0000:04:00.0: 0x00000000 | wait_event
[66147.257633] iwlwifi 0000:04:00.0: 0x00000000 | l2p_control
[66147.257634] iwlwifi 0000:04:00.0: 0x00000000 | l2p_duration
[66147.257636] iwlwifi 0000:04:00.0: 0x00000000 | l2p_mhvalid
[66147.257637] iwlwifi 0000:04:00.0: 0x00000000 | l2p_addr_match
[66147.257639] iwlwifi 0000:04:00.0: 0x00000000 | lmpm_pmg_sel
[66147.257640] iwlwifi 0000:04:00.0: 0x00000000 | timestamp
[66147.257642] iwlwifi 0000:04:00.0: 0x00000000 | flow_handler
[66147.257690] iwlwifi 0000:04:00.0: Start IWL Error Log Dump:
[66147.257692] iwlwifi 0000:04:00.0: Transport status: 0x00000042, valid: 7
[66147.257694] iwlwifi 0000:04:00.0: 0x201013F2 | ADVANCED_SYSASSERT
[66147.257695] iwlwifi 0000:04:00.0: 0x00000000 | umac branchlink1
[66147.257697] iwlwifi 0000:04:00.0: 0x8045DFC6 | umac branchlink2
[66147.257699] iwlwifi 0000:04:00.0: 0x00000000 | umac interruptlink1
[66147.257700] iwlwifi 0000:04:00.0: 0x00000000 | umac interruptlink2
[66147.257702] iwlwifi 0000:04:00.0: 0x0000000C | umac data1
[66147.257703] iwlwifi 0000:04:00.0: 0x00040000 | umac data2
[66147.257705] iwlwifi 0000:04:00.0: 0xDEADBEEF | umac data3
[66147.257706] iwlwifi 0000:04:00.0: 0x00000042 | umac major
[66147.257708] iwlwifi 0000:04:00.0: 0xF1C864E0 | umac minor
[66147.257709] iwlwifi 0000:04:00.0: 0x000121C9 | frame pointer
[66147.257711] iwlwifi 0000:04:00.0: 0xC0887F34 | stack pointer
[66147.257712] iwlwifi 0000:04:00.0: 0x00000000 | last host cmd
[66147.257714] iwlwifi 0000:04:00.0: 0x00000000 | isr status reg
[66147.257728] iwlwifi 0000:04:00.0: IML/ROM dump:
[66147.257729] iwlwifi 0000:04:00.0: 0x00000B03 | IML/ROM error/state
[66147.257743] iwlwifi 0000:04:00.0: 0x0000776A | IML/ROM data1
[66147.257757] iwlwifi 0000:04:00.0: 0x00000080 | IML/ROM WFPM_AUTH_KEY_0
[66147.257765] iwlwifi 0000:04:00.0: Fseq Registers:
[66147.257770] iwlwifi 0000:04:00.0: 0x60000100 | FSEQ_ERROR_CODE
[66147.257775] iwlwifi 0000:04:00.0: 0x00440005 | FSEQ_TOP_INIT_VERSION
[66147.257781] iwlwifi 0000:04:00.0: 0x00080009 | FSEQ_CNVIO_INIT_VERSION
[66147.257786] iwlwifi 0000:04:00.0: 0x0000A652 | FSEQ_OTP_VERSION
[66147.257791] iwlwifi 0000:04:00.0: 0x00000002 | FSEQ_TOP_CONTENT_VERSION
[66147.257796] iwlwifi 0000:04:00.0: 0x4552414E | FSEQ_ALIVE_TOKEN
[66147.257801] iwlwifi 0000:04:00.0: 0x00400410 | FSEQ_CNVI_ID
[66147.257806] iwlwifi 0000:04:00.0: 0x00400410 | FSEQ_CNVR_ID
[66147.257811] iwlwifi 0000:04:00.0: 0x00400410 | CNVI_AUX_MISC_CHIP
[66147.257818] iwlwifi 0000:04:00.0: 0x00400410 | CNVR_AUX_MISC_CHIP
[66147.257825] iwlwifi 0000:04:00.0: 0x00009061 | CNVR_SCU_SD_REGS_SD_REG_DIG_DCDC_VTRIM
[66147.257833] iwlwifi 0000:04:00.0: 0x00000061 | CNVR_SCU_SD_REGS_SD_REG_ACTIVE_VDIG_MIRROR
[66147.257837] iwlwifi 0000:04:00.0: Failed to start RT ucode: -110
[66147.257839] iwlwifi 0000:04:00.0: Failed to start RT ucode: -110
[66147.257840] iwlwifi 0000:04:00.0: WRT: Collecting data: ini trigger 13 fired (delay=0ms).
[66147.929144] ata19: SATA link down (SStatus 0 SControl 300)
[66149.012674] ata19: SATA link down (SStatus 0 SControl 300)
[66149.202661] iwlwifi 0000:04:00.0: mac start retry 2

硬件规格

  • 网卡:Qualcomm Atheros AR9287 PCI-E 网卡(使用~10年)更换为TP-Link ARCHER TX50E AX3000
  • 操作系统:Ubuntu 21.10升级至 Ubuntu 22.04

答案1

请参阅:https://bugs.archlinux.org/task/73387 

请尝试重命名从 -66 开始的所有固件文件,以使驱动程序加载 -63。检查:

 ls /usr/lib/firmware | grep ty-a0-gf-a0 

重命名所有比 -63 更新的内容: 

cd /usr/lib/firmware 
sudo mv iwlwifi-ty-a0-gf-a0-66.ucode iwlwifi-ty-a0-gf-a0-66.bak 

如果存在,请重复上述步骤,以检查版本 -67、-68 和 -71。重新启动并再次检查: 

sudo dmesg | grep iwl 

有沒有改善?

请注意,linux-firmware 软件包会不时更新。当发生这种情况时,您的 .bak 文件将被覆盖,您的无线设备将再次停止工作。在这种情况下,请重复上述步骤并重新启动。

相关内容