greearb / ath10k-ct

Stand-alone ath10k driver based on Candela Technologies Linux kernel.
110 stars 40 forks source link

linux 5.15.5 firmware-ct cause ath10k driver to crash #193

Closed gsustek closed 2 years ago

gsustek commented 2 years ago

Please provide this info. See this link for more info on how to gather debug info: http://www.candelatech.com/ath10k-bugs.php

Description of the problem (how to configure, how to reproduce, how often it happens). kernel config - CONFIG_ATH_REG_DYNAMIC_USER_REG_HINTS=y CONFIG_ATH_REG_DYNAMIC_USER_CERT_TESTING=y CONFIG_ATH10K_DFS_CERTIFIED=y CONFIG_CFG80211_CERTIFICATION_ONUS=y patch to ath10: https://raw.githubusercontent.com/openwrt/openwrt/master/package/kernel/mac80211/patches/ath/402-ath_regd_optional.patch

Software (OS, Firmware version, kernel, driver, etc) ubuntu 20.04

Hardware (NIC chipset, platform, etc)

Atheros QCA9984

Logs (dmesg, maybe supplicant and/or hostap)

[Sat Nov 27 21:38:14 2021] ath10k 5.15 driver, optimized for CT firmware, probing pci device: 0x46. [Sat Nov 27 21:38:14 2021] ath10k_pci 0000:07:00.0: pci irq msi oper_irq_mode 2 irq_mode 0 reset_mode 0 [Sat Nov 27 21:38:14 2021] ath10k_pci 0000:07:00.0: fwcfg key: regdom val: 332 [Sat Nov 27 21:38:14 2021] ath10k_pci 0000:07:00.0: fwcfg key: dma_burst val: 0 [Sat Nov 27 21:38:14 2021] ath10k_pci 0000:07:00.0: qca9984/qca9994 hw1.0 target 0x01000000 chip_id 0x00000000 sub 168c:cafe [Sat Nov 27 21:38:14 2021] ath10k_pci 0000:07:00.0: kconfig debug 0 debugfs 1 tracing 1 dfs 0 testmode 0 [Sat Nov 27 21:38:14 2021] ath10k_pci 0000:07:00.0: firmware ver 10.4b-ct-9984-xfH-13-b1b524c8e5 api 5 features mfp,peer-flow-ctrl,peer-fixed-rate,txstatus-noack,wmi-10.x-CT,rxswcrypt-CT,ratemask-CT,regdump-CT,txrate-CT,flush-all-CT,pingpong-CT,ch-regs-CT,nop-CT,htt-mgt-CT,set-special-CT,tx-rc-CT,cust-stats-CT,CT-STA,txrate2-CT,beacon-cb-CT,wmi-block-ack-CT,wmi-bcn-rc-CT crc32 f866180c [Sat Nov 27 21:38:15 2021] ath10k_pci 0000:07:00.0: board_file api 2 bmi_id 0:31 crc32 e807b522 [Sat Nov 27 21:38:18 2021] ath10k_pci 0000:07:00.0: DANGER! You're overriding EEPROM-defined regulatory domain [Sat Nov 27 21:38:18 2021] ath10k_pci 0000:07:00.0: from: 0x0 to 0x14c (svc-ready-work) [Sat Nov 27 21:38:18 2021] ath10k_pci 0000:07:00.0: Your card was not certified to operate in the domain you chose. [Sat Nov 27 21:38:18 2021] ath10k_pci 0000:07:00.0: This might result in a violation of your local regulatory rules. [Sat Nov 27 21:38:18 2021] ath10k_pci 0000:07:00.0: Do not ever do this unless you really know what you are doing! [Sat Nov 27 21:38:18 2021] ath10k_pci 0000:07:00.0: 10.4 wmi init: vdevs: 16 peers: 48 tid: 96 [Sat Nov 27 21:38:18 2021] ath10k_pci 0000:07:00.0: msdu-desc: 2500 skid: 32 [Sat Nov 27 21:38:18 2021] ath10k_pci 0000:07:00.0: wmi print 'ChipType 1100 ChipTypeID 0 BoardID 2 P 48/48 V 16 K 144 PH 176 T 186 msdu-desc: 2500 sw-crypt: 0 ct-sta: 0' [Sat Nov 27 21:38:18 2021] ath10k_pci 0000:07:00.0: wmi print 'free: 85112 iram: 19908 sram: 12824' [Sat Nov 27 21:38:18 2021] ath10k_pci 0000:07:00.0: htt-ver 2.2 wmi-op 6 htt-op 4 cal otp max-sta 32 raw 0 hwcrypto 1 [Sat Nov 27 21:38:18 2021] ath: EEPROM regdomain: 0x814c [Sat Nov 27 21:38:18 2021] ath: EEPROM indicates we should expect a country code [Sat Nov 27 21:38:18 2021] ath: doing EEPROM country->regdmn map search [Sat Nov 27 21:38:18 2021] ath: country maps to regdmn code: 0x37 [Sat Nov 27 21:38:18 2021] ath: Country alpha2 being used: HT [Sat Nov 27 21:38:18 2021] ath: Regpair used: 0x37 [Sat Nov 27 21:38:18 2021] Modules linked in: ath10k_pci(O) ath10k_core(O) nfnetlink bridge stp llc ip6table_filter ip6_tables xt_MASQUERADE xt_nat iptable_nat nf_nat xt_TCPMSS iptable_mangle xt_limit ipt_REJECT nf_reject_ipv4 xt_tcpudp xt_conntrack nf_conntrack nf_defrag_ipv6 nf_defrag_ipv4 xt_comment iptable_filter dm_multipath scsi_dh_rdac scsi_dh_emc scsi_dh_alua snd_soc_skl snd_soc_sst_ipc snd_soc_sst_dsp snd_hda_ext_core snd_soc_acpi_intel_match snd_soc_acpi snd_soc_core ath snd_hda_codec_hdmi snd_compress ac97_bus snd_pcm_dmaengine snd_hda_intel x86_pkg_temp_thermal snd_intel_dspcfg intel_powerclamp kvm_intel snd_hda_codec snd_usb_audio snd_hda_core mac80211 kvm snd_usbmidi_lib iTCO_wdt snd_hwdep iTCO_vendor_support snd_pcm uvcvideo intel_rapl_msr irqbypass snd_seq_midi crct10dif_pclmul snd_seq_midi_event crc32_pclmul snd_rawmidi ghash_clmulni_intel processor_thermal_device_pci_legacy snd_seq videobuf2_vmalloc rapl processor_thermal_device videobuf2_memops processor_thermal_rfim intel_cstate [Sat Nov 27 21:38:18 2021] processor_thermal_mbox i2c_i801 videobuf2_v4l2 snd_seq_device processor_thermal_rapl snd_timer videobuf2_common intel_wmi_thunderbolt i2c_smbus wmi_bmof sdhci_pci serio_raw intel_rapl_common intel_lpss_pci igb videodev libarc4 snd uas mei_me int340x_thermal_zone cqhci intel_lpss usb_storage idma64 mc rtl8188fu(O) soundcore mei dca intel_soc_dts_iosf sdhci virt_dma intel_pch_thermal acpi_pad sch_fq_codel it87 hwmon_vid coretemp cuse msr parport_pc ppdev lp parport ip_tables x_tables autofs4 raid10 raid456 libcrc32c async_raid6_recov async_memcpy async_pq async_xor xor async_tx raid6_pq raid1 raid0 multipath linear i915 cec rc_core i2c_algo_bit ttm drm_kms_helper syscopyarea sysfillrect sysimgblt fb_sys_fops drm aesni_intel psmouse crypto_simd ahci cryptd libahci wmi video mac_hid [last unloaded: ath10k_core] [Sat Nov 27 21:38:18 2021] Workqueue: ath10k_wq ath10k_core_register_work [ath10k_core] [Sat Nov 27 21:38:18 2021] ? ath_reg_apply_world_flags+0x28/0xa0 [ath] [Sat Nov 27 21:38:18 2021] ath10k_mac_register+0xb51/0xf20 [ath10k_core] [Sat Nov 27 21:38:18 2021] ? ath10k_wmi_detach+0x3e/0x80 [ath10k_core] [Sat Nov 27 21:38:18 2021] ath10k_core_register_work+0x921/0xd30 [ath10k_core] [Sat Nov 27 21:38:18 2021] ath10k_pci 0000:07:00.0: failed to register ieee80211: -22 [Sat Nov 27 21:38:18 2021] ath10k_pci 0000:07:00.0: could not register to mac80211 (-22)

greearb commented 2 years ago

Did this system work on older versions? Can you try with US regdomain instead of HT?

gsustek commented 2 years ago

hi, it was working. i must warn you that my wificard has region 00 and and that is why during compilation of kernel i needed to use above stated kernel configuration. i did not apply any patch to regd.c or kernel at all...

if i change HT to US:

[Sun Nov 28 21:08:05 2021] ath10k 5.15 driver, optimized for CT firmware, probing pci device: 0x46. [Sun Nov 28 21:08:05 2021] ath10k_pci 0000:07:00.0: pci irq msi oper_irq_mode 2 irq_mode 0 reset_mode 0 [Sun Nov 28 21:08:05 2021] ath10k_pci 0000:07:00.0: fwcfg key: regdom val: 840 [Sun Nov 28 21:08:05 2021] ath10k_pci 0000:07:00.0: fwcfg key: val: [Sun Nov 28 21:08:05 2021] ath10k_pci 0000:07:00.0: Unknown fwcfg key name -::-, val: [Sun Nov 28 21:08:05 2021] ath10k_pci 0000:07:00.0: qca9984/qca9994 hw1.0 target 0x01000000 chip_id 0x00000000 sub 168c:cafe [Sun Nov 28 21:08:05 2021] ath10k_pci 0000:07:00.0: kconfig debug 0 debugfs 1 tracing 1 dfs 0 testmode 0 [Sun Nov 28 21:08:05 2021] ath10k_pci 0000:07:00.0: firmware ver 10.4-ct-9984-xfH-011-33ec52c8 api 5 features mfp,peer-flow-ctrl,txstatus-noack,wmi-10.x-CT,rxswcrypt-CT,ratemask-CT,regdump-CT,txrate-CT,flush-all-CT,pingpong-CT,ch-regs-CT,nop-CT,htt-mgt-CT,set-special-CT,tx-rc-CT,cust-stats-CT,txrate2-CT crc32 5b4f6cbc [Sun Nov 28 21:08:07 2021] ath10k_pci 0000:07:00.0: board_file api 2 bmi_id 0:31 crc32 85498734 [Sun Nov 28 21:08:09 2021] ath10k_pci 0000:07:00.0: DANGER! You're overriding EEPROM-defined regulatory domain [Sun Nov 28 21:08:09 2021] ath10k_pci 0000:07:00.0: from: 0x0 to 0x348 (svc-ready-work) [Sun Nov 28 21:08:09 2021] ath10k_pci 0000:07:00.0: Your card was not certified to operate in the domain you chose. [Sun Nov 28 21:08:09 2021] ath10k_pci 0000:07:00.0: This might result in a violation of your local regulatory rules. [Sun Nov 28 21:08:09 2021] ath10k_pci 0000:07:00.0: Do not ever do this unless you really know what you are doing! [Sun Nov 28 21:08:09 2021] ath10k_pci 0000:07:00.0: 10.4 wmi init: vdevs: 16 peers: 48 tid: 96 [Sun Nov 28 21:08:10 2021] WARNING: CPU: 2 PID: 1075 at net/wireless/core.c:636 wiphy_register+0x49c/0x9c0 [Sun Nov 28 21:08:10 2021] Modules linked in: ath10k_pci(O) ath10k_core(O) nfnetlink bridge stp llc ip6table_filter ip6_tables xt_MASQUERADE xt_nat iptable_nat nf_nat xt_TCPMSS iptable_mangle xt_limit ipt_REJECT nf_reject_ipv4 xt_tcpudp xt_conntrack nf_conntrack nf_defrag_ipv6 nf_defrag_ipv4 xt_comment iptable_filter dm_multipath scsi_dh_rdac scsi_dh_emc scsi_dh_alua snd_soc_skl snd_soc_sst_ipc snd_soc_sst_dsp snd_hda_ext_core snd_soc_acpi_intel_match snd_soc_acpi snd_soc_core x86_pkg_temp_thermal intel_powerclamp kvm_intel snd_compress snd_hda_codec_hdmi ac97_bus ath snd_pcm_dmaengine snd_hda_intel snd_intel_dspcfg snd_hda_codec mac80211 kvm snd_usb_audio snd_hda_core snd_usbmidi_lib snd_hwdep snd_pcm uvcvideo snd_seq_midi snd_seq_midi_event irqbypass snd_rawmidi crct10dif_pclmul iTCO_wdt crc32_pclmul iTCO_vendor_support intel_rapl_msr videobuf2_vmalloc snd_seq ghash_clmulni_intel videobuf2_memops rapl intel_cstate snd_seq_device videobuf2_v4l2 processor_thermal_device_pci_legacy videobuf2_common [Sun Nov 28 21:08:10 2021] snd_timer processor_thermal_device intel_wmi_thunderbolt wmi_bmof snd videodev serio_raw processor_thermal_rfim uas igb processor_thermal_mbox mei_me i2c_i801 processor_thermal_rapl mc libarc4 soundcore intel_lpss_pci i2c_smbus rtl8188fu(O) usb_storage intel_rapl_common sdhci_pci mei intel_lpss int340x_thermal_zone cqhci idma64 dca intel_pch_thermal intel_soc_dts_iosf sdhci virt_dma mac_hid acpi_pad sch_fq_codel it87 hwmon_vid coretemp cuse msr parport_pc ppdev lp parport ip_tables x_tables autofs4 raid10 raid456 libcrc32c async_raid6_recov async_memcpy async_pq async_xor xor async_tx raid6_pq raid1 raid0 multipath linear i915 cec rc_core i2c_algo_bit ttm drm_kms_helper syscopyarea sysfillrect sysimgblt fb_sys_fops drm psmouse aesni_intel crypto_simd cryptd ahci libahci wmi video [last unloaded: ath10k_core] [Sun Nov 28 21:08:10 2021] CPU: 2 PID: 1075 Comm: kworker/u16:12 Tainted: G W O 5.15.5-regfix #2 [Sun Nov 28 21:08:10 2021] Hardware name: Default string Default string/Default string, BIOS 5.13 06/17/2020 [Sun Nov 28 21:08:10 2021] Workqueue: ath10k_wq ath10k_core_register_work [ath10k_core] [Sun Nov 28 21:08:10 2021] RIP: 0010:wiphy_register+0x49c/0x9c0 [Sun Nov 28 21:08:10 2021] Code: 0f 86 73 ff ff ff 0f 0b b8 ea ff ff ff e9 a1 fc ff ff 0f 0b b8 ea ff ff ff e9 95 fc ff ff 0f 0b b8 ea ff ff ff e9 89 fc ff ff <0f> 0b b8 ea ff ff ff e9 7d fc ff ff 0f 0b b8 ea ff ff ff e9 71 fc [Sun Nov 28 21:08:10 2021] RSP: 0018:ffff996140973cc0 EFLAGS: 00010202 [Sun Nov 28 21:08:10 2021] RAX: 0000000000000002 RBX: 0000000000000001 RCX: 0000000000000001 [Sun Nov 28 21:08:10 2021] RDX: ffff8dfe589ac878 RSI: 000000000000008c RDI: ffff8dfe4cb42398 [Sun Nov 28 21:08:10 2021] RBP: ffff996140973d40 R08: 0000000000000010 R09: 0000000000000020 [Sun Nov 28 21:08:10 2021] R10: ffff8dfe4cb423b0 R11: ffff8dfe589ac878 R12: ffff8dfe4cb40300 [Sun Nov 28 21:08:10 2021] R13: 0000000000000001 R14: 0000000000000004 R15: 000000000000001b [Sun Nov 28 21:08:10 2021] FS: 0000000000000000(0000) GS:ffff8dffa5c80000(0000) knlGS:0000000000000000 [Sun Nov 28 21:08:10 2021] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [Sun Nov 28 21:08:10 2021] CR2: 00007fe40db72340 CR3: 00000001ae40a002 CR4: 00000000003706e0 [Sun Nov 28 21:08:10 2021] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 [Sun Nov 28 21:08:10 2021] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 [Sun Nov 28 21:08:10 2021] Call Trace: [Sun Nov 28 21:08:10 2021] [Sun Nov 28 21:08:10 2021] ? netdev_run_todo+0x61/0x2c0 [Sun Nov 28 21:08:10 2021] ieee80211_register_hw+0x63e/0xc50 [mac80211] [Sun Nov 28 21:08:10 2021] ? ath_reg_apply_world_flags+0x28/0xa0 [ath] [Sun Nov 28 21:08:10 2021] ath10k_mac_register+0xb51/0xf20 [ath10k_core] [Sun Nov 28 21:08:10 2021] ? ath10k_wmi_detach+0x3e/0x80 [ath10k_core] [Sun Nov 28 21:08:10 2021] ath10k_core_register_work+0x921/0xd30 [ath10k_core] [Sun Nov 28 21:08:10 2021] process_one_work+0x21d/0x400 [Sun Nov 28 21:08:10 2021] worker_thread+0x4d/0x3d0 [Sun Nov 28 21:08:10 2021] ? process_one_work+0x400/0x400 [Sun Nov 28 21:08:10 2021] kthread+0x147/0x170 [Sun Nov 28 21:08:10 2021] ? set_kthread_struct+0x40/0x40 [Sun Nov 28 21:08:10 2021] ret_from_fork+0x1f/0x30 [Sun Nov 28 21:08:10 2021] [Sun Nov 28 21:08:10 2021] ---[ end trace 053d4aa03c1c2a6e ]--- [Sun Nov 28 21:08:10 2021] ath10k_pci 0000:07:00.0: failed to register ieee80211: -22 [Sun Nov 28 21:08:10 2021] ath10k_pci 0000:07:00.0: could not register to mac80211 (-22)

gsustek commented 2 years ago

and if i remove redom = 840

[Sun Nov 28 21:09:54 2021] ath10k 5.15 driver, optimized for CT firmware, probing pci device: 0x46. [Sun Nov 28 21:09:54 2021] ath10k_pci 0000:07:00.0: pci irq msi oper_irq_mode 2 irq_mode 0 reset_mode 0 [Sun Nov 28 21:09:54 2021] ath10k_pci 0000:07:00.0: qca9984/qca9994 hw1.0 target 0x01000000 chip_id 0x00000000 sub 168c:cafe [Sun Nov 28 21:09:54 2021] ath10k_pci 0000:07:00.0: kconfig debug 0 debugfs 1 tracing 1 dfs 0 testmode 0 [Sun Nov 28 21:09:54 2021] ath10k_pci 0000:07:00.0: firmware ver 10.4-ct-9984-xfH-011-33ec52c8 api 5 features mfp,peer-flow-ctrl,txstatus-noack,wmi-10.x-CT,rxswcrypt-CT,ratemask-CT,regdump-CT,txrate-CT,flush-all-CT,pingpong-CT,ch-regs-CT,nop-CT,htt-mgt-CT,set-special-CT,tx-rc-CT,cust-stats-CT,txrate2-CT crc32 5b4f6cbc [Sun Nov 28 21:09:59 2021] ------------[ cut here ]------------ [Sun Nov 28 21:09:59 2021] WARNING: CPU: 3 PID: 1075 at net/wireless/core.c:636 wiphy_register+0x49c/0x9c0 [Sun Nov 28 21:09:59 2021] Modules linked in: ath10k_pci(O) ath10k_core(O) nfnetlink bridge stp llc ip6table_filter ip6_tables xt_MASQUERADE xt_nat iptable_nat nf_nat xt_TCPMSS iptable_mangle xt_limit ipt_REJECT nf_reject_ipv4 xt_tcpudp xt_conntrack nf_conntrack nf_defrag_ipv6 nf_defrag_ipv4 xt_comment iptable_filter dm_multipath scsi_dh_rdac scsi_dh_emc scsi_dh_alua snd_soc_skl snd_soc_sst_ipc snd_soc_sst_dsp snd_hda_ext_core snd_soc_acpi_intel_match snd_soc_acpi snd_soc_core x86_pkg_temp_thermal intel_powerclamp kvm_intel snd_compress snd_hda_codec_hdmi ac97_bus ath snd_pcm_dmaengine snd_hda_intel snd_intel_dspcfg snd_hda_codec mac80211 kvm snd_usb_audio snd_hda_core snd_usbmidi_lib snd_hwdep snd_pcm uvcvideo snd_seq_midi snd_seq_midi_event irqbypass snd_rawmidi crct10dif_pclmul iTCO_wdt crc32_pclmul iTCO_vendor_support intel_rapl_msr videobuf2_vmalloc snd_seq ghash_clmulni_intel videobuf2_memops rapl intel_cstate snd_seq_device videobuf2_v4l2 processor_thermal_device_pci_legacy videobuf2_common [Sun Nov 28 21:09:59 2021] snd_timer processor_thermal_device intel_wmi_thunderbolt wmi_bmof snd videodev serio_raw processor_thermal_rfim uas igb processor_thermal_mbox mei_me i2c_i801 processor_thermal_rapl mc libarc4 soundcore intel_lpss_pci i2c_smbus rtl8188fu(O) usb_storage intel_rapl_common sdhci_pci mei intel_lpss int340x_thermal_zone cqhci idma64 dca intel_pch_thermal intel_soc_dts_iosf sdhci virt_dma mac_hid acpi_pad sch_fq_codel it87 hwmon_vid coretemp cuse msr parport_pc ppdev lp parport ip_tables x_tables autofs4 raid10 raid456 libcrc32c async_raid6_recov async_memcpy async_pq async_xor xor async_tx raid6_pq raid1 raid0 multipath linear i915 cec rc_core i2c_algo_bit ttm drm_kms_helper syscopyarea sysfillrect sysimgblt fb_sys_fops drm psmouse aesni_intel crypto_simd cryptd ahci libahci wmi video [last unloaded: ath10k_core] [Sun Nov 28 21:09:59 2021] CPU: 3 PID: 1075 Comm: kworker/u16:12 Tainted: G W O 5.15.5-regfix #2 [Sun Nov 28 21:09:59 2021] Hardware name: Default string Default string/Default string, BIOS 5.13 06/17/2020 [Sun Nov 28 21:09:59 2021] Workqueue: ath10k_wq ath10k_core_register_work [ath10k_core] [Sun Nov 28 21:09:59 2021] RIP: 0010:wiphy_register+0x49c/0x9c0 [Sun Nov 28 21:09:59 2021] Code: 0f 86 73 ff ff ff 0f 0b b8 ea ff ff ff e9 a1 fc ff ff 0f 0b b8 ea ff ff ff e9 95 fc ff ff 0f 0b b8 ea ff ff ff e9 89 fc ff ff <0f> 0b b8 ea ff ff ff e9 7d fc ff ff 0f 0b b8 ea ff ff ff e9 71 fc [Sun Nov 28 21:09:59 2021] RSP: 0018:ffff996140973cc0 EFLAGS: 00010202 [Sun Nov 28 21:09:59 2021] RAX: 0000000000000002 RBX: 0000000000000001 RCX: 0000000000000001 [Sun Nov 28 21:09:59 2021] RDX: ffff8dfe51034708 RSI: 000000000000008c RDI: ffff8dfe4e6c2398 [Sun Nov 28 21:09:59 2021] RBP: ffff996140973d40 R08: 0000000000000010 R09: 0000000000000020 [Sun Nov 28 21:09:59 2021] R10: ffff8dfe4e6c23b0 R11: ffff8dfe51034708 R12: ffff8dfe4e6c0300 [Sun Nov 28 21:09:59 2021] R13: 0000000000000001 R14: 0000000000000004 R15: 000000000000001b [Sun Nov 28 21:09:59 2021] FS: 0000000000000000(0000) GS:ffff8dffa5cc0000(0000) knlGS:0000000000000000 [Sun Nov 28 21:09:59 2021] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [Sun Nov 28 21:09:59 2021] CR2: 000055a14c251000 CR3: 00000001ae40a006 CR4: 00000000003706e0 [Sun Nov 28 21:09:59 2021] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 [Sun Nov 28 21:09:59 2021] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 [Sun Nov 28 21:09:59 2021] Call Trace: [Sun Nov 28 21:09:59 2021] [Sun Nov 28 21:09:59 2021] ? netdev_run_todo+0x61/0x2c0 [Sun Nov 28 21:09:59 2021] ieee80211_register_hw+0x63e/0xc50 [mac80211] [Sun Nov 28 21:09:59 2021] ? ath_reg_apply_world_flags+0x28/0xa0 [ath] [Sun Nov 28 21:09:59 2021] ath10k_mac_register+0xb51/0xf20 [ath10k_core] [Sun Nov 28 21:09:59 2021] ? ath10k_wmi_detach+0x3e/0x80 [ath10k_core] [Sun Nov 28 21:09:59 2021] ath10k_core_register_work+0x921/0xd30 [ath10k_core] [Sun Nov 28 21:09:59 2021] process_one_work+0x21d/0x400 [Sun Nov 28 21:09:59 2021] worker_thread+0x4d/0x3d0 [Sun Nov 28 21:09:59 2021] ? process_one_work+0x400/0x400 [Sun Nov 28 21:09:59 2021] kthread+0x147/0x170 [Sun Nov 28 21:09:59 2021] ? set_kthread_struct+0x40/0x40 [Sun Nov 28 21:09:59 2021] ret_from_fork+0x1f/0x30 [Sun Nov 28 21:09:59 2021] [Sun Nov 28 21:09:59 2021] ---[ end trace 053d4aa03c1c2a6f ]--- [Sun Nov 28 21:09:59 2021] ath10k_pci 0000:07:00.0: failed to register ieee80211: -22 [Sun Nov 28 21:09:59 2021] ath10k_pci 0000:07:00.0: could not register to mac80211 (-22) root@u1804:/lib/firmware/ath10k/QCA9984/hw1.0#

gsustek commented 2 years ago

i even apply thi patch: ath-reg: Relax application of default world regd on my 5.15.5 which change ath.ko, but no change...

after applying above patch

[Sun Nov 28 21:50:38 2021] ath10k 5.15 driver, optimized for CT firmware, probing pci device: 0x46. [Sun Nov 28 21:50:38 2021] ath10k_pci 0000:07:00.0: pci irq msi oper_irq_mode 2 irq_mode 0 reset_mode 0 [Sun Nov 28 21:50:38 2021] ath10k_pci 0000:07:00.0: fwcfg key: regdom val: 332 [Sun Nov 28 21:50:38 2021] ath10k_pci 0000:07:00.0: qca9984/qca9994 hw1.0 target 0x01000000 chip_id 0x00000000 sub 168c:cafe [Sun Nov 28 21:50:38 2021] ath10k_pci 0000:07:00.0: kconfig debug 0 debugfs 1 tracing 1 dfs 0 testmode 0 [Sun Nov 28 21:50:38 2021] ath10k_pci 0000:07:00.0: firmware ver 10.4b-ct-9984-xfH-13-b1b524c8e5 api 5 features mfp,peer-flow-ctrl,peer-fixed-rate,txstatus-noack,wmi-10.x-CT,rxswcrypt-CT,ratemask-CT,regdump-CT,txrate-CT,flush-all-CT,pingpong-CT,ch-regs-CT,nop-CT,htt-mgt-CT,set-special-CT,tx-rc-CT,cust-stats-CT,CT-STA,txrate2-CT,beacon-cb-CT,wmi-block-ack-CT,wmi-bcn-rc-CT crc32 f866180c [Sun Nov 28 21:50:42 2021] ath10k_pci 0000:07:00.0: DANGER! You're overriding EEPROM-defined regulatory domain [Sun Nov 28 21:50:42 2021] ath10k_pci 0000:07:00.0: from: 0x0 to 0x14c (svc-ready-work) [Sun Nov 28 21:50:42 2021] ath10k_pci 0000:07:00.0: Your card was not certified to operate in the domain you chose. [Sun Nov 28 21:50:42 2021] ath10k_pci 0000:07:00.0: This might result in a violation of your local regulatory rules. [Sun Nov 28 21:50:42 2021] ath10k_pci 0000:07:00.0: Do not ever do this unless you really know what you are doing! [Sun Nov 28 21:50:42 2021] ath10k_pci 0000:07:00.0: 10.4 wmi init: vdevs: 16 peers: 48 tid: 96 [Sun Nov 28 21:50:42 2021] ath10k_pci 0000:07:00.0: msdu-desc: 2500 skid: 32 [Sun Nov 28 21:50:42 2021] ath10k_pci 0000:07:00.0: wmi print 'ChipType 1100 ChipTypeID 0 BoardID 2 P 48/48 V 16 K 144 PH 176 T 186 msdu-desc: 2500 sw-crypt: 0 ct-sta: 0' [Sun Nov 28 21:50:42 2021] ath10k_pci 0000:07:00.0: wmi print 'free: 85112 iram: 19908 sram: 12824' [Sun Nov 28 21:50:42 2021] ath10k_pci 0000:07:00.0: htt-ver 2.2 wmi-op 6 htt-op 4 cal otp max-sta 32 raw 0 hwcrypto 1 [Sun Nov 28 21:50:43 2021] ath: EEPROM regdomain: 0x814c [Sun Nov 28 21:50:43 2021] ath: EEPROM indicates we should expect a country code [Sun Nov 28 21:50:43 2021] ath: doing EEPROM country->regdmn map search [Sun Nov 28 21:50:43 2021] ath: country maps to regdmn code: 0x37 [Sun Nov 28 21:50:43 2021] ath: Country alpha2 being used: HT [Sun Nov 28 21:50:43 2021] ath: Regpair used: 0x37 [Sun Nov 28 21:50:43 2021] ath: ath: Not applying default regdom, alpha2: HT [Sun Nov 28 21:50:43 2021] ------------[ cut here ]------------ [Sun Nov 28 21:50:43 2021] WARNING: CPU: 4 PID: 281 at net/wireless/core.c:636 wiphy_register+0x49c/0x9c0 [Sun Nov 28 21:50:43 2021] Modules linked in: dm_multipath scsi_dh_rdac scsi_dh_emc scsi_dh_alua ath10k_pci(O) snd_soc_skl ath10k_core(O) snd_soc_sst_ipc snd_soc_sst_dsp snd_hda_ext_core snd_soc_acpi_intel_match snd_soc_acpi snd_soc_core snd_hda_codec_hdmi snd_compress ath ac97_bus snd_pcm_dmaengine x86_pkg_temp_thermal intel_powerclamp snd_hda_intel snd_usb_audio kvm_intel snd_intel_dspcfg mac80211 snd_hda_codec kvm snd_hda_core uvcvideo snd_usbmidi_lib snd_hwdep snd_pcm videobuf2_vmalloc snd_seq_midi snd_seq_midi_event videobuf2_memops irqbypass snd_rawmidi crct10dif_pclmul videobuf2_v4l2 crc32_pclmul iTCO_wdt snd_seq intel_rapl_msr videobuf2_common iTCO_vendor_support ghash_clmulni_intel rapl videodev snd_seq_device intel_cstate serio_raw snd_timer processor_thermal_device_pci_legacy intel_wmi_thunderbolt wmi_bmof processor_thermal_device igb processor_thermal_rfim snd i2c_i801 processor_thermal_mbox libarc4 intel_lpss_pci uas i2c_smbus processor_thermal_rapl sdhci_pci mei_me intel_lpss mc [Sun Nov 28 21:50:43 2021] rtl8188fu(O) usb_storage intel_rapl_common soundcore mei int340x_thermal_zone cqhci idma64 intel_pch_thermal intel_soc_dts_iosf dca sdhci virt_dma mac_hid acpi_pad sch_fq_codel it87 hwmon_vid coretemp cuse msr parport_pc ppdev lp parport ip_tables x_tables autofs4 raid10 raid456 libcrc32c async_raid6_recov async_memcpy async_pq async_xor xor async_tx raid6_pq raid1 raid0 multipath linear i915 cec rc_core i2c_algo_bit ttm drm_kms_helper syscopyarea sysfillrect sysimgblt fb_sys_fops drm psmouse aesni_intel crypto_simd cryptd ahci libahci wmi video [Sun Nov 28 21:50:43 2021] CPU: 4 PID: 281 Comm: kworker/u16:4 Tainted: G O 5.15.5-regfix #2 [Sun Nov 28 21:50:43 2021] Hardware name: Default string Default string/Default string, BIOS 5.13 06/17/2020 [Sun Nov 28 21:50:43 2021] Workqueue: ath10k_wq ath10k_core_register_work [ath10k_core] [Sun Nov 28 21:50:43 2021] RIP: 0010:wiphy_register+0x49c/0x9c0 [Sun Nov 28 21:50:43 2021] Code: 0f 86 73 ff ff ff 0f 0b b8 ea ff ff ff e9 a1 fc ff ff 0f 0b b8 ea ff ff ff e9 95 fc ff ff 0f 0b b8 ea ff ff ff e9 89 fc ff ff <0f> 0b b8 ea ff ff ff e9 7d fc ff ff 0f 0b b8 ea ff ff ff e9 71 fc [Sun Nov 28 21:50:43 2021] RSP: 0018:ffffa3e5009dfcc0 EFLAGS: 00010202 [Sun Nov 28 21:50:43 2021] RAX: 0000000000000002 RBX: 0000000000000001 RCX: 0000000000000001 [Sun Nov 28 21:50:43 2021] RDX: ffff986d46b255f8 RSI: 000000000000008c RDI: ffff986d5a602398 [Sun Nov 28 21:50:43 2021] RBP: ffffa3e5009dfd40 R08: 0000000000000010 R09: 0000000000000020 [Sun Nov 28 21:50:43 2021] R10: ffff986d5a6023b0 R11: ffff986d46b255f8 R12: ffff986d5a600300 [Sun Nov 28 21:50:43 2021] R13: 0000000000000001 R14: 0000000000000004 R15: 000000000000001b [Sun Nov 28 21:50:43 2021] FS: 0000000000000000(0000) GS:ffff986ea5d00000(0000) knlGS:0000000000000000 [Sun Nov 28 21:50:43 2021] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [Sun Nov 28 21:50:43 2021] CR2: 00007f013b56f421 CR3: 00000001b620a006 CR4: 00000000003706e0 [Sun Nov 28 21:50:43 2021] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 [Sun Nov 28 21:50:43 2021] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 [Sun Nov 28 21:50:43 2021] Call Trace: [Sun Nov 28 21:50:43 2021] [Sun Nov 28 21:50:43 2021] ? netdev_run_todo+0x61/0x2c0 [Sun Nov 28 21:50:43 2021] ieee80211_register_hw+0x63e/0xc50 [mac80211] [Sun Nov 28 21:50:43 2021] ? ath_reg_apply_world_flags+0x28/0xa0 [ath] [Sun Nov 28 21:50:43 2021] ath10k_mac_register+0xb51/0xf20 [ath10k_core] [Sun Nov 28 21:50:43 2021] ? ath10k_wmi_detach+0x3e/0x80 [ath10k_core] [Sun Nov 28 21:50:43 2021] ath10k_core_register_work+0x921/0xd30 [ath10k_core] [Sun Nov 28 21:50:43 2021] process_one_work+0x21d/0x400 [Sun Nov 28 21:50:43 2021] worker_thread+0x4d/0x3d0 [Sun Nov 28 21:50:43 2021] ? process_one_work+0x400/0x400 [Sun Nov 28 21:50:43 2021] kthread+0x147/0x170 [Sun Nov 28 21:50:43 2021] ? set_kthread_struct+0x40/0x40 [Sun Nov 28 21:50:43 2021] ret_from_fork+0x1f/0x30 [Sun Nov 28 21:50:43 2021] [Sun Nov 28 21:50:43 2021] ---[ end trace cded86570794aa54 ]--- [Sun Nov 28 21:50:43 2021] ath10k_pci 0000:07:00.0: failed to register ieee80211: -22 [Sun Nov 28 21:50:43 2021] ath10k_pci 0000:07:00.0: could not register to mac80211 (-22) [Sun Nov 2

gsustek commented 2 years ago

it seems that it works now!

  1. git clone git://git.launchpad.net/~ubuntu-kernel-test/ubuntu/+source/linux/+git/mainline-crack v5.15.5v
  2. git reset --hard b10c942b042c318e4d7783cd529f0fd5f468eed6v
  3. patch
  4. git apply -v ../ath10k-ct-5.15/patches/0001-wireless-Relax-beacon_int_min_gcd-and-ADHOC-check.patch
  5. git apply -v ../0404-ath-reg-Relax-application-of-default-world-regd.patch git apply -v ../0404-ath-reg-Relax-application-of-default-world-regd.patch
  6. build kernel with those connfig (CONFIG_ATH_REG_DYNAMIC_USER_REG_HINTS=y CONFIG_ATH_REG_DYNAMIC_USER_CERT_TESTING=y CONFIG_ATH10K_DFS_CERTIFIED=y CONFIG_CFG80211_CERTIFICATION_ONUS=y) It seems that is working for now!

but ping is fairly high.

64 bytes from 192.168.168.1: icmp_seq=662 ttl=64 time=12.231 ms 64 bytes from 192.168.168.1: icmp_seq=663 ttl=64 time=9.781 ms 64 bytes from 192.168.168.1: icmp_seq=664 ttl=64 time=2.943 ms 64 bytes from 192.168.168.1: icmp_seq=665 ttl=64 time=8.656 ms 64 bytes from 192.168.168.1: icmp_seq=666 ttl=64 time=8.329 ms 64 bytes from 192.168.168.1: icmp_seq=667 ttl=64 time=3.117 ms Request timeout for icmp_seq 668 64 bytes from 192.168.168.1: icmp_seq=669 ttl=64 time=2.529 ms 64 bytes from 192.168.168.1: icmp_seq=670 ttl=64 time=1.881 ms 64 bytes from 192.168.168.1: icmp_seq=671 ttl=64 time=2.522 ms 64 bytes from 192.168.168.1: icmp_seq=672 ttl=64 time=1.523 ms 64 bytes from 192.168.168.1: icmp_seq=673 ttl=64 time=9.509 ms 64 bytes from 192.168.168.1: icmp_seq=674 ttl=64 time=9.758 ms 64 bytes from 192.168.168.1: icmp_seq=675 ttl=64 time=3.261 ms 64 bytes from 192.168.168.1: icmp_seq=676 ttl=64 time=9.246 ms 64 bytes from 192.168.168.1: icmp_seq=677 ttl=64 time=15.283 ms 64 bytes from 192.168.168.1: icmp_seq=678 ttl=64 time=71.470 ms 64 bytes from 192.168.168.1: icmp_seq=679 ttl=64 time=3.129 ms 64 bytes from 192.168.168.1: icmp_seq=680 ttl=64 time=6.796 ms