OpenWrt Forum Archive

Topic: Lantiq XWAY WAVE300

The content of this topic has been archived between 30 Mar 2018 and 30 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

I can force start up of the interface by adding some lines to driver/wireless/driver/linux/core.c

In particular, in function _mtlk_core_country_code_set_default
I added:

uint8 country_code = country_to_country_code("GB");

This sets a value for the country code.

And in function _mtlk_core_mbss_check_activation_params

char * test_essid = "test";
mtlk_pdb_set_string(mtlk_vap_get_param_db(nic->vap_handle), PARAM_DB_CORE_ESSID, test_essid);

This sets a default value for ESSID.

Once I run ifconfig wlan1 up I get the following dmesg output:
https://pastebin.com/Y3UqC7Nc

However, the router reboots a few seconds later

Mandrake wrote:

Hi Blackadder,

Maybe it's a longshot, but in the sources from Vittorio88, there's a folder /scripts that looks to me like a CLI to setup the wave300.
    https://www.downloads.netgear.com/files … 46-GPL.zip

More in particular, there's a script called mtk_init_country.sh
    https://pastebin.com/Ya25wQ2C

I believe this can be of some help.

Good luck!
Mandrake

blackadder1000 wrote:

when I try to bring the interface up dmesg reports:

[0000182056] mtlk3(_mtlk_core_ap_set_initial_channel:3319): CID-0000: Failed to open - Country not specified
[  482.178127] [0000182064] mtlk3(_mtlk_core_activate:3384): Cannot set initial channel (-14)

Does anyone know how to set the country code?

Thanks Mandrake. Will take a look at this next

I have to find files of my source code - I put them on some external HDD. I also had a list of more advanced settings, like 20/40MHz, isolation. Give me some days.

Anyway almost all (no WPA) things can be set with iwpriv - at least ESSID, channel. Do not write own 'test' to source code.
I forgot to tell you, that you should check the MAC address - in common cases driver fails with that.

I told about rflib, because GPLed 3.1 has a rflib binary bloob instead - to not use 3.1. 3.1 has a serious stability problems too.

On LEDE you should install wireless tools. mtlk driver has no support of linux cfg80211.

@blackadder1000 try to decrease the debug level (OOM?) and set essid with iwpriv, revert your patch. And try again

(Last edited by lpm11 on 25 Sep 2017, 10:14)

Hello

I've stuck on "insmod" drivers (kernel panic). I'm using "TP-LINK TD-W8980"  profile to compile drivers. I tried lede-17.01 branch (kernel 4.4.87) and with tag 17.01.1 (kernel 4.4.61). What's funny that drivers compiled on 4.4.87 showing at least :

[58956.672810] ap_upper.bin: @@@ VERSION INFO @@@ version number: FW_3.2.1_r5437 MIPS:  Upper CPU(TMC AGG AP) interface: PCI  phy type: real phy on Mar 28 2012 at 11:00:01@@@ END @@@
[58956.672810] contr_lm.bin: @@@ VERSION INFO @@@ version number: FW_3.2.1_r5437 MIPS:  Lower MAC  interface: --  phy type: real phy on Mar 28 2012 at 10:59:46@@@ END @@@

Under 4.4.61 I don't have those lines.

To be clear I'm using LEDE 17.01.1 firmware for W8980 on W9980. As I'm not so smart as YOU (I don't know where you get such huge knowledge), I'm stuck and waiting for your action.

Cheers wyatt_

@lpm11 Thanks for the advice.

I can get the correct settings using the following commands:

iwpriv wlan1 sCountry GB
iwconfig wlan1 essid test
iwconfig wlan1 channel 52

I can then bring the interface up

Still finding the router crashes after a few seconds. Will keep looking at it. I'm not running with any explicit debugging i.e. I'm loading the modules with no debug switches.

Looks like kernel panic. Without crash dump it is hard to say what is happening sad You have to connect to UART

I found only some very old staff for mips - uploaded it here https://ufile.io/rczdo
Try to extract content to rootfs, reboot router and check for /etc/config/wireless if it could be configured from here.

Please also provide and set macaddr in wireless config file, or it will not work.

I have to check if I have something newer, but I am afraid that it is lost.

(Last edited by lpm11 on 26 Sep 2017, 12:34)

Hello,

I have wiped everything, and started again using latest code for LEDE and OpenWRT.
I have submitted, and had merged into LEDE trunk the patch to enable the GPIO for resetting PCI to enable the WAVE300 on the VR200v platform.

I have not submitted the slightly different patch to enable PCI for OpenWRT. I believe from some mailing list discussions that the main OpenWRT buildsystem repository was going to get replaced by the LEDE buildsystem, and it seems they haven't been taking in that many pulls.

Using LEDE, I have been able to get past multiple issues.
The first issue I had, my built .ko modules were not printing anything upon insmod.
The second issue I had, (also wyatt_, it seems), was a kernel panic shorty after firmware was loaded

Both these issues are fixed, however I am not sure if it was fixed by removing and recreating the entire environment and building the the latest LEDE trunk or by using blackadder1000's method for insmodding the the driver:

insmod mtlkroot.ko cdebug=2
insmod mtlk.ko ap=1 debug=2

Anyway, now the driver loads (finally!), and I am at the point where blackadder1000 was.
I have not yet tried to set the country.
Here is my LEDE trunk log:

root@vitto-rtr1:~/vitto_wav300_lede-trunk_ugw5.1-vrx288-nand_v1# insmod mtlk.ko ap=1 debug=2
[ 1521.878069] [0001221768] mtlk2(mtlk_dfg_init:681): Starting MTLK
[ 1521.882747] [0001221772] mtlk0(__mtlk_print_endianess:3867): The system is Big endian (0xbeadfeed, 0xedfeadbe)
[ 1521.892843] [0001221784] mtlk1(mtlk_df_proc_node_create:125): Proc node root/ created
[ 1521.900637] [0001221792] mtlk1(mtlk_df_proc_node_create:127): Proc node root/mtlk created
[ 1521.908798] [0001221800] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry mtlk/version created
[ 1521.917938] [0001221808] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry mtlk/mem_alloc_dump created
[ 1521.927688] [0001221820] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry mtlk/objpool_dump created
[ 1521.937263] [0001221828] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry mtlk/topology created
[ 1521.946590] [0001221836] mtlk0(mtlk_fast_mem_print_info:105): Using normal memory for hot context
[ 1521.955350] PCI: Enabling device 0000:00:0e.0 (0000 -> 0002)
[ 1521.961068] [0001221852] mtlk2(_mtlk_bus_drv_map_resource:247): BAR0=0x18800000 Len=0x1000 VA=0xb8800000
[ 1521.970485] [0001221860] mtlk2(_mtlk_bus_drv_map_resource:247): BAR1=0x18000000 Len=0x800000 VA=0xb8000000
[ 1521.980333] [0001221872] mtlk0(_mtlk_df_user_alloc_devname:6511): NDEV Name pattern: wlan%d
[ 1521.988559] [0001221880] mtlk1(mtlk_df_proc_node_create:127): Proc node mtlk/wlan0 created
[ 1521.996790] [0001221888] mtlk1(mtlk_df_proc_node_create:127): Proc node wlan0/Debug created
[ 1522.005157] [0001221896] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/hw_limits created
[ 1522.014550] [0001221904] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/reg_limits created
[ 1522.024042] [0001221916] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/antenna_gain created
[ 1522.033698] [0001221924] mtlk1(_mtlk_df_proc_node_add_entry:229): Proc entry wlan0/do_debug_assert created
[ 1522.043364] [0001221936] mtlk1(_mtlk_df_proc_node_add_entry:229): Proc entry wlan0/lm created
[ 1522.051886] [0001221944] mtlk1(_mtlk_df_proc_node_add_entry:229): Proc entry wlan0/um created
[ 1522.060427] [0001221952] mtlk1(_mtlk_df_proc_node_add_entry:229): Proc entry wlan0/shram created
[ 1522.069208] [0001221960] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry Debug/General created
[ 1522.078441] [0001221968] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry Debug/MACStats created
[ 1522.087748] [0001221980] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/igmp created
[ 1522.096720] [0001221988] mtlk1(_mtlk_df_proc_node_add_entry:229): Proc entry Debug/ResetStats created
[ 1522.105940] [0001221996] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/aocs_history created
[ 1522.115604] [0001222008] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/aocs_table created
[ 1522.125095] [0001222016] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/aocs_channels created
[ 1522.134853] [0001222024] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/aocs_penalties created
[ 1522.144674] [0001222036] mtlk1(_mtlk_df_proc_node_add_entry:229): Proc entry Debug/aocs_cl created
[ 1522.153642] [0001222044] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry Debug/L2NAT created
[ 1522.162692] [0001222052] mtlk1(_mtlk_df_proc_node_add_entry:229): Proc entry Debug/L2NAT_ClearTable created
[ 1522.172445] [0001222064] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry Debug/ReorderingStats created
[ 1522.182361] [0001222072] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/EECaps created
[ 1522.191505] [0001222084] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry Debug/SendQueue created
[ 1522.200902] [0001222092] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry Debug/serializer_dump created
[ 1522.210895] [0001222100] mtlk1(mtlk_print_drv_info:8042): *********************************************************
[ 1522.221234] [0001222112] mtlk1(mtlk_print_drv_info:8043): * Driver Compilation Details:
[ 1522.229256] [0001222120] mtlk1(mtlk_print_drv_info:8044): *********************************************************
[ 1522.239723] [0001222132] mtlk1(mtlk_print_drv_info:8046): * CONFIG=PLATFORM_UGW51_VRX288_NAND COMPONENTS LIN_DRV BUS_PCI_PCIE LINDRV_HW LINDRV_HW_PCIE LINDRV_HW_PCIG3 RF_MANAGEMENT_MTLK DEBUG ENABLE_OBJPOOL TXMM_HISTORY_LENGTH=3 NO_FW_RESET_ON_STOP RT_LOGGER_FUNCTIONS MAX_DLEVEL=2 USE_GENL_DEF USE_GENL DEVELOPMENT_PLATFORM ENVIRONMENT_NAME="ugw5.1-vrx288-nand" HOST_TYPE="mips-linux"
[ 1522.273733] [0001222164] mtlk1(mtlk_print_drv_info:8046): * CFLAGS=
[ 1522.279988] [0001222172] mtlk1(mtlk_print_drv_info:8046): * MTLK_KERNEL_CFLAGS=
[ 1522.287303] [0001222180] mtlk1(mtlk_print_drv_info:8046): * KERNELDIR=/root/lede/build_dir/target-mips_24kc_musl/linux-lantiq_xrx200/linux-4.9.51/
[ 1522.300472] [0001222192] mtlk1(mtlk_print_drv_info:8046): * CROSS_COMPILE=/root/WAVE300/driver/builds/ugw5.1-vrx288-nand/../../support/mtlkfront.sh /root/lede/staging_dir/toolchain-mips_24kc_gcc-5.4.0_musl/bin/mips-openwrt-linux-
[ 1522.320809] [0001222212] mtlk1(mtlk_print_drv_info:8046): * HOSTNAME=
[ 1522.327283] [0001222220] mtlk1(mtlk_print_drv_info:8049): *********************************************************
[ 1522.337729] [0001222228] mtlk0(mtlk_core_pdb_fast_handles_open:33): Open Hot-path parameters
[ 1522.346514] [0001222236] mtlk1(mtlk_qos_set_map:152): Set 802.11 TID-to-AC mapping
[ 1522.353819] [0001222244] mtlk4(_mtlk_core_get_max_stas_supported_by_fw:3227): Cannot get MAX STAs supported by FW. Forcing default
[ 1522.365551] [0001222256] mtlk1(_mtlk_core_get_max_stas_supported_by_fw:3231): MAX STAs supported by FW: 32
[ 1522.375229] [0001222268] mtlk2(_mtlk_20_40_set_limit_to_20:1207): Limit to 20 flag is set to 0
[ 1522.383841] [0001222276] mtlk2(_mtlk_core_ability_control_callback:12248): called
[ 1522.391343] [0001222284] mtlk2(_mtlk_core_ability_control_callback:12248): called
[ 1522.399424] [0001222292] mtlk2(_mtlk_bus_drv_init:336): mtlk IRQ 0x1e
[ 1522.472625] [0001222364] mtlk2(_mtlk_mmb_load_firmware:1763): Loading 'ap_upper.bin' of 161024 bytes
[ 1522.500522] [0001222392] mtlk2(_mtlk_mmb_load_firmware:1792): Loading 'contr_lm.bin' of 85376 bytes
[ 1522.583087] [0001222476] mtlk2(_mtlk_mmb_parse_chi_extensions:1917): offset = 68, CHI_ADDR = 0x00000000, sizeof(hw->chi_data) = 68
[ 1522.593487] [0001222484] mtlk2(_mtlk_mmb_parse_chi_extensions:1928): HOST_EXTENSION_MAGIC = 0xbeadfeed
[ 1522.602836] [0001222492] mtlk2(_mtlk_mmb_parse_chi_extensions:1929): ext_hdr.u32ExtensionMagic = 0xedfeadbe
[ 1522.612555] [0001222504] mtlk2(_mtlk_mmb_parse_chi_extensions:1937): ext_hdr.u32ExtensionID = 0x00000001
[ 1522.622035] [0001222512] mtlk2(_mtlk_mmb_parse_chi_extensions:1938): ext_hdr.u32ExtensionDataSize = 8
[ 1522.631246] [0001222524] mtlk2(_mtlk_mmb_parse_chi_extensions:1928): HOST_EXTENSION_MAGIC = 0xbeadfeed
[ 1522.640562] [0001222532] mtlk2(_mtlk_mmb_parse_chi_extensions:1929): ext_hdr.u32ExtensionMagic = 0xedfeadbe
[ 1522.650309] [0001222540] mtlk2(_mtlk_mmb_parse_chi_extensions:1937): ext_hdr.u32ExtensionID = 0x00000002
[ 1522.659783] [0001222552] mtlk2(_mtlk_mmb_parse_chi_extensions:1938): ext_hdr.u32ExtensionDataSize = 4
[ 1522.669058] [0001222560] mtlk2(_mtlk_mmb_parse_chi_extensions:1928): HOST_EXTENSION_MAGIC = 0xbeadfeed
[ 1522.678385] [0001222568] mtlk2(_mtlk_mmb_parse_chi_extensions:1929): ext_hdr.u32ExtensionMagic = 0xedfeadbe
[ 1522.688117] [0001222580] mtlk2(_mtlk_mmb_parse_chi_extensions:1937): ext_hdr.u32ExtensionID = 0x00000003
[ 1522.697613] [0001222588] mtlk2(_mtlk_mmb_parse_chi_extensions:1938): ext_hdr.u32ExtensionDataSize = 8
[ 1522.706832] [0001222596] mtlk2(_mtlk_mmb_parse_chi_extensions:1928): HOST_EXTENSION_MAGIC = 0xbeadfeed
[ 1522.716146] [0001222608] mtlk2(_mtlk_mmb_parse_chi_extensions:1929): ext_hdr.u32ExtensionMagic = 0xedfeadbe
[ 1522.725876] [0001222616] mtlk2(_mtlk_mmb_parse_chi_extensions:1937): ext_hdr.u32ExtensionID = 0x00000004
[ 1522.735382] [0001222628] mtlk2(_mtlk_mmb_parse_chi_extensions:1938): ext_hdr.u32ExtensionDataSize = 4
[ 1522.744611] [0001222636] mtlk2(_mtlk_mmb_parse_chi_extensions:1928): HOST_EXTENSION_MAGIC = 0xbeadfeed
[ 1522.753925] [0001222644] mtlk2(_mtlk_mmb_parse_chi_extensions:1929): ext_hdr.u32ExtensionMagic = 0xedfeadbe
[ 1522.763650] [0001222656] mtlk2(_mtlk_mmb_parse_chi_extensions:1937): ext_hdr.u32ExtensionID = 0x00000005
[ 1522.773136] [0001222664] mtlk2(_mtlk_mmb_parse_chi_extensions:1938): ext_hdr.u32ExtensionDataSize = 4
[ 1522.782370] [0001222672] mtlk2(_mtlk_mmb_parse_chi_extensions:1928): HOST_EXTENSION_MAGIC = 0xbeadfeed
[ 1522.791705] [0001222684] mtlk2(_mtlk_mmb_parse_chi_extensions:1929): ext_hdr.u32ExtensionMagic = 0xaaaaaaaa
[ 1522.801442] [0001222692] mtlk2(mtlk_hw_mmb_start_card:3204): CHI: sFifoQ: is=0x86e0 in=380 rs=0x80f0 rn=380
[ 1522.811188] [0001222704] mtlk2(mtlk_hw_mmb_start_card:3205): CHI: sDAT: is=0x7e70 in=160 rs=0x6570 rn=200
[ 1522.820763] [0001222712] mtlk2(mtlk_hw_mmb_start_card:3206): CHI: sMAN: is=0x9d6c in=15 rs=0x6150 rn=2
[ 1522.830081] [0001222720] mtlk2(mtlk_hw_mmb_start_card:3207): CHI: sDBG: is=0x8e64 in=1 rs=0x8cd0 rn=1
[ 1522.839487] [0001222732] mtlk2(_mtlk_mmb_rxque_set_default_cfg:937): Rx Queue#d: size = [10...64], buffer = 114
[ 1522.849415] [0001222740] mtlk2(_mtlk_mmb_rxque_set_default_cfg:937): Rx Queue#d: size = [10...64], buffer = 1614
[ 1522.859573] [0001222752] mtlk2(_mtlk_mmb_rxque_set_default_cfg:937): Rx Queue#d: size = [2...32], buffer = 4096
[ 1522.869852] [0001222760] mtlk2(_mtlk_mmb_prealloc_rx_buffers:2496): Total 64 from 64 buffers allocated for queue#0 (114 bytes each)
[ 1522.881707] [0001222772] mtlk2(_mtlk_mmb_prealloc_rx_buffers:2496): Total 64 from 64 buffers allocated for queue#1 (1614 bytes each)
[ 1522.893716] [0001222784] mtlk2(_mtlk_mmb_prealloc_rx_buffers:2496): Total 32 from 32 buffers allocated for queue#2 (4096 bytes each)
[ 1522.905368] [0001222796] mtlk2(_mtlk_mmb_init_calibration_cache:2618): DEBUG: Calibration Cache req_size=119448 location=0x0001fed4
[ 1522.917227] [0001222808] mtlk2(_mtlk_mmb_init_calibration_cache:2623): hw->calibr.buffer = 0x86500010
[ 1522.926477] [0001222816] mtlk2(_mtlk_mmb_init_calibration_cache:2631): hw->calibr.dma_addr = 0x06500010
[ 1522.935854] [0001222828] mtlk2(_mtlk_mmb_init_calibration_cache:2641): DEBUG: Calibration Cache buffer pointer (v=0x86500010, d=0x06500010, s=119448) written to 0x0001fed4
[ 1522.951149] [0001222844] mtlk2(_mtlk_mmb_init_mips_control:2657): MIPS Ctrl Descriptor PAS offset: 0x5544
[ 1522.960774] [0001222852] mtlk1(_mtlk_mmb_init_fw_capabilities:2735): FW supports 32 STAs 5 VAPs
[ 1522.994118] [0001222884] mtlk2(mtlk_hw_mmb_start_card:3279): HW layer activated
[ 1523.000895] [0001222892] mtlk0(_mtlk_core_start:9001): CID-0000: Driver version: 3.2.1.1.48..PciG3.PcieG3.Debug
[ 1523.000895] MAC/PHY versions:
[ 1523.000895] ap_upper.bin: @@@ VERSION INFO @@@ version number: FW_3.2.1_r5437 MIPS:  Upper CPU(TMC AGG AP) interface: PCI  phy type: real phy on Mar 28 2012 at 11:00:01@@@ END @@@
[ 1523.000895] contr_lm.bin: @@@ VERSION INFO @@@ version number: FW_3.2.1_r5437 MIPS:  Lower MAC  interface: --  phy type: real phy on Mar 28 2012 at 10:59:46@@@ END @@@
[ 1523.000895]
[ 1523.046191] [0001222936] mtlk1(mtlk_core_set_net_state:681): Going from NET_STATE_HALTED to NET_STATE_IDLE
[ 1523.055462] [0001222948] mtlk1(mtlk_flctrl_register:67): mtlk_flctrl_register id = 0x1
[ 1524.159561] [0001224052] mtlk2(mtlk_tpcv4_init:57): Object for 5 points (39 bytes of data) created.
[ 1524.167294] [0001224060] mtlk2(mtlk_tpcv4_init:57): Object for 5 points (39 bytes of data) created.
[ 1524.176660] [0001224068] mtlk2(access_mib_value:189): Successfull UM_MAN_SET_MIB_REQ, u16ObjectID = 0x0040
[ 1524.186187] [0001224076] mtlk1(mtlk_pdb_set_mac:401): << set MAC param: id(2) MAC(00:09:86:00:00:00)
[ 1524.195384] [0001224088] mtlk1(_mtlk_core_set_mac_addr:3557): CID-0000: New MAC: 00:09:86:00:00:00
[ 1524.204298] [0001224096] mtlk0(mtlk_eeprom_check_ee_data:2094): Options mask is 0x00
[ 1524.212473] [0001224104] mtlk2(access_mib_value:189): Successfull UM_MAN_SET_MIB_REQ, u16ObjectID = 0x100c
[ 1524.222455] [0001224112] mtlk1(mtlk_pdb_set_int:353): << set param: id(13) value(0)
[ 1524.229590] [0001224120] mtlk1(_mtlk_core_country_code_set_default:11828): CID-0000: Country is set to (on init): ??(0x00)
[ 1524.240806] [0001224132] mtlk4(load_default_hw_table:1768): No HW limits is available for this platform (0x1a30:0x0700, type 0x38 rev 0x42)
[ 1524.252934] [0001224144] mtlk1(mtlk_pdb_set_binary:385): << set binary param: res(0) id(36)
[ 1524.261370] [0001224152] mtlk1(mtlk_pdb_set_binary:385): << set binary param: res(0) id(37)
[ 1524.271198] [0001224164] mtlk1(mtlk_flctrl_register:67): mtlk_flctrl_register id = 0x2
[ 1524.277848] [0001224168] mtlk1(mtlk_flctrl_register:67): mtlk_flctrl_register id = 0x4
[ 1524.285805] [0001224176] mtlk1(mtlk_pdb_set_int:353): << set param: id(24) value(1)
[ 1524.293390] [0001224184] mtlk1(mtlk_pdb_set_int:353): << set param: id(25) value(1)
[ 1524.301049] [0001224192] mtlk1(mtlk_pdb_set_int:353): << set param: id(23) value(5)
[ 1524.308694] [0001224200] mtlk1(mtlk_pdb_set_int:353): << set param: id(22) value(5)
[ 1524.318648] [0001224208] mtlk1(mtlk_core_set_net_state:681): Going from NET_STATE_IDLE to NET_STATE_READY



root@vitto-rtr1:~/vitto_wav300_lede-trunk_ugw5.1-vrx288-nand_v1# ifconfig wlan0
up
[ 1737.226624] [0001437120] mtlk1(_mtlk_core_activate:3370): CID-0000: open interface
[ 1737.232881] [0001437128] mtlk3(_mtlk_core_ap_set_initial_channel:3319): CID-0000: Failed to open - Country not specified
[ 1737.243844] [0001437136] mtlk3(_mtlk_core_activate:3384): Cannot set initial channel (-14)
[ 1737.252564] [0001437144] mtlk1(_mtlk_df_user_process_core_retval:462): Core request 0x1000000 failed with error #0
ifconfig: SIOCSIFFLAGS: Resource temporarily unavailable

I will try the iwconfig lines ASAP. I have a UART permanently attached to my router.

Going to the OpenWRT build, I was not able to insmod the driver, getting the following kernel panic:

root@vitto-rtr1:~/vitto_wav300_openwrt-trunk_ugw5.1-vrx288-nand_v1# insmod mtlkroot.ko cdebug=2
[  151.083532] mtlkroot: module license 'Proprietary' taints kernel.
[  151.088289] Disabling lock debugging due to kernel taint
[  151.098263] [4294818264] mtlk0(mtlk_cdev_init:316): Max nodex set to 1048575
root@vitto-rtr1:~/vitto_wav300_openwrt-trunk_ugw5.1-vrx288-nand_v1#
root@vitto-rtr1:~/vitto_wav300_openwrt-trunk_ugw5.1-vrx288-nand_v1#
root@vitto-rtr1:~/vitto_wav300_openwrt-trunk_ugw5.1-vrx288-nand_v1# insmod mtlk.ko ap=1 debug=2
[  160.703120] [4294827868] mtlk2(mtlk_dfg_init:681): Starting MTLK
[  160.707811] [4294827872] mtlk0(__mtlk_print_endianess:3867): The system is Big endian (0xbeadfeed, 0xedfeadbe)
[  160.717845] [4294827884] mtlk1(mtlk_df_proc_node_create:125): Proc node root/ created
[  160.725987] [4294827892] mtlk1(mtlk_df_proc_node_create:127): Proc node root/mtlk created
[  160.733916] [4294827900] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry mtlk/version created
[  160.743112] [4294827908] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry mtlk/mem_alloc_dump created
[  160.753163] [4294827920] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry mtlk/objpool_dump created
[  160.762397] [4294827928] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry mtlk/topology created
[  160.771906] [4294827936] mtlk0(mtlk_fast_mem_print_info:105): Using normal memory for hot context
[  160.780451] PCI: Enabling device 0000:00:0e.0 (0000 -> 0002)
[  160.786110] [4294827952] mtlk2(_mtlk_bus_drv_map_resource:247): BAR0=0x18800000 Len=0x1000 VA=0xb8800000
[  160.795538] [4294827960] mtlk2(_mtlk_bus_drv_map_resource:247): BAR1=0x18000000 Len=0x800000 VA=0xb8000000
[  160.805318] [4294827972] mtlk0(_mtlk_df_user_alloc_devname:6511): NDEV Name pattern: wlan%d
[  160.813622] [4294827980] mtlk1(mtlk_df_proc_node_create:127): Proc node mtlk/wlan0 created
[  160.821842] [4294827988] mtlk1(mtlk_df_proc_node_create:127): Proc node wlan0/Debug created
[  160.830199] [4294827996] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/hw_limits created
[  160.839598] [4294828004] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/reg_limits created
[  160.849079] [4294828016] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/antenna_gain created
[  160.858750] [4294828024] mtlk1(_mtlk_df_proc_node_add_entry:229): Proc entry wlan0/do_debug_assert created
[  160.868420] [4294828036] mtlk1(_mtlk_df_proc_node_add_entry:229): Proc entry wlan0/lm created
[  160.877052] [4294828044] mtlk1(_mtlk_df_proc_node_add_entry:229): Proc entry wlan0/um created
[  160.885485] [4294828052] mtlk1(_mtlk_df_proc_node_add_entry:229): Proc entry wlan0/shram created
[  160.894268] [4294828060] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry Debug/General created
[  160.903480] [4294828068] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry Debug/MACStats created
[  160.912797] [4294828080] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/igmp created
[  160.921757] [4294828088] mtlk1(_mtlk_df_proc_node_add_entry:229): Proc entry Debug/ResetStats created
[  160.930989] [4294828096] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/aocs_history created
[  160.940646] [4294828108] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/aocs_table created
[  160.950147] [4294828116] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/aocs_channels created
[  160.959880] [4294828124] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/aocs_penalties created
[  160.969804] [4294828136] mtlk1(_mtlk_df_proc_node_add_entry:229): Proc entry Debug/aocs_cl created
[  160.978701] [4294828144] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry Debug/L2NAT created
[  160.987741] [4294828152] mtlk1(_mtlk_df_proc_node_add_entry:229): Proc entry Debug/L2NAT_ClearTable created
[  160.997482] [4294828164] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry Debug/ReorderingStats created
[  161.007410] [4294828172] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry wlan0/EECaps created
[  161.016544] [4294828184] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry Debug/SendQueue created
[  161.025963] [4294828192] mtlk1(mtlk_df_proc_node_add_seq_entry:438): Proc entry Debug/serializer_dump created
[  161.035958] [4294828200] mtlk1(mtlk_print_drv_info:8042): *********************************************************
[  161.046282] [4294828212] mtlk1(mtlk_print_drv_info:8043): * Driver Compilation Details:
[  161.054312] [4294828220] mtlk1(mtlk_print_drv_info:8044): *********************************************************
[  161.064765] [4294828232] mtlk1(mtlk_print_drv_info:8046): * CONFIG=PLATFORM_UGW51_VRX288_NAND COMPONENTS LIN_DRV BUS_PCI_PCIE LINDRV_HW LINDRV_HW_PCIE LINDRV_HW_PCIG3 RF_MANAGEMENT_MTLK DEBUG ENABLE_OBJPOOL TXMM_HISTORY_LENGTH=3 NO_FW_RESET_ON_STOP RT_LOGGER_FUNCTIONS MAX_DLEVEL=2 USE_GENL_DEF USE_GENL DEVELOPMENT_PLATFORM ENVIRONMENT_NAME="ugw5.1-vrx288-nand" HOST_TYPE="mips-linux"
[  161.099008] [4294828264] mtlk1(mtlk_print_drv_info:8046): * CFLAGS=
[  161.105049] [4294828272] mtlk1(mtlk_print_drv_info:8046): * MTLK_KERNEL_CFLAGS=
[  161.112368] [4294828280] mtlk1(mtlk_print_drv_info:8046): * KERNELDIR=/root/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.16/linux-lantiq_xrx200/linux-4.4.14/
[  161.126725] [4294828292] mtlk1(mtlk_print_drv_info:8046): * CROSS_COMPILE=/root/WAVE300-openwrt/driver/builds/ugw5.1-vrx288-nand/../../support/mtlkfront.sh /root/openwrt/staging_dir/toolchain-mips_34kc+dsp_gcc-5.3.0_musl-1.1.16/bin/mips-openwrt-linux-
[  161.149012] [4294828316] mtlk1(mtlk_print_drv_info:8046): * HOSTNAME=
[  161.155461] [4294828320] mtlk1(mtlk_print_drv_info:8049): *********************************************************
[  161.165920] [4294828332] mtlk0(mtlk_core_pdb_fast_handles_open:33): Open Hot-path parameters
[  161.174645] [4294828340] mtlk1(mtlk_qos_set_map:152): Set 802.11 TID-to-AC mapping
[  161.182036] [4294828348] mtlk4(_mtlk_core_get_max_stas_supported_by_fw:3227): Cannot get MAX STAs supported by FW. Forcing default
[  161.193830] [4294828360] mtlk1(_mtlk_core_get_max_stas_supported_by_fw:3231): MAX STAs supported by FW: 32
[  161.203457] [4294828368] mtlk2(_mtlk_20_40_set_limit_to_20:1207): Limit to 20 flag is set to 0
[  161.212113] [4294828380] mtlk2(_mtlk_core_ability_control_callback:12248): called
[  161.219625] [4294828384] mtlk2(_mtlk_core_ability_control_callback:12248): called
[  161.227497] genirq: Flags mismatch irq 0. 00000080 (mtlk) vs. 00000400 (IPI_resched)
[  161.234785] [4294828400] mtlk3(_mtlk_bus_drv_request_irq:208): Failed to allocate PCI interrupt 0, error code: -16
[  161.245201] [4294828412] mtlk3(MTLK_STEPS_ERROR_SD:54): STARTCTRL: bus_drv:BUS_REQUEST_IRQ_INIT FAILED! step (150)
[  161.255674] [4294828420] mtlk3(MTLK_STEPS_ERROR_S:48): STARTCTRL: bus_drv INIT FAILED! Initiating rollback...
[  161.265945] [4294828432] mtlk0(mtlk_txmm_cleanup:917): Usage Peak=0 (Total=2)
[  161.272823] [4294828440] mtlk0(mtlk_txmm_cleanup:917): Usage Peak=0 (Total=32)
[  161.280425] CPU 0 Unable to handle kernel paging request at virtual address 00000044, epc == 86205f94, ra == 86205f74
[  161.290575] Oops[#1]:
[  161.292784] CPU: 0 PID: 1519 Comm: insmod Tainted: P                4.4.14 #20
[  161.299992] task: 87920560 ti: 865f8000 task.ti: 865f8000
[  161.305378] $ 0   : 00000000 00000001 00000002 864eb300
[  161.310597] $ 4   : 864eb33c 8630c82c 00000000 00000016
[  161.315820] $ 8   : 00000000 864eb33c ad922b40 4b955af7
[  161.321043] $12   : 8665a400 8665a400 00000000 1042f438
[  161.326265] $16   : 02080020 0000001c 00000024 00000005
[  161.331487] $20   : 00000001 86312780 8630c810 86210000
[  161.336711] $24   : 00000000 00000000
[  161.341933] $28   : 865f8000 865f9a98 864eb314 86205f74
[  161.347155] Hi    : 00000019
[  161.350029] Lo    : 02600aae
[  161.352940] epc   : 86205f94 mtlk_nl_send_brd_msg+0x114/0x1d0 [mtlkroot]
[  161.359625] ra    : 86205f74 mtlk_nl_send_brd_msg+0xf4/0x1d0 [mtlkroot]
[  161.366219] Status: 1100ff03 KERNEL EXL IE
[  161.370397] Cause : 00800008 (ExcCode 02)
[  161.374400] BadVA : 00000044
[  161.377275] PrId  : 00019556 (MIPS 34Kc)
[  161.381188] Modules linked in: mtlk(P+) mtlkroot(P) ltq_ptm_vr9 iptable_nat pppoe nf_nat_ipv4 nf_conntrack_ipv6 nf_conntrack_ipv4 ipt_REJECT ipt_MASQUERADE xt_time xt_tcpudp xt_state xt_nat xt_multiport xt_mark xt_mac xt_limit xt_conntrack xt_comment xt_TCPMSS xt_REDIRECT xt_LOG xt_CT pppox ppp_async nf_reject_ipv4 nf_nat_redirect nf_nat_masquerade_ipv4 nf_nat nf_log_ipv4 nf_defrag_ipv6 nf_defrag_ipv4 nf_conntrack_rtcache nf_conntrack ltq_deu_vr9 iptable_raw iptable_mangle iptable_filter ip_tables crc_ccitt drv_dsl_cpe_api drv_mei_cpe ip6t_REJECT nf_reject_ipv6 nf_log_ipv6 nf_log_common ip6table_raw ip6table_mangle ip6table_filter ip6_tables x_tables pppoatm ppp_generic slhc br2684 atm drv_ifxos gpio_button_hotplug aead crypto_null
[  161.446130] Process insmod (pid: 1519, threadinfo=865f8000, task=87920560, tls=7702cd48)
[  161.454214] Stack : 0000001c 00000000 85cc5ffc b8800000 00000000 00000001 8630c810 8620f480
          864eb754 00000000 0000001c 00000000 85cc5ffc b8800000 024000c0 86204728
          8665b210 85c85a08 8630c800 00000002 00000005 0000002c 8665b210 864eb710
          878171a8 85cd0000 878f0c00 85cd0000 85cd0000 86204804 878171a8 85cd0000
          878f0c00 85cd0000 87817010 878171a8 85cd0000 878f0c00 85cd0000 85cd0000
          ...
[  161.489728] Call Trace:
[  161.492190] [<86205f94>] mtlk_nl_send_brd_msg+0x114/0x1d0 [mtlkroot]
[  161.498555] [<86204728>] mtlk_irbd_notify_app+0x1b8/0x1fc [mtlkroot]
[  161.504908] [<86204804>] mtlk_irbd_cleanup+0x98/0xd8c [mtlkroot]
[  161.511528] [<85c58f38>] mtlk_hw_mmb_cleanup_card+0x384/0x590 [mtlk]
[  161.518476] [<85c84f68>] mtlk_wssd_send_event+0x3f4/0xb7c [mtlk]
[  161.523860]
[  161.524717]
Code: 8fa2004c  24e7ffff  00e23821 <8c020044> 00e2102b  14400013  3c038054  3c108621  9202f560
[  161.534970] ---[ end trace 9fa375b238349112 ]---
Segmentation fault

If anybody knows what the issue is there, I would appreciate any hints!

Hi,

@Developers. I do not have UART in my platform. Instead of it, I have compiled my LEDE image with kernel option ->General Setup->Crash Logging

The image must be flashed afterwards to your router.

The benefit is that after any kernel panic and following reboot, the last log file will be stored at:

/sys/kernel/debug/crashlog

@Vittorio88. No disrespect to Openwrt, we are borrowing their forum in fact, but we should focus on the working platform and the many issues with the driver. However, you can look into linux sources for error code -16. It must be an IRQ issue.

Mandrake

Hello,

I originally used LEDE, however I fell back to OpenWRT when I couldn't get LEDE to work with my build. Since it is older, it is "closer" to the driver, so it may actually work where LEDE would not.

Now that I have started from scratch, I am testing with both, trying to see where each gets me.

I followed blackadder1000's steps to bring up the interface. I got the same result, it started up, then crashed.
I was connected through a serial connection, so I managed to get the output.

The only difference is that my WAV300 is BGN instead of AN, so the firmware were not included in the firmware zip provided by lpm11.

For reference: After digging through various GPL dumps, I noticed the latest one I posted actually has most firmwares for various chips each with various versions under the path: package\lantiq-wave300\files\root\mtlk\images\progmodels\wave300\

A few WAVE400 firmwares are also there in case anybody cares.

After erroring out on ifconfig wlan0 up the driver would ask for a missing firmware in dmesg.
To fix it, I placed the following in /lib/firmware:

  • ProgModel_BG_CB.bin

  • ProgModel_BG_CB_38_RevB.bin

  • ProgModel_BG_nCB.bin

  • ProgModel_BG_nCB_38_RevB.bin

NOTE: the files had a "_wav300" at the end of their names. I had to rename each of the files to strip this so the driver would find them.

Anyway here is the log:

root@vitto-rtr1:~/vitto_wav300_lede-trunk_ugw5.1-vrx288-nand_v1# insmod mtlkroot.ko
[  119.123390] mtlkroot: module license 'Proprietary' taints kernel.
[  119.128120] Disabling lock debugging due to kernel taint
[  119.138193] [4294786304] mtlk0(mtlk_cdev_init:316): Max nodex set to 1048575
root@vitto-rtr1:~/vitto_wav300_lede-trunk_ugw5.1-vrx288-nand_v1# insmod mtlk.ko ap=1
[  129.814129] [4294796980] mtlk0(__mtlk_print_endianess:3867): The system is Big endian (0xbeadfeed, 0xedfeadbe)
[  129.823146] [4294796992] mtlk0(mtlk_fast_mem_print_info:105): Using normal memory for hot context
[  129.831723] PCI: Enabling device 0000:00:0e.0 (0000 -> 0002)
[  129.837559] [4294797004] mtlk0(_mtlk_df_user_alloc_devname:6511): NDEV Name pattern: wlan%d
[  129.846171] [4294797012] mtlk0(mtlk_core_pdb_fast_handles_open:33): Open Hot-path parameters
[  129.854598] [4294797020] mtlk4(_mtlk_core_get_max_stas_supported_by_fw:3227): Cannot get MAX STAs supported by FW. Forcing default
[  130.040516] [4294797208] mtlk0(_mtlk_core_start:9001): CID-0000: Driver version: 3.2.1.1.48..PciG3.PcieG3.Debug
[  130.040516] MAC/PHY versions:
[  130.040516] ap_upper.bin: @@@ VERSION INFO @@@ version number: FW_3.2.1_r5437 MIPS:  Upper CPU(TMC AGG AP) interface: PCI  phy type: real phy on Mar 28 2012 at 11:00:01@@@ END @@@
[  130.040516] contr_lm.bin: @@@ VERSION INFO @@@ version number: FW_3.2.1_r5437 MIPS:  Lower MAC  interface: --  phy type: real phy on Mar 28 2012 at 10:59:46@@@ END @@@
[  130.040516]
[  131.181426] [4294798348] mtlk0(mtlk_eeprom_check_ee_data:2094): Options mask is 0x00
[  131.188577] [4294798356] mtlk4(load_default_hw_table:1768): No HW limits is available for this platform (0x1a30:0x0700, type 0x38 rev 0x42)

root@vitto-rtr1:~/vitto_wav300_lede-trunk_ugw5.1-vrx288-nand_v1# iwpriv wlan0 sCountry IT
root@vitto-rtr1:~/vitto_wav300_lede-trunk_ugw5.1-vrx288-nand_v1# iwconfig wlan0 essid test-vitto
root@vitto-rtr1:~/vitto_wav300_lede-trunk_ugw5.1-vrx288-nand_v1# iwconfig wlan0 channel 1
root@vitto-rtr1:/lib/firmware# ifconfig wlan0 up
[ 1799.041066] [0001498936] mtlk0(mtlk_mbss_init:2736): CID-0000: _mtlk_core_mbss_check_activation_params returned successfully
[ 1799.051036] [0001498944] mtlk0(_mtlk_mbss_send_preactivate:2188): CID-0000: Pre-activation started with parameters:
[ 1799.061436] [0001498956] mtlk0(mtlk_core_configuration_dump:10274): CID-0000: Country             : IT
[ 1799.070735] [0001498964] mtlk0(mtlk_core_configuration_dump:10275): CID-0000: Domain              : 48
[ 1799.080048] [0001498972] mtlk0(mtlk_core_configuration_dump:10276): CID-0000: Network mode        : 802.11bgn
[ 1799.089933] [0001498984] mtlk0(mtlk_core_configuration_dump:10277): CID-0000: Band                : 2.4
[ 1799.099375] [0001498992] mtlk0(mtlk_core_configuration_dump:10278): CID-0000: Prog Model Spectrum : 40 MHz
[ 1799.109027] [0001499004] mtlk0(mtlk_core_configuration_dump:10279): CID-0000: Selected Spectrum   : 40 MHz
[ 1799.118697] [0001499012] mtlk0(mtlk_core_configuration_dump:10280): CID-0000: Bonding             : 0
[ 1799.127926] [0001499020] mtlk0(mtlk_core_configuration_dump:10281): CID-0000: HT mode             : enabled
[ 1799.137671] [0001499032] mtlk0(mtlk_core_configuration_dump:10283): CID-0000: SM enabled          : enabled
[ 1799.147420] [0001499040] mtlk0(mtlk_aocs_set_config_frequency_band:2906): Overriding AOCS type for 2.4 GHz (NONE)
[ 1799.157688] [0001499052] mtlk0(_mtlk_mbss_send_preactivate:2199): CID-0000: Start AOCS
[ 1799.165880] [0001499060] mtlk0(_mtlk_mbss_send_preactivate:2211): CID-0000: ap_scan_band_cfg = 1
[ 1799.174416] [0001499068] mtlk0(_mtlk_core_perform_initial_scan:2075): CID-0000: AOCS is completely OFF (ch=1 type=0 20/40=0): skipping the Initial Scan
[ 1799.215182] [0001499108] mtlk0(_mtlk_channels_frequency_element_dump:2700): CID-0000: Channel        : 1
[ 1799.223363] [0001499116] mtlk0(_mtlk_channels_frequency_element_dump:2701): CID-0000: ChannelACT     : 0
[ 1799.232824] [0001499128] mtlk0(_mtlk_channels_frequency_element_dump:2702): CID-0000: ScanType       : 0
[ 1799.242322] [0001499136] mtlk0(_mtlk_channels_frequency_element_dump:2703): CID-0000: ChannelSwCnt   : 0
[ 1799.251812] [0001499144] mtlk0(_mtlk_channels_frequency_element_dump:2704): CID-0000: SwitchMode     : 16
[ 1799.261389] [0001499156] mtlk0(_mtlk_channels_frequency_element_dump:2705): CID-0000: SmRequired     : 0
[ 1799.270871] [0001499164] mtlk0(_mtlk_channels_frequency_element_dump:2706): CID-0000: CbTxPowerLim   : 128
[ 1799.280517] [0001499176] mtlk0(_mtlk_channels_frequency_element_dump:2707): CID-0000: nCbTxPowerLim  : 128
[ 1799.290182] [0001499184] mtlk0(_mtlk_channels_frequency_element_dump:2708): CID-0000: AntennaGain    : 0
[ 1799.299663] [0001499192] mtlk0(_mtlk_channels_frequency_element_dump:2709): CID-0000: ChannelLoad    : 0
[ 1799.309167] [0001499204] mtlk0(_mtlk_channels_frequency_element_dump:2711): CID-0000: MaxTxPwr[0]    : 0
[ 1799.318646] [0001499212] mtlk0(_mtlk_channels_frequency_element_dump:2712): CID-0000: MaxTxPwrIdx[0] : 0
[ 1799.328147] [0001499224] mtlk0(_mtlk_channels_frequency_element_dump:2711): CID-0000: MaxTxPwr[1]    : 0
[ 1799.337613] [0001499232] mtlk0(_mtlk_channels_frequency_element_dump:2712): CID-0000: MaxTxPwrIdx[1] : 0
[ 1799.347107] [0001499240] mtlk0(_mtlk_channels_frequency_element_dump:2711): CID-0000: MaxTxPwr[2]    : 0
[ 1799.356599] [0001499252] mtlk0(_mtlk_channels_frequency_element_dump:2712): CID-0000: MaxTxPwrIdx[2] : 0
[ 1799.366088] [0001499260] mtlk0(_mtlk_channels_frequency_element_dump:2714): CID-0000: SwitchType     : 0
[ 1799.378136] [0001499272] mtlk0(_mtlk_mbss_send_preactivate:2333): CID-0000: mtlk_txmm_msg_send_blocked, MsgId = 0x451
[ 1799.533352] [0001499428] mtlk0(_mtlk_mbss_send_preactivate:2352): CID-0000: _mtlk_mbss_send_preactivate returned successfully
[ 1799.543425] [0001499436] mtlk0(mtlk_mbss_init:2743): CID-0000: _mtlk_mbss_send_preactivate_if_needed returned successfully
[ 1799.554448] [0001499448] mtlk0(mtlk_mbss_send_vap_activate:2415): CID-0000: Entering mtlk_mbss_send_vap_activate
[ 1799.564542] [0001499460] mtlk0(mtlk_mbss_send_vap_activate:2422): CID-0000: Start activation
[ 1799.573035] [0001499468] mtlk0(mtlk_dump:61): dump of UMI_ACTIVATE_VAP:
[ 1799.579587] cp= 0x80a29c50 l=132
[ 1799.582776] 0000:  [ 1799.584710] 00
09 [ 1799.586648] 86
00 [ 1799.588658] 00
00 [ 1799.590654] 00
00  [ 1799.592753] 02
00 [ 1799.594742] 00
00 [ 1799.596753] 0a
00 [ 1799.598748] 00
00 [ 1799.600754]
[ 1799.602236] 0010:  [ 1799.604236] 74
65 [ 1799.606147] 73
74 [ 1799.608261] 2d
76 [ 1799.610151] 69
74  [ 1799.612333] 74
6f [ 1799.614241] 00
00 [ 1799.616336] 00
00 [ 1799.618245] 00
00 [ 1799.620344]
[ 1799.621735] 0020:  [ 1799.623643] 00
00 [ 1799.625651] 00
00 [ 1799.627645] 00
00 [ 1799.629654] 00
00  [ 1799.631736] 00
00 [ 1799.633745] 00
00 [ 1799.635740] 00
00 [ 1799.637749] 00
00 [ 1799.639742]
[ 1799.641315] 0030:  [ 1799.643150] 00
00 [ 1799.645148] 00
00 [ 1799.647142] 00
00 [ 1799.649152] 00
00  [ 1799.651233] 00
00 [ 1799.653242] 00
00 [ 1799.655237] 00
00 [ 1799.657247] 00
00 [ 1799.659240]
[ 1799.660819] 0040:  [ 1799.662647] 00
00 [ 1799.664645] 00
00 [ 1799.666639] 00
00 [ 1799.668648] 00
00  [ 1799.670730] 00
00 [ 1799.672740] 00
00 [ 1799.674734] 00
00 [ 1799.676742] 00
00 [ 1799.678737]
[ 1799.680309] 0050:  [ 1799.682144] 00
00 [ 1799.684237] 00
00 [ 1799.686137] 00
00 [ 1799.688231] 00
00  [ 1799.690227] 00
00 [ 1799.692335] 00
00 [ 1799.694231] 00
00 [ 1799.696337] 00
00 [ 1799.698234]
[ 1799.699711] 0060:  [ 1799.701725] 00
00 [ 1799.703632] 00
00 [ 1799.705640] 00
00 [ 1799.707635] 00
00  [ 1799.709734] 00
00 [ 1799.711724] 00
00 [ 1799.713736] 00
00 [ 1799.715730] 00
00 [ 1799.717735]
[ 1799.719219] 0070:  [ 1799.721230] 00
00 [ 1799.723128] 00
00 [ 1799.725138] 00
00 [ 1799.727132] 00
00  [ 1799.729232] 00
00 [ 1799.731221] 00
00 [ 1799.733232] 00
00 [ 1799.735226] 00
00 [ 1799.737232]
[ 1799.738716] 0080:  [ 1799.740717] 00
00 [ 1799.742625] 00
00 [ 1799.744631]
[ 1799.746142] [0001499640] mtlk0(mtlk_mbss_send_vap_activate:2473): CID-0000: UMI_ACTIVATE_VAP
[ 1799.754709] [0001499648] mtlk0(mtlk_mbss_send_vap_activate:2474): CID-0000:  sBSSID = 00:09:86:00:00:00
[ 1799.764108] [0001499660] mtlk0(mtlk_mbss_send_vap_activate:2475): CID-0000:  sSSID = test-vitto
[ 1799.772745] [0001499668] mtlk0(mtlk_mbss_send_vap_activate:2476): CID-0000:  Hidden = 0
[ 1799.780792] [0001499676] mtlk0(mtlk_dump:61):        sRSNie =
[ 1799.786084] cp= 0x80a29c84 l=80
[ 1799.789193] 0000:  [ 1799.791024] 00
00 [ 1799.793028] 00
00 [ 1799.795023] 00
00 [ 1799.797032] 00
00  [ 1799.799114] 00
00 [ 1799.801123] 00
00 [ 1799.803118] 00
00 [ 1799.805128] 00
00 [ 1799.807120]
[ 1799.808702] 0010:  [ 1799.810527] 00
00 [ 1799.812526] 00
00 [ 1799.814520] 00
00 [ 1799.816530] 00
00  [ 1799.818611] 00
00 [ 1799.820620] 00
00 [ 1799.822614] 00
00 [ 1799.824624] 00
00 [ 1799.826618]
[ 1799.828191] 0020:  [ 1799.830025] 00
00 [ 1799.832013] 00
00 [ 1799.834024] 00
00 [ 1799.836020] 00
00  [ 1799.838119] 00
00 [ 1799.840209] 00
00 [ 1799.842112] 00
00 [ 1799.844199] 00
00 [ 1799.846115]
[ 1799.847592] 0030:  [ 1799.849604] 00
00 [ 1799.851512] 00
00 [ 1799.853522] 00
00 [ 1799.855516] 00
00  [ 1799.857615] 00
00 [ 1799.859604] 00
00 [ 1799.861617] 00
00 [ 1799.863610] 00
00 [ 1799.865617]
[ 1799.867099] 0040:  [ 1799.869110] 00
00 [ 1799.871009] 00
00 [ 1799.873019] 00
00 [ 1799.875013] 00
00  [ 1799.877113] 00
00 [ 1799.879102] 00
00 [ 1799.881113] 00
00 [ 1799.883108] 00
00 [ 1799.885114]
[ 1799.886631] [0001499780] mtlk0(mtlk_mbss_send_vap_activate:2480): CID-0000: mtlk_txmm_msg_send, MsgId = 0x453, ESSID = test-vitto
[ 1799.901836] [0001499796] mtlk0(mtlk_mbss_init:2750): CID-0000: mtlk_mbss_send_vap_activate returned successfully
root@vitto-rtr1:/lib/firmware#
root@vitto-rtr1:/lib/firmware#
root@vitto-rtr1:/lib/firmware#
root@vitto-rtr1:/lib/firmware#
root@vitto-rtr1:/lib/firmware# uptime
 00:43:03 up 30 min,  load average: 1.10, 1.08, 0.92
root@vitto-rtr1:/lib/firmware#
root@vitto-rtr1:/lib/firmware#
root@vitto-rtr1:/lib/firmware# [ 1808.665864] CPU 0 Unable to handle kernel paging request at virtual address 00000044, epc == 80a05988, ra == 80a05968
[ 1808.675086] Oops[#1]:
[ 1808.677309] CPU: 0 PID: 0 Comm: swapper/0 Tainted: P                4.9.51 #0
[ 1808.684437] task: 8054fca0 task.stack: 80540000
[ 1808.688955] $ 0   : 00000000 81010000 00000001 85af9b40
[ 1808.694174] $ 4   : 85af9a00 80a18a42 00000000 00000015
[ 1808.699396] $ 8   : 00000000 00000000 00000000 00000000
[ 1808.704620] $12   : 00000000 00000c10 00000000 00000000
[ 1808.709841] $16   : 00000096 00000001 02080020 85af9a14
[ 1808.715064] $20   : 80a189ae 00000004 85af9a14 85afacc0
[ 1808.720287] $24   : 00000002 8000c64c
[ 1808.725509] $28   : 80540000 8780ddf0 80a10000 80a05968
[ 1808.730731] Hi    : 00000016
[ 1808.733609] Lo    : 00000000
[ 1808.736519] epc   : 80a05988 mtlk_nl_send_brd_msg+0x118/0x1cc [mtlkroot]
[ 1808.743206] ra    : 80a05968 mtlk_nl_send_brd_msg+0xf8/0x1cc [mtlkroot]
[ 1808.749796] Status: 1100ff03 KERNEL EXL IE
[ 1808.753975] Cause : 00800008 (ExcCode 02)
[ 1808.757979] BadVA : 00000044
[ 1808.760853] PrId  : 00019556 (MIPS 34Kc)
[ 1808.764764] Modules linked in: mtlk(P) mtlkroot(P) ltq_ptm_vr9 pppoe nf_conntrack_ipv6 iptable_nat ipt_REJECT ipt_MASQUERADE xt_time xt_tcpudp xt_state xt_nat xt_multiport xt_mark xt_mac xt_limit xt_conntrack xt_comment xt_TCPMSS xt_REDIRECT xt_LOG pppox ppp_async nf_reject_ipv4 nf_nat_redirect nf_nat_masquerade_ipv4 nf_conntrack_ipv4 nf_nat_ipv4 nf_nat nf_log_ipv4 nf_defrag_ipv6 nf_defrag_ipv4 nf_conntrack_rtcache nf_conntrack ltq_deu_vr9 lib80211_crypt_wep lib80211_crypt_tkip lib80211_crypt_ccmp lib80211 iptable_mangle iptable_filter ip_tables crc_ccitt compat drv_dsl_cpe_api ledtrig_usbport drv_mei_cpe ip6t_REJECT nf_reject_ipv6 nf_log_ipv6 nf_log_common ip6table_mangle ip6table_filter ip6_tables x_tables pppoatm ppp_generic slhc br2684 atm drv_ifxos dwc2 gpio_button_hotplug
[ 1808.833804] Process swapper/0 (pid: 0, threadinfo=80540000, task=8054fca0, tls=00000000)
[ 1808.841882] Stack : 0000005c 80073dc4 87907400 80a189b8 00000000 00000001 85afa480 00000000
[ 1808.850236]         809e0814 8054d0a0 80a189ae 87907010 80a189a2 879070c8 00000004 854145d0
[ 1808.858591]         00000001 80543f60 80543f60 00000001 00000004 80a189ae 00000096 80a189a2
[ 1808.866947]         8115a2ac 879070cc 00000000 8007318c 00000000 80062828 00000000 8115cc94
[ 1808.875302]         8115ccf8 8000c78c 858d7a14 8547da40 87846990 16569a59 00000016 00000000
[ 1808.883658]         ...
[ 1808.886100] Call Trace:
[ 1808.888578] [<80a05988>] mtlk_nl_send_brd_msg+0x118/0x1cc [mtlkroot]
[ 1808.895142] [<854145d0>] mtlk_xmit+0xf0c/0x25f4 [mtlk]
[ 1808.900247] Code: 8fa2004c  24e7ffff  00e23821 <8c020044> 00e2102b  1440000b  00003025  3c0280a1  9043e8a0
[ 1808.909771]
[ 1808.911371] ---[ end trace 0502fb61c099b461 ]---
[ 1808.921951] Kernel panic - not syncing: Fatal exception in interrupt
[ 1808.933834] Rebooting in 3 seconds..

To me, now the culprit seems to be around the mtlk_nl_send_brd_msg() function. Interestingly, the OpenWRT build I had tried previously errored out at the same function, however during the insmod not ifconfig up command..

@lpm11 I copied over your old mips stuff. Thanks

Managed to get UART connected. My error log looks similar to vittorio88:

[  278.839351] [4294946008] mtlk0(mtlk_dump:61): dump of recvd .11n packet
[  278.844597] cp= 0x82704cae l=64
[  278.847692] 0000:  40 00 00 00 ff ff ff ff  ff ff 8c f5 a3 18 2b 32 
[  278.853997] 0010:  ff ff ff ff ff ff a0 f2  00 0c 56 6f 64 61 66 6f 
[  278.860351] 0020:  6e 65 57 69 46 69 01 08  0c 12 18 24 30 48 60 6c 
[  278.866705] 0030:  2d 1a ef 01 17 ff ff 00  00 00 00 00 00 00 00 00 
[  278.873124] [4294946044] mtlk0(mtlk_dump:61): 802.11n head:
[  278.878668] cp= 0x82704cae l=24
[  278.881803] 0000:  40 00 00 00 ff ff ff ff  ff ff 8c f5 a3 18 2b 32 
[  278.888117] 0010:  ff ff ff ff ff ff a0 f2  
[  278.892420] [4294946060] mtlk0(mtlk_dump:61): HTCap information element
[  278.899041] cp= 0x82704cde l=28
[  278.902166] 0000:  2d 1a ef 01 17 ff ff 00  00 00 00 00 00 00 00 00 
[  278.908484] 0010:  00 00 00 00 00 00 00 00  00 00 00 00 
[  278.913862] CPU 0 Unable to handle kernel paging request at virtual address 00000044, epc == 82ee7514, ra == 82ee74f4
[  278.924470] Oops[#1]:
[  278.926697] CPU: 0 PID: 0 Comm: swapper/0 Tainted: P                4.4.14 #5
[  278.933824] task: 805278d8 ti: 80518000 task.ti: 80518000
[  278.939212] $ 0   : 00000000 00000001 00000001 832cd800
[  278.944431] $ 4   : 832cd8a4 82704d32 00000000 00000016
[  278.949653] $ 8   : 00000000 070050f2 08001000 dd090010
[  278.954875] $12   : 00000141 00000141 00000000 8067d9b8
[  278.960098] $16   : 02080020 00000087 0000008f 00000004                                              
[  278.965321] $20   : 00000001 8274b3c0 82704cae 82ef0000
[  278.970543] $24   : 00000003 00000000                                                               
[  278.975765] $28   : 80518000 80519bb8 832cd814 82ee74f4
[  278.980988] Hi    : 0000005a
[  278.983864] Lo    : d70a3edc
[  278.986775] epc   : 82ee7514 mtlk_nl_send_brd_msg+0x114/0x1d0 [mtlkroot]
[  278.993459] ra    : 82ee74f4 mtlk_nl_send_brd_msg+0xf4/0x1d0 [mtlkroot]
[  279.000054] Status: 1100ff03 KERNEL EXL IE 
[  279.004230] Cause : 00800008 (ExcCode 02)
[  279.008235] BadVA : 00000044
[  279.011110] PrId  : 00019556 (MIPS 34Kc)
[  279.015022] Modules linked in: mtlk(P) mtlkroot(P) ltq_atm_vr9 ath9k ath9k_common iptable_nat ath9k_hw ath pppoe nf_nat_ipv4 nf_conntrack_ipv6 nf_conntrack_ipv4 mac80211 ipt_REJECT ipt_MASQUERADE cfg80211 xt_time xt_tcpudp xt_state xtl
[  279.087272] Process swapper/0 (pid: 0, threadinfo=80518000, task=805278d8, tls=00000000)
[  279.095360] Stack : 82704cae 00000001 000004e7 00000011 00000000 00000001 8339ea80 00000004
          82d7f814 00000000 82704cae 81cd0000 833bb0d8 833bb010 80524480 81c17a2c
          00000000 00000000 833bb2e8 00000001 00000004 00000004 00000087 82704ca2
          82704cb8 82704ca2 833bb0dc 00000000 00000001 81ca6b9c 0000001e 00000000
          00000040 800713c8 00000040 806a0000 00000000 00000182 00000000 824ea810
          ...
[  279.130872] Call Trace:
[  279.133335] [<82ee7514>] mtlk_nl_send_brd_msg+0x114/0x1d0 [mtlkroot]
[  279.139914] [<81c17a2c>] mtlk_xmit+0x1118/0x2b18 [mtlk]
[  279.145096] 
[  279.146364] 
Code: 8fa2004c  24e7ffff  00e23821 <8c020044> 00e2102b  14400013  3c038054  3c1082ef  920246d0 
[  279.156368] ---[ end trace e4d43fd1765e5860 ]---
[  279.164627] Kernel panic - not syncing: Fatal exception in interrupt
[  279.173088] Rebooting in 3 seconds..

Also, I wrote some script for the wireless config file. Does it look ok?

config wifi-device 'radio1'
    option type 'mtlk'
    option macaddr '00:09:86:00:00:00'
    option channel '52'
    option hwmode '11a
    option txpower '15'
    option country 'GB'

config wifi-iface
    option device 'radio1'
    option mode 'ap'
    option ssid 'test'
    option network 'lan'
    option encryption 'psk2'
    option key 'test5g'

With this code in place, at the moment, my router won't bring up wifi (i.e. radio0 doesn't come up) on a reboot. I guess because radio1 isn't present until I load the kernel modules for mtlk.

@blackadder1000 - it looks ok

@vittorio88 @blackadder1000 problem is the same.
Could you try to swap the option in menuconfig MTCFG_USE_GENL (enable it if it was not set, or disable if it was set), recompile and check again.
I am afraid I have no idea about netlink sockets.

@lpm11 That change seems to have done it. No crashes so far.
My CONFIG_USE_GENL was enabled. It is now disabled.

To achieve this I enabled the option 'Don't use generic netlink socket' in make menuconfig -> Features

Now looking at config. With my wireless config setup including the radio1 code from my previous post (as well as my regular radio0 code) I get no interfaces (wlan0 - 2.4GHz or wlan1 - 5GHz). Not seeing any dmesg errors and I don't know where openwrt puts errors associated with config files.

Separately, I tried scanning with "iwlist wlan1 scan" but I get the error "Interface doesn't support scanning : Resource busy".
dmesg shows the following error:

 mtlk4(_mtlk_core_async_clb:376): Requested ability 0x1000007 is disabled or never was registered

(Last edited by blackadder1000 on 1 Oct 2017, 23:42)

Thats great, congratulations!!

I think that scanning just doesn't work in ap mode. Driver internally does scans, but it is not possible to get the results.

I'm making some progress but not quite there.

I can't get mtlk-ap and mtlk-sta to work at all. If I run "sh mtlk-ap", just to test it, it errors:

mtlk-ap: line 1: syntax error: unexpected "("

But I don't think I need it(?)

@lpm11 I can get v. close using your mtlk.sh script. I've had to modify it a bit, firstly to change "mtlk0" to "wlan1".
And to get around the fact that mtlk-ap isn't working I'm using iwconfig to set up the ssid, which would otherwise be set with mtlk-ap.

So I added, to mtlk.sh, the line:

[ "$ssid" ] && iwconfig "$iface" essid "$ssid"

As I've mentioned a few times I've also set up /etc/config/wireless, as mentioned in previous posts

Placing mtlk.sh in /lib/wifi and the kernel modules in /lib/modules/4.4.14 means that on reboot openwrt configures the interface with channel, ssid etc. and I can simply bring it up with "ifconfig wlan1 up".

My final piece is getting the interface to pass traffic. I can connect to the test network ssid with a static ip address but can't get traffic going.

The mtlk.sh configures the interface on a bridge with brctl addif br-"$network" "$iface"
which I can confirm with "brctl show" but no traffic so far.

So bad sad It seems that these binaries are incompatible with LEDE.
They was prepared to work with OpenWRT AA.

Actually mtlk-ap is just hostapd with support for mtlk driver.

You have to compile hostapd with the mtlk driver from github (https://github.com/benjaminlevine/WAVE3 … ver_mtlk.c), probably do a manual merge. After that, please rename hostapd to mtlk-ap - script mtlk.sh should launch it.
Do not add official LEDE/OpenWRT patches for wpad/hostapd to this compilation.

The similar thing is with wpa_supplicant, but this case wext driver works - no need for patching.

I've cross compiled hostapd-2.6 with the manual merge of the mtlk driver.

hostapd (renamed to mtlk-ap) runs on my hardware and is placed in /sbin. The script mtlk.sh, together with mtlk-ap configures the WAVE300 hardware (i.e. it sets as SSID which I was previously having to do with iwconfig).

However, I still have no network traffic, no dhcp etc.
Are there further ways I can test mtlk-ap?

Hi,

@blackadder1000, is the SSID visible from other devices?

I tried disabling CONFIG_USE_GENL as well, however I have a new issue upon insmodding.

root@vitto-rtr1:~/vitto_wav300_lede-trunk_ugw5.1-vrx288-nand_v2# insmod mtlkroot
.ko cdebug=2
[   61.272507] mtlkroot: module license 'Proprietary' taints kernel.
[   61.277228] Disabling lock debugging due to kernel taint
[   61.287117] Assertion failed [SLID:7:5:0:226]
[   61.290038] Kernel bug detected[#1]:
[   61.293619] CPU: 1 PID: 1861 Comm: insmod Tainted: P                4.9.51 #0
[   61.300740] task: 87939700 task.stack: 80d04000
[   61.305257] $ 0   : 00000000 00000001 00000021 00000000
[   61.310472] $ 4   : 812e62dc 812e62dc 812e8f00 80550000
[   61.315698] $ 8   : 80550000 00010000 353a303a 3232365d
[   61.320918] $12   : 205b534c 00000000 00000000 49443a37
[   61.326140] $16   : 80e4e940 00000000 8054d0a0 80e50000
[   61.331366] $20   : 00000045 80d05cbc 00000036 80e50000
[   61.336601] $24   : 00000000 80025584
[   61.341808] $28   : 80d04000 80d05c08 8009a3e8 80e477e4
[   61.347039] Hi    : 00000001
[   61.349899] Lo    : 00000000
[   61.352876] epc   : 80e477e4 __mtlk_assert+0x34/0x14c [mtlkroot]
[   61.358853] ra    : 80e477e4 __mtlk_assert+0x34/0x14c [mtlkroot]
[   61.364794] Status: 1100c303 KERNEL EXL IE
[   61.368970] Cause : 10800024 (ExcCode 09)
[   61.372989] PrId  : 00019556 (MIPS 34Kc)
[   61.376893] Modules linked in: mtlkroot(P+) ltq_ptm_vr9 pppoe nf_conntrack_ipv6 iptable_nat ipt_REJECT ipt_MASQUERADE xt_time xt_tcpudp xt_state xt_nat xt_multiport xt_mark xt_mac xt_limit xt_conntrack xt_comment xt_TCPMSS xt_REDIRECT xt_LOG pppox ppp_async nf_reject_ipv4 nf_nat_redirect nf_nat_masquerade_ipv4 nf_conntrack_ipv4 nf_nat_ipv4 nf_nat nf_log_ipv4 nf_defrag_ipv6 nf_defrag_ipv4 nf_conntrack_rtcache nf_conntrack ltq_deu_vr9 lib80211_crypt_wep lib80211_crypt_tkip lib80211_crypt_ccmp lib80211 iptable_mangle iptable_filter ip_tables crc_ccitt compat drv_dsl_cpe_api ledtrig_usbport drv_mei_cpe ip6t_REJECT nf_reject_ipv6 nf_log_ipv6 nf_log_common ip6table_mangle ip6table_filter ip6_tables x_tables pppoatm ppp_generic slhc br2684 atm drv_ifxos dwc2 gpio_button_hotplug
[   61.445315] Process insmod (pid: 1861, threadinfo=80d04000, task=87939700, tls=77821d48)
[   61.453400] Stack : 00000000 00000007 00000005 00000000 000000e2 87806a08 8563bb00 80e40acc
[   61.461747]         854d9a80 87b91120 000000c3 80d05c80 80cfcf80 80e4e940 00000007 8054d0a0
[   61.470102]         80e50000 80e40c10 00000000 87806a08 00000000 80e4f6c0 80e4f6c8 80e42604
[   61.478457]         80e4e940 80e409d8 878d6d40 00000000 81086b80 00000000 00000007 00000045
[   61.486813]         00000003 0000003b 00000033 00000036 024000c0 80e4bcfc 80cfce24 024000c0
[   61.495170]         ...
[   61.497609] Call Trace:
[   61.500146] [<80e477e4>] __mtlk_assert+0x34/0x14c [mtlkroot]
[   61.505848] [<80e40acc>] mtlk_log_get_free_buf+0xcc/0x248 [mtlkroot]
[   61.512174] [<80e40c10>] mtlk_log_get_free_buf+0x210/0x248 [mtlkroot]
[   61.518565] Code: afbf001c  0c02b48f  2484de48 <000c000d> 00000000  00000000  27bdffe8  afb00010  afbf0014
[   61.528246]
[   61.529838] ---[ end trace d10087fe54d9ae07 ]---
[   61.539550] Kernel panic - not syncing: Fatal exception in interrupt
[   61.547329] Rebooting in 3 seconds..

Any ideas?

I did successfully compile hostapd but not wpa_supplicant. I get undefined reference errors as follows:

/root/WAVE300/hostap08/hostapd/../src/wps/wps_registrar.c:3080: undefined reference to `upnp_wps_device_send_wlan_event'
/root/WAVE300/hostap08/hostapd/../src/crypto/tls_internal.c:50: undefined reference to `tlsv1_server_global_init'

@vittorio88 Yes the SSID is visible from other devices and I can connect successfully if I set a static ip address.

Sorry about your further problems.

Regarding hostapd: you can try a newer version of hostapd with the patch here:
https://github.com/benjaminlevine/hostapd-devel-mtlk

blackadder1000 wrote:

@vittorio88 Yes the SSID is visible from other devices and I can connect successfully if I set a static ip address.

Sorry about your further problems.

Regarding hostapd: you can try a newer version of hostapd with the patch here:
https://github.com/benjaminlevine/hostapd-devel-mtlk

Cool, if you can connect, then I believe that means hostapd is working to an extent.
Do pings pass?


Good work with the hostapd-devel-mtlk repo.

I am still having driver issues unfortunately. I am testing with the following commands before throwing hostapd into the mix:

iwpriv wlan0 sCountry IT
iwconfig wlan0 essid test-vitto
iwconfig wlan0 channel 1
ifconfig wlan0 up

No, unfortunately pings don't pass.

Does your hardware support channel 1?
What does "iwlist wlan0 channel" report?

My hardware only supports channel 36 and above.

As I remember, mtlk.sh script should add mtlk0 interface to bridge lan interface, set parameter with iwpriw and in hostapd config.

After that it should work, but I do not remember exact names of these params - look at the mtlk.sh.
If it does not, maybe older hostapd is needed.

lpm11 wrote:

As I remember, mtlk.sh script should add mtlk0 interface to bridge lan interface, set parameter with iwpriw and in hostapd config.

After that it should work, but I do not remember exact names of these params - look at the mtlk.sh.
If it does not, maybe older hostapd is needed.

hostapd 2.3

I'm trying hostapd 0.8 - the one included with the WAVE300 sources. It should work. right? I mean it comes with the driver sources!

All compiles fine.

Here's my hostapd config (generated by mtlk.sh, with an addition to specify hw_mode):

driver=mtlk
interface=wlan1
channel=40
bridge=br-lan
ssid=testing5g
hw_mode=a

Here's the hostapd/mtlk-ap error log:

root@Router:~# mtlk-ap -d /tmp/mtlk
random: Trying to read entropy from /dev/random
Configuration file: /tmp/mtlk
Configure bridge br-lan for EAPOL traffic.
mtlk_set_iface_flags: dev_up=0
SIOCGIWRANGE: WE(compiled)=22 WE(source)=18 enc_capa=0x0
BSS count 1, BSSID mask 00:00:00:00:00:00 (0 bits)
wlan1: IEEE 802.11 Fetching hardware channel/rate support not supported.
Completing interface initialization
Mode: IEEE 802.11a  Channel: 40  Frequency: 0 MHz
Flushing old station entries
Deauthenticate all stations
mtlk_sta_deauth
ioctl[SIOCSIWMLME]: Not supported
mtlk_set_encryption: alg=0 addr=00:00:00:00:00:00 key_idx=0 txkey=0
mtlk_set_encryption: alg=0 addr=00:00:00:00:00:00 key_idx=1 txkey=0
mtlk_set_encryption: alg=0 addr=00:00:00:00:00:00 key_idx=2 txkey=0
mtlk_set_encryption: alg=0 addr=00:00:00:00:00:00 key_idx=3 txkey=0
Using interface wlan1 with hwaddr 00:09:86:00:00:00 and ssid 'testing5g'
mtlk_set_iface_flags: dev_up=1
wlan1: Setup of interface done.
random: Got 20/20 bytes from /dev/random
l2_packet_receive - recvfrom: Network is down
Wireless event: cmd=0x8c03 len=20
wlan1: STA c0:ee:fb:32:6d:45 IEEE 802.11: associated
STA did not include WPS/RSN/WPA IE in (Re)AssocReq
  New STA
wlan1: STA c0:ee:fb:32:6d:45 RADIUS: starting accounting session 59E29651-00000000
IEEE 802.1X: Ignore STA - 802.1X not enabled or forced for WPS
Wireless event: cmd=0x8c04 len=20
wlan1: STA c0:ee:fb:32:6d:45 IEEE 802.11: disassociated
wlan1: AP-STA-DISCONNECTED c0:ee:fb:32:6d:45

Something like this:

IEEE 802.1X: Ignore STA - 802.1X not enabled or forced for WPS

is probably a problem. No idea at this moment (maybe inspecting into a source code is needed), but is WPS disabled? All my tests were on disabled WPS.

Hi Blackadder1000,

This sounds more to me like a hostapd configuration problem.

The frequency of 0 MHz in your log is fishy, isn't it?

Mode: IEEE 802.11a  Channel: 40  Frequency: 0 MHz

I'd suggest you add to your file:

ieee80211n=1
ht_capab=[HT40-]

Thanks for your efforts and good luck,
Mandrake