This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Wilink8 and Linux 3.12 problem

Other Parts Discussed in Thread: AM3352, WL1271

Hello.

We are using AM3352 based board with SIM51A6 (wl18xx) WiFi module on OpenWRT (r38993) with kernel 3.12 and faced with some connectivity problems. WiFi module is connected to cpu through MMC2 + 2 gpio for irq/wl_en.
When we try to connect to adhoc network wilink driver crashes.

Wilink driver loads correctly on boot:

[    1.491339] mmc0: new high speed SDIO card at address 0001
[    1.506870] wl1271_sdio mmc0:0001:2: legacy platform data not found, trying device tree
/* here we removed wl18xx-conf.bin, with wl18xx-conf.bin (without following error) all works the same way */
[   61.610103] wlcore: ERROR could not get configuration binary ti-connectivity/wl18xx-conf.bin: -2
[   61.619526] wlcore: WARNING falling back to default config
[   62.559710] wlcore: wl18xx HW: RDL 2, 1857 MIMO, PG 2.0 (ROM 0)
[   62.591794] wlcore: loaded

After booting wlan0 interface appeared and can be set to up state:

root@OpenWrt:/# ifconfig wlan0 up
[  107.140395] wlcore: PHY firmware version: Rev 8.2.0.0.163
[  107.233431] wlcore: firmware booted (Rev 8.5.0.0.55)
root@OpenWrt:/# ifconfig
lo        Link encap:Local Loopback 
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:18 errors:0 dropped:0 overruns:0 frame:0
          TX packets:18 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:1476 (1.4 KiB)  TX bytes:1476 (1.4 KiB)

wlan0     Link encap:Ethernet  HWaddr DE:AD:BE:EF:00:00 
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

Then iw wlan0 scan command works correctly, so we can see the list of found networks.
But when we try to connect to adhoc network by openwrt utility 'wifi' wilink driver failed.

Here is openwrt config:

root@OpenWrt:/# cat /etc/config/wireless

config wifi-device 'radio0'
        option type 'mac80211'
        option phy 'phy0'
        option channel '11'
        option macaddr 'DE:AD:BE:EF:00:00'
        option hwmode '11ng'
        option htmode 'HT20'

config wifi-iface
        option device 'radio0'
        option network 'client'
        option encryption 'wep'
        option ssid 'SSID'
        option key '0000000001'
        option mode 'adhoc'

Here is console output:

root@OpenWrt:/# wifi up
Command failed: Not found
Command failed: Not found
command failed: Device or resource busy (-16)
[  374.146537] wlcore: PHY firmware version: Rev 8.2.0.0.163
[  374.243144] wlcore: firmware booted (Rev 8.5.0.0.55)
[  374.251327] wlcore: ERROR command execute failure 14
[  374.256562] ------------[ cut here ]------------
[  374.261520] WARNING: CPU: 0 PID: 1341 at drivers/net/wireless/ti/wlcore/main.c:778 wl12xx_queue_recovery_work+0x28/0x64()
[  374.273095] Modules linked in: iptable_nat nf_nat_ipv4 nf_conntrack_ipv4 iptable_raw iptable_mangle iptable_filter ipt_REJECT ipt_MASQUERADEd
[  374.310364] CPU: 0 PID: 1341 Comm: ifconfig Tainted: G        W    3.12.0 #79
[  374.317881] Backtrace:
[  374.320527] [<c001bfc8>] (dump_backtrace+0x0/0x10c) from [<c001c168>] (show_stack+0x18/0x1c)
[  374.329445]  r6:0000030a r5:c07d22a4 r4:00000000 r3:00000000
[  374.335469] [<c001c150>] (show_stack+0x0/0x1c) from [<c01dcf30>] (dump_stack+0x70/0x8c)
[  374.343943] [<c01dcec0>] (dump_stack+0x0/0x8c) from [<c003d210>] (warn_slowpath_common+0x6c/0x8c)
[  374.353349]  r4:00000000 r3:c08913e4
[  374.357145] [<c003d1a4>] (warn_slowpath_common+0x0/0x8c) from [<c003d254>] (warn_slowpath_null+0x24/0x2c)
[  374.367250]  r8:c08960c0 r7:c7494a80 r6:fffffffb r5:0000000e r4:c7298ce0
[  374.374384] [<c003d230>] (warn_slowpath_null+0x0/0x2c) from [<c02cdebc>] (wl12xx_queue_recovery_work+0x28/0x64)
[  374.385052] [<c02cde94>] (wl12xx_queue_recovery_work+0x0/0x64) from [<c02d0fb4>] (wlcore_cmd_send_failsafe+0x380/0x3a0)
[  374.396439]  r4:c7298ce0 r3:c08913e4
[  374.400259] [<c02d0c34>] (wlcore_cmd_send_failsafe+0x0/0x3a0) from [<c02d2040>] (wlcore_cmd_configure_failsafe+0x68/0x90)
[  374.411839] [<c02d1fd8>] (wlcore_cmd_configure_failsafe+0x0/0x90) from [<c02d2084>] (wl1271_cmd_configure+0x1c/0x28)
[  374.422948]  r8:00000000 r7:00000001 r6:c76b0cb0 r5:c7494a80 r4:00000000
[  374.430086] [<c02d2068>] (wl1271_cmd_configure+0x0/0x28) from [<c02d7fc4>] (wl1271_acx_group_address_tbl+0x8c/0xc0)
[  374.441123] [<c02d7f38>] (wl1271_acx_group_address_tbl+0x0/0xc0) from [<c02db858>] (wl1271_init_vif_specific+0x374/0x39c)
[  374.452703] [<c02db4e4>] (wl1271_init_vif_specific+0x0/0x39c) from [<c02ceda0>] (wl1271_op_add_interface+0x6e0/0x7ec)
[  374.463928]  r8:c7298d1c r7:c091dc50 r6:c7298ce0 r5:c76b0bb8 r4:00000000
[  374.471090] [<c02ce6c0>] (wl1271_op_add_interface+0x0/0x7ec) from [<c04a439c>] (ieee80211_do_open+0x3b4/0x9c4)
[  374.481670] [<c04a3fe8>] (ieee80211_do_open+0x0/0x9c4) from [<c04a4a1c>] (ieee80211_open+0x70/0x7c)
[  374.491245] [<c04a49ac>] (ieee80211_open+0x0/0x7c) from [<c03a9d3c>] (__dev_open+0xa0/0xf4)
[  374.500073]  r4:c76b0000 r3:c04a49ac
[  374.503866] [<c03a9c9c>] (__dev_open+0x0/0xf4) from [<c03a9fa4>] (__dev_change_flags+0xb4/0x13c)
[  374.513146]  r7:00001002 r6:00000001 r5:00001043 r4:c76b0000
[  374.519174] [<c03a9ef0>] (__dev_change_flags+0x0/0x13c) from [<c03aa0b8>] (dev_change_flags+0x18/0x4c)
[  374.529000]  r7:c75fe000 r6:c71c83cc r5:00001002 r4:c76b0000
[  374.535020] [<c03aa0a0>] (dev_change_flags+0x0/0x4c) from [<c03feb6c>] (devinet_ioctl+0x2cc/0x698)
[  374.544483]  r6:c71c83cc r5:00000000 r4:c71c83cc r3:00008914
[  374.550516] [<c03fe8a0>] (devinet_ioctl+0x0/0x698) from [<c03fff34>] (inet_ioctl+0x19c/0x1c8)
[  374.559544] [<c03ffd98>] (inet_ioctl+0x0/0x1c8) from [<c0393a58>] (sock_ioctl+0x228/0x280)
[  374.568277] [<c0393830>] (sock_ioctl+0x0/0x280) from [<c00d5618>] (do_vfs_ioctl+0x5b0/0x610)
[  374.577191]  r6:bef4b758 r5:c7498e00 r4:c692a0e0 r3:c0393830
[  374.583221] [<c00d5068>] (do_vfs_ioctl+0x0/0x610) from [<c00d56bc>] (SyS_ioctl+0x44/0x64)
[  374.591860]  r8:c7498e00 r7:00000000 r6:bef4b758 r5:00008914 r4:00000003
[  374.599000] [<c00d5678>] (SyS_ioctl+0x0/0x64) from [<c0008cc0>] (ret_fast_syscall+0x0/0x30)
[  374.607796]  r8:c0008e44 r7:00000036 r6:00008914 r5:00000003 r4:bef4b758
[  374.614923] ---[ end trace 995b6ef9977c5560 ]---
[  374.619832] wlcore: WARNING CONFIGURE command NOK
[  374.624790] wlcore: WARNING failed to set group addr table: -5
ifconfig: SIOCSIFFLAGS: Input/output error
command failed: Network is down (-100)
Command failed: Not found

Maybe somebody have the same issue and can help?