Qualcomm Atheros 设备找不到频道 13 WiFi(Ubuntu 16.04.2)

Qualcomm Atheros 设备找不到频道 13 WiFi(Ubuntu 16.04.2)

因此,我有如上所述的特定 WLAN 适配器 (168c:0042 rev 31),但如果将频道设置为 13,我无法在 WiFi 网络列表中找到我的 WiFi(如果我将其设置为 < 13,我可以找到它,但其他频道上有太多 WiFi 网络,它们只是弄乱了我的,下载速度变得非常慢)。我已将我的区域设置为相应的区域sudo iw reg set(我相当确定支持频道 13),但问题仍然存在。我想知道问题的根源是否是任何驱动程序(当前使用 ath10k)。

编辑1:输出iw list | grep Freq -A14

Frequencies:
            * 2412 MHz [1] (20.0 dBm)
            * 2417 MHz [2] (20.0 dBm)
            * 2422 MHz [3] (20.0 dBm)
            * 2427 MHz [4] (20.0 dBm)
            * 2432 MHz [5] (20.0 dBm)
            * 2437 MHz [6] (20.0 dBm)
            * 2442 MHz [7] (20.0 dBm)
            * 2447 MHz [8] (20.0 dBm)
            * 2452 MHz [9] (20.0 dBm)
            * 2457 MHz [10] (20.0 dBm)
            * 2462 MHz [11] (20.0 dBm)
            * 2467 MHz [12] (20.0 dBm)
            * 2472 MHz [13] (disabled)
            * 2484 MHz [14] (disabled)
--
        Frequencies:
            * 5180 MHz [36] (20.0 dBm) (no IR)
            * 5200 MHz [40] (20.0 dBm) (no IR)
            * 5220 MHz [44] (20.0 dBm) (no IR)
            * 5240 MHz [48] (20.0 dBm) (no IR)
            * 5260 MHz [52] (20.0 dBm) (no IR, radar detection)
              DFS state: usable (for 103 sec)
              DFS CAC time: 60000 ms
            * 5280 MHz [56] (20.0 dBm) (no IR, radar detection)
              DFS state: usable (for 103 sec)
              DFS CAC time: 60000 ms
            * 5300 MHz [60] (20.0 dBm) (no IR, radar detection)
              DFS state: usable (for 103 sec)
              DFS CAC time: 60000 ms
            * 5320 MHz [64] (20.0 dBm) (no IR, radar detection)

编辑2:输出iw reg get

country GR: DFS-ETSI
    (2402 - 2482 @ 40), (N/A, 20), (N/A)
    (5170 - 5250 @ 80), (N/A, 20), (N/A)
    (5250 - 5330 @ 80), (N/A, 20), (0 ms), DFS
    (5490 - 5710 @ 160), (N/A, 27), (0 ms), DFS
    (57000 - 66000 @ 2160), (N/A, 40), (N/A)

编辑3:输出dmesg | grep ath

[    1.960190] ath10k_pci 0000:03:00.0: pci irq msi oper_irq_mode 2 irq_mode 0 reset_mode 0
[    2.252806] ath10k_pci 0000:03:00.0: Direct firmware load for ath10k/pre-cal-pci-0000:03:00.0.bin failed with error -2
[    2.252815] ath10k_pci 0000:03:00.0: Direct firmware load for ath10k/cal-pci-0000:03:00.0.bin failed with error -2
[    2.269809] ath10k_pci 0000:03:00.0: qca9377 hw1.1 target 0x05020001 chip_id 0x003821ff sub 11ad:08a6
[    2.269811] ath10k_pci 0000:03:00.0: kconfig debug 0 debugfs 1 tracing 1 dfs 0 testmode 0
[    2.270128] ath10k_pci 0000:03:00.0: firmware ver WLAN.TF.1.0-00267-1 api 5 features ignore-otp crc32 79cea2c7
[    2.338522] ath10k_pci 0000:03:00.0: board_file api 2 bmi_id N/A crc32 93da0176
[    4.117342] ath10k_pci 0000:03:00.0: htt-ver 3.1 wmi-op 4 htt-op 3 cal otp max-sta 32 raw 0 hwcrypto 1
[    4.123902] ath: EEPROM regdomain: 0x69
[    4.123903] ath: EEPROM indicates we should expect a direct regpair map
[    4.123905] ath: Country alpha2 being used: 00
[    4.123905] ath: Regpair used: 0x69
[    4.128498] ath10k_pci 0000:03:00.0 wlp3s0: renamed from wlan0

答案1

您需要在软件源中启用源代码存储库,并确保 build-essential 与内核头文件一起安装。您还需要在 BIOS 中禁用安全启动

sudo apt-get install build-essential linux-headers-generic

然后我们就可以下载内核源代码了

apt-get source linux-image-$(uname -r)

然后我们可以导航到 ath 文件夹

cd linux-hwe-4.8.0/drivers/net/wireless/ath

使用 gedit 打开我们需要更改的文件

gedit regd.c

到第 235-237 行并更改

   case 0x66:
   case 0x69:
      return &ath_world_regdom_66_69;

   case 0x66:
      return &ath_world_regdom_66_69;
   case 0x69:
      return &ath_world_regdom_60_61_62;
确保缩进匹配,大小写应从TAB左边开始,返回应为 2TAB左边开始两个,然后保存文件并退出 gedit。然后我们可以用

make -C /lib/modules/$(uname -r)/build M=$(pwd) modules

如果更改正确,它应该可以编译。然后我们可以复制原始模块

sudo mv /lib/modules/$(uname -r)/kernel/drivers/net/wireless/ath/ath.ko /lib/modules/$(uname -r)/kernel/drivers/net/wireless/ath/ath.ko.bak
然后我们可以将新模块复制到内核
sudo cp ath.ko /lib/modules/$(uname -r)/kernel/drivers/net/wireless/ath/ath.ko

重启

内核更新后需要重新执行此操作,并且您需要

cd linux-hwe-4.8.0/drivers/net/wireless/ath
make -C /lib/modules/$(uname -r)/build M=$(pwd) clean
make -C /lib/modules/$(uname -r)/build M=$(pwd) modules
sudo mv /lib/modules/$(uname -r)/kernel/drivers/net/wireless/ath/ath.ko /lib/modules/$(uname -r)/kernel/drivers/net/wireless/ath/ath.ko.bak
sudo cp ath.ko /lib/modules/$(uname -r)/kernel/drivers/net/wireless/ath/ath.ko
重启后新内核将进入第 13 频道

参考:https://forums.linuxmint.com/viewtopic.php?f=53&t=236357

相关内容