hi ,
I download the QCA 9377 driver from website which is "QCA9377.LEA.3.0_QDN_r3000017.1" . I have build the driver and copy the firmware to my board. when i insmod the mdoule. something wrong. it seems that I miss some firmware. but these firmwre not exist in download package, and im not sure. please help me . thanks!
my env:
kernel: linux 4.9.37
arch: arm
the error log:
/udisk # insmod wlan.kowlan: loading driver v4.0.11.213VhifDeviceInserted: Dumping clocks (50000000,100000000)HIFDumpCCCR 0(43) 1(3) 2(0) 3(0) 4(0) 5(0) 6(0) 7(6) 8(17) 9(0) A(10) B(0) C(0) D(0) E(0) F(0) 10(0) 11(0) 12(1) 13(3) 14(7) 15(37) 16(3)AR6000: Set async interrupt delay clock as 2.R0: wlan: [234:E :HDD] hdd_apply_cfg_ini: Reg Parameter gRrmOperChanMax > allowed Maximum [8 > 7]. Enforcing Default= 4R0: wlan: [234:E :HDD] hdd_apply_cfg_ini: Reg Parameter gRrmNonOperChanMax > allowed Maximum [8 > 7]. Enforcing Default= 4R0: wlan: [234:E :HDD] Name = [gEnableHostapdEdcaLocal] Value = [0]R0: wlan: [234:E :HDD] Name = [g_sta_change_cc_via_beacon] Value = [0]R0: [insmod][01:18:14.694004] wlan: [234:E :HDD] Name = [gEnableHostapdEdcaLocal] Value = [0]R0: [insmod][01:18:14.702871] wlan: [234:E :HDD] Name = [g_sta_change_cc_via_beacon] Value = [0]AR6000: configuration opcode 3 is not used for Linux SDIO stackNUM_DEV=1 FWMODE=0x2 FWSUBMODE=0x0 FWBR_BUF 0ol_download_firmware: Using 0x1234 for the remainder of initR0: [insmod][01:18:14.976617] wlan: [234:E :VOS] __ol_transfer_bin_file: transferring file: otp30.bin size 25057 bytes done!ol_download_firmware: chip_id:0x5020001 board_id:0x0ar6k_wlan mmc2:0001:1: Direct firmware load for bdwlan30.b00 failed with error -2__ol_transfer_bin_file: Failed to get bdwlan30.b00:-2__ol_transfer_bin_file: Trying to load default bdwlan30.binBoard extended Data download address: 0x0R0: [insmod][01:18:15.051981] wlan: [234:E :VOS] __ol_transfer_bin_file: transferring file: bdwlan30.bin size 8124 bytes done!__ol_transfer_bin_file: Loading setup file epping30.binar6k_wlan mmc2:0001:1: Direct firmware load for epping30.bin failed with error -2__ol_transfer_bin_file: Failed to get epping30.bin:-2R0: [insmod][01:18:15.416903] wlan: [234:E :VOS] __ol_transfer_bin_file: transferring file: qwlan30.bin size 619364 bytes done!+HTCCreate .. HIF :c4d90000HIF Interrupt processing is SYNC ONLYAR6000: configuration opcode 7 is only used for RTOS systems, not Linux systemsAR6000: configuration opcode 5 is not used for Linux SDIO stack-HTCCreate (0xc4342000)R0: [insmod][01:18:15.451026] wlan: [234:F :WDA] WMA --> wmi_unified_attach - successol_if_dfs_attach: called; ptr=c4009e68, radar_info=c5397954R0: [insmod][01:18:15.465171] wlan: [234:E :SAP] dfs_init_radar_filters[217]: Unknown dfs domain 0+HWTsend_filled_buffers_to_user: Send Failed -3 drop_count = 1Target Ready! : transmit resources : 3 size:1792, MaxMsgsPerHTCBundle = 32HTC Service Index : 1 TX : 0x100 : alloc:3HTC Service:0x0001, ULpipe:1 DLpipe:0 id:0 Ready-HWTMAILBOX SWAP Service is enabled!is_full_reorder_offloaded? 0HTC Service TX : 0x300 : allocation is zero!HTCConnectService, host indicate support b2b bundleHTCConnectService, firmware decide to disabled b2b bundleHTC Service:0x0300, ULpipe:1 DLpipe:0 id:1 ReadyTXRX: page_divider 0x5, offset_filter 0x1f num elem 4800, ol desc num page 150, ol desc per page 32HTCConnectService, host indicate support b2b bundleHTCConnectService, firmware decide to disabled b2b bundleHTC Service:0x0100, ULpipe:3 DLpipe:2 id:2 ReadyR0: [insmod][01:18:15.559688] wlan: [234:F :WDA] WMA --> wmi_unified_connect_htc_service - successR0: [VosMCThread][01:18:15.568533] wlan: [239:F :WDA] McThread: WNI_CFG_DNLD_REQHTC using TX credit flow control__wmi_control_rx: WMI UNIFIED SERVICE AVAILABLE eventR0: [kworker/1:0][01:18:15.605088] wlan: [15:F :WDA] WMA <-- WMI_SERVICE_AVAILABLE_EVENTID__wmi_control_rx: WMI UNIFIED SERVICE READY eventR0: [kworker/1:0][01:18:15.617708] wlan: [15:F :WDA] WMA <-- WMI_SERVICE_READY_EVENTIDR0: [kworker/1:0][01:18:15.625474] wlan: [15:E :WDA] wma_rx_service_ready_event: Firmware build version : 00000017R0: [kworker/1:0][01:18:15.635654] wlan: [15:E :WDA] wma_rx_service_ready_event: Board version: 0.2201400aR0: [kworker/1:0][01:18:15.645168] wlan: [15:F :WDA] WMA --> WMI_INIT_CMDIDol_target_failure: Loading/Unloading is in progress, ignore!R0: [insmod][01:18:17.589981] wlan: [234:F :WDA] wma_wait_for_ready_event: Timeout waiting for ready event from FWR0: [insmod][01:18:17.600174] wlan: [234:F :SYS] Failed to get ready event from target firmwareVOS ASSERT in vos_preStart Line 976------------[ cut here ]------------WARNING: CPU: 0 PID: 234 at /root/enforce_cam_v2/ec_driver/QCA9377.LEA.3.0_QDN_r3000017.1/fixce/AIO/build/../drivers/qcacld-new/CORE/VOSS/src/vos_api.c:976 vos_preStart+0x398/0x3a0 [wlan]Modules linked in: wlan(O+) mac80211 cfg80211 g_mass_storage usb_f_mass_storage libcompositeCPU: 0 PID: 234 Comm: insmod Tainted: G W O 4.9.37 #20Hardware name: Generic DT based system[<c010fdf0>] (unwind_backtrace) from [<c010b3d8>] (show_stack+0x10/0x14)[<c010b3d8>] (show_stack) from [<c033007c>] (dump_stack+0x84/0x98)[<c033007c>] (dump_stack) from [<c0118c00>] (__warn+0xe8/0x100)[<c0118c00>] (__warn) from [<c0118cc8>] (warn_slowpath_null+0x20/0x28)[<c0118cc8>] (warn_slowpath_null) from [<bf7e63e4>] (vos_preStart+0x398/0x3a0 [wlan])[<bf7e63e4>] (vos_preStart [wlan]) from [<bf675c50>] (hdd_wlan_startup+0x75c/0x22fc [wlan])[<bf675c50>] (hdd_wlan_startup [wlan]) from [<bf878ce0>] (ath_hif_sdio_probe+0x374/0x390 [wlan])[<bf878ce0>] (ath_hif_sdio_probe [wlan]) from [<bf879c04>] (HIFSetMboxSleep+0x56c/0x808 [wlan])[<bf879c04>] (HIFSetMboxSleep [wlan]) from [<bf87c5e4>] (hifDeviceInserted+0x468/0x9c8 [wlan])[<bf87c5e4>] (hifDeviceInserted [wlan]) from [<c04744bc>] (sdio_bus_probe+0x108/0x11c)[<c04744bc>] (sdio_bus_probe) from [<c03aff5c>] (driver_probe_device+0x204/0x2b0)[<c03aff5c>] (driver_probe_device) from [<c03b00c0>] (__driver_attach+0xb8/0xbc)[<c03b00c0>] (__driver_attach) from [<c03ae338>] (bus_for_each_dev+0x68/0x9c)[<c03ae338>] (bus_for_each_dev) from [<c03af3d0>] (bus_add_driver+0x108/0x214)[<c03af3d0>] (bus_add_driver) from [<c03b07e8>] (driver_register+0x78/0xf4)[<c03b07e8>] (driver_register) from [<bf879360>] (HIFInit+0x84/0x118 [wlan])[<bf879360>] (HIFInit [wlan]) from [<bf878688>] (hif_register_driver+0xac/0x124 [wlan])[<bf878688>] (hif_register_driver [wlan]) from [<bf66860c>] (hdd_hif_register_driver+0x34/0xf8 [wlan])[<bf66860c>] (hdd_hif_register_driver [wlan]) from [<bfae2118>] (init_module+0x118/0x1d4 [wlan])[<bfae2118>] (init_module [wlan]) from [<c010173c>] (do_one_initcall+0x44/0x16c)[<c010173c>] (do_one_initcall) from [<c0194f48>] (do_init_module+0x60/0x380)[<c0194f48>] (do_init_module) from [<c0185be8>] (load_module+0x19ec/0x1fdc)[<c0185be8>] (load_module) from [<c018632c>] (SyS_init_module+0x154/0x16c)[<c018632c>] (SyS_init_module) from [<c0107400>] (ret_fast_syscall+0x0/0x3c)---[ end trace 6c1aec9493298d16 ]---R0: [insmod][01:18:17.865163] wlan: [234:F :HDD] hdd_wlan_startup: vos_preStart failedR0: [VosMCThread][01:18:17.872953] wlan: [239:E :VOS] VosMCThread: MC Thread exiting!!!!R0: [VosTlshimRxThre][01:18:17.880955] wlan: [240:E :VOS] VosTlshimRxThread: Shutting down tl shim Tlshim rx threadR0: [VosTlshimRxThre][01:18:17.891247] wlan: [240:E :VOS] VosTlshimRxThread: Exiting VOSS Tlshim rx threadR0: [insmod][01:18:17.904097] wlan: [234:E :VOS] vos_get_context: Module ID 17 context is NullR0: wlan: [234:F :HIF] hdd_wlan_startup failedar6k_wlan: probe of mmc2:0001:1 failed with error -1ath_hif_sdio: HIF (Atheros/multi-bss)R0: wlan: [234:E :HDD] hdd_hif_register_driver: 17769: hdd_wlan_startup failed status:-11 jiffies_left:14000R0: wlan: [234:F :HDD] hdd_driver_init: WLAN Driver Initialization failedAR6000: Unregistering with the bus driverAR6000: Unregistered!insmod: can't insert 'wlan.ko': No such device
Hi Paul,
Some of the firmware .bin files are not needed. Whichever are needed, they got downloaded successfully.
The real problem in your setup is related to SDIO. The transactions might be failing but it's not visible in dmesg logs.
Please enable SDIO logs and check what's going wrong.
hi ,
thanks your reply. I think i get the real error. Unable to read HOST_INT_STATUS_ADDRESS register. can you give me some adivces? when I install modules. the wlan.ko stopped. I have to press CTRL+C to interrupte it.
Hi Arnold,
Which is the platform on which you are trying the card? Does it support SDIO 3.0?
Also, can you comment out the line having "-DSDIO_3_0 \" in the qcacld-2.0/Kbuild file, build the driver and test with it?
The error you are seeing is most likely related to your interface , SDIO in this case. You may want to enable SD/MMC logs in your kernel to confirm. There is a better way to have the logs dynamically enabled. Here are the steps:
Enable "CONFIG_MMC_DEBUG" in kernel .config file and then rebuild the kernel.
If "CONFIG_DYNAMIC_DEBUG" is enabled in the kernel config, then simply run these 2 commands before you insmod wlan.ko.
#echo -n 'module mmc_core +p' > /sys/kernel/debug/dynamic_debug/control
#echo -n 'file sdio_irq.c +p' > /sys/kernel/debug/dynamic_debug/control
Thanks.
hi sir,
thanks for your reply. when i disable sdio 3.0. it still failed. can you give me some advice again. thanks!
Hi Arnold,
Which Embedded platform are you using?
Such errors are due to SDIO clocks also. Could you please try below different clocks during driver load and let us know if any improvements:
#insmod wlan.ko mmcclock=X
mmcclock=12500000 means 12.5 MHz. You can change it to 5, 10, 12.5, 15, 20, 25, 50, 75 ... and see if you get better results.
Thanks.
Hi,
I think I faced same issue exactly with Arnold when insmod wlan.ko. I had cross compiled QCA9377 driver (wlan.ko) for ARM architecture by using the package as shown below and copied it to my ARM platform board. In this post had attached the error log when insmod wlan.ko.
The error log seem like deliver the message that SDIO failed to be communicated, and I had tried out the previous suggested methods but still failed when insmod wlan.ko.
The followings are the environment on my site to insert wlan.ko:
Kernel Version: 4.4.15
Platform arch: ARM
QCA9377 driver package: qca9377.lea_.3.0_qdn_r3000017.1.tgz
WLAN driver version: 4.5.25.38
Here is the kernel log:
XH
Hi XH,
Your issue is different than Arnold.
2. What's the inbuilt SDIO Controller in that board?
3. Did you try to use the driver on an x86 laptop? The QCA9377 SDIO module works well with these laptops:
Thanks.
Hi,
First of all, thanks for your reply.
1. Currently I am using the board with Qualcomm chipset IPQ8065
2. The board have a micro SD card slot and I use an adapter (TFtoSD) connect with QCA 9377 SDIO
3. Unfortunately, I don't have any laptop stated above. But I had tried the driver on x86 pc with linux kernel 4.4.15 but failed to insert the driver also.
Hi XH,
Thank you for sharing details.
We need to make sure if our card was enumerated. We should see a new mmc device in /sys/bus/mmc/devices after inserting QCA9377 to SDIO slot. Something like this, after inserting the card:
Do you see this?
Thanks.
Hi,
Yes, I can see the new mmc device (mmc0:0001) under /sys/bus/mmc/devices after inserting QCA9377 SDIO card and can detect the vendor ID as well. However, the driver still failed to insert although ID can be detected, this is the error log:
This is the log when I insert the QCA9377 SDIO to IPQ8065 board:
Thanks,
XH
Hi XH,
Hi,
Thanks for looking out my issue.
Sorry, it is my mistake when copying the error log, the following I attached is the errror when I load the driver with inserting QCA9377 SDIO:
Hi,
Shall I modify the board device tree (dtsi) file?
Thanks,
XH
Hi XH,
What are you going to modify in your DTSI file?
From the logs that you have shared so far, it seems an incompatibility from your host controller. I'm trying to check internally about the errors you are seeing.
Thanks.
Hi,
I am using module QCA9377-3 and SDK "qca9377.lea_.3.0_qdn_r3000017.1" from Qualcomm's website to build and try install driver.
- Kernel: 4.11.0
- Wlan version: 4.0.11.213V
I use cmd: insmod wlan.ko to install the driver for module QCA9377, but it fail:
Hi Lap,
I see a timeout in the logs:
[13538.124117] R0: wlan: [54119:E :HDD] hdd_hif_register_driver: 17762: hif registration timedout
1. Have you checked if the card was detected?
Detection:
we have to see a new mmc device in /sys/bus/mmc/devices after inserting dut
ls /sys/bus/mmc/devices
Something like this, after inserting the card
vtanuku@blrnapleshost01:~$ ls /sys/bus/mmc/devices/
mmc0:0001
2. Which Laptop/Platform are you using for this test?
Following are the supported laptop models
Hi,
Thank you for your reply.
1. After insert the card, I go to ls /sys/bus/mmc/devices/ and no device is showed. But in my laptop can detect the device on Player/Removable Device of my VMware Vitural Machine.
2. I using the Latitude 3490 and other is Dell Inspirion for tetst but it still faill when insmod the driver.
When try on Dell Inspirion, the dmesg as below:
[32773.031032] AR6000: Unregistered!
Hi Lap,
Are you using QCA9377 USB or SDIO module?
The SDIO is only supported by the software.
Thanks.
Hi,
I am using the board with interface SDIO. I connect the board and my laptop by SD card slot on laptop.
I don't know why the log display that USB
I am still fail when try insmod driver to the board.
Regards,
Lap
Hi Lap,
Not sure on the USB enumeration.
Since you are using a laptop that is not known to work for QCA9377 SDIO, we aren't sure what might be going wrong.
Please use one of the above laptops from the "Supported Laptops list". I already shared with you in previous response.
If still doesn't work, we can help to check.
Thanks.
Hi,
I tested with Lenovo T430 but it still can not detect the HW. In path /sys/bus/mmc/devices: no device here
And also can not insmod the driver for the HW
Have you any idea?
Regards,
Lap
Hi Lap,
T430 is verified to be working. At least you should see some prints in dmesg when you insert the card. Can you check?
What happens when you insmod? HIF registration fails?
Thanks.
Hi,
I inserted the HW into SD card slot and no log from dmesg, nothing happen in linux or windown.
When run the insmod command, it's fail with notified: no such device.
Regards,
Lap
Does your kernel have SD/MMC support enabled?
Hi,
Sure about that. I already enable all SD/MMC support in menu_makeconfig follow the document of Qualcomm.
Please confirm the version Ubuntu and version Kernel which you use for test?
Current I use Ubuntu 16.4 and Kernel 4.11, is it OK?
Regards,
Lap
Hi Lap,
We verify on 4.9 generally and it works.
On 4.11, are you able to build the driver? If so, I believe you can use it as well.
I still doubt on the SDIO detection. If you have an SD/MMC memory card, you may check if that gets detected.
Unless the card gets detected, we may not be able to help much.
Thanks.
Hi,
I use kernel version 4.11 and can build the driver successfully.
I used the SD card to test and the laptop can detect the SD card, can read/ write file.
If not any other solution, I will try with Kernel version 4.9.
Regards,
Lap
Lap,
As suggested, please verify your slot supports SDIO too. You might already know SD and SDIO are 2 different things.
SD card detection is fine but you need to test if QCA9377 SDIO card gets detected or not.
Thanks.
Hi,
Thank you for your advice. Currenlly, my laptop can detect the HW via SDIO port.
I copied all the file from "Source" to "Target" follow the Qualcomm document and try insmod, but it fail.
Here my log:
Hi Lap,
It is a driver registration timeout issue when the driver tries to register itself to the SDIO Host Controller driver.
You can add some prints in the WLAN driver function hif_sdio_register_driver() and check the return of this call:
status = sdio_register_driver(&ar6k_driver);
You can further trace kernel code as to why the SDIO registration is failing. I don't see it as Qualcomm driver issue.
Thanks.
Hi,
Thanks for your help. I had insmod Wlan successfully.
Now, I am trying to enable the Bluetooth:
I got to gap_menu -> enable but it fail.
=====
Hi Lap,
Thanks for creating new thread for the BT issue. Someone from BT Team will be supporting you soon.
Thanks.