If you see encrypted AP - there is a progress!
Could you launch mtlk-ap, but with debug flags? I am not sure, something like mtlk-ap -dd (and the rest)
Or https://stackoverflow.com/a/32209729
I would like to know what build source is being worked on and which driver source is currently working. Last time I tried to build the driver I could not make it work.
Hello @Smim0,
You're far ahead of me now. Nonetheless, I think I can do a small contribution.
In the link you will find some scripts used in the original Livebox image (I believe). These scripts will setup the driver in different modes.
I believe you will find most interesting the S90* files. I guess the ones ending with _br means bridge.
https://ufile.io/02az062f
What I see strange is that always sBridgeMode=0
Also there's a hostapd.conf file.
Hope this helps you
Smim0
230
Here is some progress:
Something was wrong with config file I used in the beginning, taking the encryption options from the one provided by @Mandrake-Lee now I can connect to the AP with the password, iperf results are the same no increase nor decrease in the speed.
Here is the content of my config file now:
# the interface used by the AP
interface=wlan0
# "g" simply means 2.4GHz band
driver=mtlk
hw_mode=g
# the channel to use
#channel=11
# limit the frequencies used to those allowed in the country
#ieee80211d=1
# the country code
country_code=ES
# 802.11n support
# QoS support, also required for full speed on 802.11n/ac/ax
wmm_enabled=0
bridge=br-lan
# the name of the AP
ssid=test
# 1=wpa, 2=wep, 3=both
auth_algs=1
# WPA2 only
wpa=2
wpa_key_mgmt=WPA-PSK
wpa_passphrase=test1234
wpa_group_rekey=600
wpa_gmk_rekey=86400
wpa_pairwise=TKIP CCMP
logger_syslog=-1
logger_syslog_level=4
logger_stdout=-1
logger_stdout_level=4
What I noticed is that I have the same MAC address as @Mandrake-Lee so maybe it is loaded from ap_upper_wave300.bin file that we are both using.
@ahmar16 I am still using the old soruces from @pc2005, the issue I had with compiling it few weeks ago (I think you had the same one) was because of the lack of libnl package in OpenWrt
Thanks @Mandrake-Lee and @lukasz92 for the help, I think this finally going somewhere 
Smim0
231
These files are interesting, I am not an expert in bash scripting but I can see that these are the files to launch the driver, the wifi and in different modes.
I see that you are still stuck, please do the following:
1- Copy these 2 files only to /lib/firmware/
ap_upper_wave300.bin
contr_lm.bin
2- Insert the driver, with those 2 files should be enough
3- Then launch hostapd (or mtlk-ap) with the config file
4- Then for every file the log shows that you need copy it from the original Livebox firmware files (just add _wave300 at the end of the name)
In total there are 4 files needed:
ProgModel_BG_CB_39_RevA_wave300.bin
ProgModel_BG_CB_wave300.bin
ProgModel_BG_nCB_39_RevA_wave300.bin
ProgModel_BG_nCB_wave300.bin
Now we need to figure out how to backport the sta_upper file from version 3.1 or 3.2 to work with 3.4, maybe to see also how to compile hostapd from OpenWrt and last not least to see why OpenWrt crashes when the driver module mtlk.ro is unloaded
Cheers
I don't think STA could work with anything other than 3.2. No repeater, no WDS, no P2P - I think we could have only AP driver and nothing more.
MAC address is not stored in hardware, one must read it from somewhere else.
In order to unload mtlk.ko driver, first you have to stop all hostapd instances for wave300 interfaces (or interface wlan0 if you do not set VAP), and set each interface down (ifconfig wlan0 down if you do not set VAP). Than you can unload mtlk.ko without crash.
Things needed to implement:
- prepare OpenWRT driver (to be able to use /etc/config/wireless)
- patch Luci to enable WPA/WPA2 selection, disable other modes than AP, disable scanning (useless on AP mode)
- patch iwinfo to be able to get info about connected stations
- test, test, test
@Smim0 could you share again your speed tests on WPA2 (with iperf)?
Smim0
233
Hello,
This what iperf gives me a couple of meters away from the router
[ ID] Interval Transfer Bandwidth
[ 4] 0.00-1.00 sec 751 KBytes 6.12 Mbits/sec
[ 4] 1.00-2.00 sec 950 KBytes 7.79 Mbits/sec
[ 4] 2.00-3.00 sec 643 KBytes 5.26 Mbits/sec
[ 4] 3.00-4.00 sec 1.43 MBytes 12.0 Mbits/sec
[ 4] 4.00-5.00 sec 849 KBytes 6.98 Mbits/sec
[ 4] 5.00-6.00 sec 1.17 MBytes 9.78 Mbits/sec
[ 4] 6.00-7.00 sec 1.43 MBytes 12.0 Mbits/sec
[ 4] 7.00-8.00 sec 799 KBytes 6.56 Mbits/sec
[ 4] 8.00-9.00 sec 1.34 MBytes 11.2 Mbits/sec
[ 4] 9.00-10.00 sec 1.28 MBytes 10.8 Mbits/sec
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bandwidth
[ 4] 0.00-10.00 sec 10.6 MBytes 8.85 Mbits/sec sender
[ 4] 0.00-10.00 sec 10.4 MBytes 8.70 Mbits/sec receiver
iperf Done.
targa
234
I have an unused vr200v if I can help testing. /T.
I have a Netgear D6100 (from beta testing) and on firmware 1.0.0.63 (latest) I get 30 Mbps from my phone to my local server, while I get 100+ Mbps using a different router.
Someone mentioned in Netgear forums that the slowdown came few releases ago together with security fixes.
While 10-12 Mbps is still low, maybe you cannot achieve much more.
I haven't followed the whole thread, I'm not sure which sources or which closed source binaries you are using.
I wonder if scripts from https://ufile.io/02az062f could possibly help to get list of settings you can play with (with iwpriv cmd), possibly increasing throughput of radio. 12Mbps is a bad result even for 802.11g
Smim0
237
I don't think STA could work with anything other than 3.2. No repeater, no WDS, no P2P - I think we could have only AP driver and nothing more.
it looks like @suleiman could backport files from version 3.2 to work with 3.5, let's see if he can post his findings. What is curious is that if you try to insert the driver with no option (without ap=1) it looks for the file sta_upper_wave300.bin which means that it tries to bring wlan0 in STA mode by default nevertheless sta_upper_wave300.bin is absent in version 3.5.
MAC address is not stored in hardware, one must read it from somewhere else.
True, it is stored in cal_wlan0.bin file, the problem is that for LiveBox this file is incompatible as it contains data for 5GHZ only
n order to unload mtlk.ko driver, first you have to stop all hostapd instances for wave300 interfaces (or interface wlan0 if you do not set VAP), and set each interface down (ifconfig wlan0 down if you do not set VAP). Than you can unload mtlk.ko without crash.
Tried that but router still crashes even if I try to unload it after loading it immediatly
In the scripts provided my @Mandrake-Lee I found this option insmod mtlk.ro ap=1,1, which is used to launch multiple APs but it doesn't work with the actual driver it brings up wlan0 only
Cheers
I had this https://openwrt.org/toh/vtech/netiaspot device
It never contained cal_wlan0.bin, but probably MAC was set by OpenRG - I think that some private ioctl can set mac address.
I never tried unload module just after loading.
mtlk.ko ap=1,1 makes only sense if there are 2 Wave300 cards - one for 2.4GHz and one for 5GHz.
You have to call some iwpriv command to bring up VAP
Dear @smim0 and team,
-
I'm starting to port the hostapd code from Lantiq UGW 7.1.1 (latest known) to current Openwrt. So far the compilation is done but fails to recognize the wlan0 interface. I will share the patches when reasonably done.
-
In regards to the MAC address, there's an interesting command. I've got the feeling that the communication with the eeprom is not working and therefore it falls back to default values
root@OpenWrt:/# iwpriv wlan0 gEEPROM
[ 3625.795879] mtlk 0000:01:00.0: Direct firmware load for cal_wlan0.bin failed with error -2
[ 3625.802813] mtlk 0000:01:00.0: Falling back to user helper
[ 3625.948216] firmware cal_wlan0.bin: firmware_loading_store: map pages failed
[ 3625.954290] [0003325864] mtlk3(_mtlk_df_fw_request_firmware:63): Firmware (cal_wlan0.bin) is missing
wlan0 gEEPROM:
EEPROM version: 4.1
EEPROM MAC : 00:12:34:00:00:00
EEPROM country: ??
HW type : 0x39
HW revision : 0x41 (A)
HW ID : 0x1a30,0x710,0x1a30,0x711
Serial number : 0112c8
Week/Year : 35/14
EEPROM header binary dump:
0000: fc 1b 06 07 00 00 80 0d 01 00 00 00 00 00 00 00
0010: 30 1a 11 07 00 00 00 00 08 00 ff ff 08 00 00 ff
0020: 00 00 00 00 30 1a 10 07 ff ff ff ff ff ff ff ff
0030: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
0040: c0 03 00 00 00 00 01 04
- Regarding speed, this post from @paldier hints that full speed may need to have access to eeprom (so the point above)
- Last not least, maybe the code is preventing STA mode to be loaded and there's no real issue but to amend the sources. But this is a TODO thing.
Thanks all for your work and stay safe!
I have a few findings to share about the driver:
-
There is a stream of debug messages related to MAC address being not found (probably) and it may be causing a load on CPU because in idle condition with only 2% of CPU usage the load average is more than 1. This is also noticeable with heartbeat LED trigger. The stream of messages is visible with flags of cdebug=3 with mtlkroot.ko. This could be related to the issue above.
-
I am not able to make the WiFi turn on and see the network and it crashes the router when I issue ifconfig wlan1 up. I have a WAVE300 5GHz wireless chip, the router is TpLink TD-W8980 V1 and lspci shows this 00:0e.0 Wireless controller: Lantiq Wave300 PSB8224 [Hyperion III] (rev 01).
-
The driver asks for "A_CB" & "A_nCB" 38_RevA ProgModel files which I have provided and I also set other attributes but it still crashes. I am using v19.07.2 with Linux v4.14.171.
root@AP254:/# iwpriv wlan1 sMAC 12:34:56:78:90:ab
root@AP254:/# iwconfig wlan1 essid openwrt
root@AP254:/# iwconfig wlan1 channel 153
root@AP254:/# ifconfig wlan1
wlan1 Link encap:Ethernet HWaddr 12:34:56:78:90:AB
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)
root@AP254:/# ifconfig wlan1 up
[ 233.621647] [4294900804] mtlk0(mtlk_mbss_init:3457): CID-0000: _mtlk_core_mbss_check_activation_params returned successfully
[ 233.631697] [4294900812] mtlk0(_mtlk_mbss_preactivate:2917): CID-0000: Pre-activation configured parameters:
[ 233.641497] [4294900824] mtlk0(mtlk_core_configuration_dump:4938): CID-0000: Country : US
[ 233.650762] [4294900832] mtlk0(mtlk_core_configuration_dump:4939): CID-0000: Domain : 16
[ 233.659922] [4294900844] mtlk0(mtlk_core_configuration_dump:4940): CID-0000: Network mode : 802.11an
[ 233.669691] [4294900852] mtlk0(mtlk_core_configuration_dump:4941): CID-0000: Band : 5.2
[ 233.678993] [4294900860] mtlk0(mtlk_core_configuration_dump:4942): CID-0000: Prog Model Spectrum : 40 MHz
[ 233.688862] [4294900872] mtlk0(mtlk_core_configuration_dump:4943): CID-0000: Selected Spectrum : 40 MHz
[ 233.698234] [4294900880] mtlk0(mtlk_core_configuration_dump:4944): CID-0000: User Sel. Spectrum : 40 MHz
[ 233.708037] [4294900892] mtlk0(mtlk_core_configuration_dump:4945): CID-0000: Bonding : lower
[ 233.717490] [4294900900] mtlk0(mtlk_core_configuration_dump:4946): CID-0000: HT mode : enabled
[ 233.726815] [4294900908] mtlk0(mtlk_core_configuration_dump:4948): CID-0000: SM enabled : enabled
[ 233.736568] [4294900920] mtlk0(_mtlk_mbss_preactivate:2932): CID-0000: Start AOCS
[ 233.745692] [4294900928] mtlk0(_mtlk_mbss_preactivate:2945): CID-0000: ap_scan_band_cfg = 0
[ 233.752889] [4294900936] mtlk0(_mtlk_core_perform_initial_scan:2714): CID-0000: AOCS and 20/40 Coexistence are completely OFF (ch=153 type=0 20/40=0): skipping the Initial Scan
[ 233.787526] [4294900968] mtlk0(prepare_progmodel_string:2061): CID-0000: ProgModel: ProgModel_A_CB_38_RevA_wave300.bin version 1668
[ 233.787526]
[ 233.799960] [4294900980] mtlk0(_mtlk_mbss_preactivate:3044): CID-0000: Pre-activation selected parameters:
[ 233.809209] [4294900992] mtlk0(mtlk_core_configuration_dump:4938): CID-0000: Country : US
[ 233.818476] [4294901000] mtlk0(mtlk_core_configuration_dump:4939): CID-0000: Domain : 16
[ 233.827677] [4294901008] mtlk0(mtlk_core_configuration_dump:4940): CID-0000: Network mode : 802.11an
[ 233.837431] [4294901020] mtlk0(mtlk_core_configuration_dump:4941): CID-0000: Band : 5.2
[ 233.846742] [4294901028] mtlk0(mtlk_core_configuration_dump:4942): CID-0000: Prog Model Spectrum : 40 MHz
[ 233.856321] [4294901040] mtlk0(mtlk_core_configuration_dump:4943): CID-0000: Selected Spectrum : 40 MHz
[ 233.865898] [4294901048] mtlk0(mtlk_core_configuration_dump:4944): CID-0000: User Sel. Spectrum : 40 MHz
[ 233.875468] [4294901056] mtlk0(mtlk_core_configuration_dump:4945): CID-0000: Bonding : lower
[ 233.884969] [4294901068] mtlk0(mtlk_core_configuration_dump:4946): CID-0000: HT mode : enabled
[ 233.894633] [4294901076] mtlk0(mtlk_core_configuration_dump:4948): CID-0000: SM enabled : enabled
[ 233.906963] _mtlk_core_send_current_debug_tpc 0
[ 233.910631] _mtlk_core_send_lna_gains_on_preactivate 0
[ 233.915513] [4294901096] mtlk0(_mtlk_channels_frequency_element_dump:3117): CID-0000: Channel : 153
[ 233.924994] [4294901108] mtlk0(_mtlk_channels_frequency_element_dump:3118): CID-0000: ChannelACT : 0
[ 233.934476] [4294901116] mtlk0(_mtlk_channels_frequency_element_dump:3119): CID-0000: ScanType : 0
[ 233.943971] [4294901128] mtlk0(_mtlk_channels_frequency_element_dump:3120): CID-0000: ChannelSwCnt : 0
[ 233.953446] [4294901136] mtlk0(_mtlk_channels_frequency_element_dump:3121): CID-0000: SwitchMode : 48
[ 233.963019] [4294901144] mtlk0(_mtlk_channels_frequency_element_dump:3122): CID-0000: SmRequired : 0
[ 233.972530] [4294901156] mtlk0(_mtlk_channels_frequency_element_dump:3123): CID-0000: CbTxPowerLim : 194
[ 233.982191] [4294901164] mtlk0(_mtlk_channels_frequency_element_dump:3124): CID-0000: nCbTxPowerLim : 194
[ 233.991881] [4294901176] mtlk0(_mtlk_channels_frequency_element_dump:3125): CID-0000: AntennaGain : 0
[ 234.001330] [4294901184] mtlk0(_mtlk_channels_frequency_element_dump:3126): CID-0000: ChannelLoad : 0
[ 234.010843] [4294901192] mtlk0(_mtlk_channels_frequency_element_dump:3128): CID-0000: MaxTxPwr[0] : 0
[ 234.020301] [4294901204] mtlk0(_mtlk_channels_frequency_element_dump:3129): CID-0000: MaxTxPwrIdx[0] : 0
[ 234.029795] [4294901212] mtlk0(_mtlk_channels_frequency_element_dump:3128): CID-0000: MaxTxPwr[1] : 0
[ 234.039298] [4294901220] mtlk0(_mtlk_channels_frequency_element_dump:3129): CID-0000: MaxTxPwrIdx[1] : 0
[ 234.048756] [4294901232] mtlk0(_mtlk_channels_frequency_element_dump:3128): CID-0000: MaxTxPwr[2] : 0
[ 234.058242] [4294901240] mtlk0(_mtlk_channels_frequency_element_dump:3129): CID-0000: MaxTxPwrIdx[2] : 0
[ 234.067740] [4294901248] mtlk0(_mtlk_channels_frequency_element_dump:3131): CID-0000: SwitchType : 0
[ 234.077186] [4294901260] mtlk0(_mtlk_mbss_send_preactivate_req:2829): CID-0000: Sending UMI FW Preactivation
[ 234.286730] _mtlk_mbss_send_preactivate_req 0
[ 234.290167] mtlk_set_power_limit 0
[ 234.293525] [4294901476] mtlk4(mtlk_cc_handle_mac_fatal:71): CID-0000: MAC event: From upper : MAC fatal error: [GroupID: 20, FileID: 3, Line: 926], TS 0x8a4851f
[ 234.307900] [4294901492] mtlk4(_txm_msg_timed_out:4296): CID-0000: Resetting FW because of message timeout. Message ID is 0x45F
[ 234.319274] [4294901500] mtlk3(_mtlk_txmm_send_blocked:884): send (b): wait failed (id=0x045f). Err#-4 (req=2338 cfm=2337)
[ 234.330454] [4294901512] mtlk3(_mtlk_txmm_err_print_err_sent_que:298): Unconfirmed messages:
[ 234.338941] [4294901520] mtlk3(_mtlk_txmm_err_print_que_block:293): MSG: id = 0x045f, size = 2
[ 234.347743] [4294901528] mtlk3(_mtlk_txmm_history_print_unsafe:151): MSG[0]: id=0x0444 clbR=0 bwtR=0
[ 234.356909] [4294901540] mtlk3(_mtlk_txmm_history_print_unsafe:154): ts[0] = 4294901472
[ 234.365387] [4294901548] mtlk3(_mtlk_txmm_history_print_unsafe:154): ts[1] = 4294901472
[ 234.373840] [4294901556] mtlk3(_mtlk_txmm_history_print_unsafe:154): ts[2] = 4294901472
[ 234.382295] [4294901564] mtlk3(_mtlk_txmm_history_print_unsafe:154): ts[3] = 4294901472
[ 234.390756] [4294901572] mtlk3(_mtlk_txmm_history_print_unsafe:151): MSG[1]: id=0x0444 clbR=0 bwtR=0
[ 234.399953] [4294901584] mtlk3(_mtlk_txmm_history_print_unsafe:154): ts[0] = 4294901472
[ 234.408424] [4294901592] mtlk3(_mtlk_txmm_history_print_unsafe:154): ts[1] = 4294901472
[ 234.416849] [4294901600] mtlk3(_mtlk_txmm_history_print_unsafe:154): ts[2] = 4294901472
[ 234.425307] [4294901608] mtlk3(_mtlk_txmm_history_print_unsafe:154): ts[3] = 4294901472
[ 234.433757] [4294901616] mtlk3(_mtlk_txmm_history_print_unsafe:151): MSG[2]: id=0x045F clbR=4 bwtR=-4
[ 234.443030] [4294901624] mtlk3(_mtlk_txmm_history_print_unsafe:154): ts[0] = 4294901476
[ 234.451485] [4294901632] mtlk3(_mtlk_txmm_history_print_unsafe:154): ts[1] = 4294901476
[ 234.459915] [4294901644] mtlk3(_mtlk_txmm_history_print_unsafe:154): ts[2] = 0
[ 234.467581] [4294901648] mtlk3(_mtlk_txmm_history_print_unsafe:154): ts[3] = 4294901488
[ 234.476110] [4294901660] mtlk3(mtlk_core_set_ra_protection:6582): CID-0000: Can't send UMI_RA_PROTECTION request to MAC (err=-4)
[ 234.487725] mtlk_core_set_ra_protection -4
[ 234.491908] [4294901676] mtlk3(mtlk_core_set_force_ncb:6634): CID-0000: Can't send UMI_FORCE_NCB request to MAC (err=-4)
[ 234.502736] mtlk_core_set_force_ncb -4
[ 234.506573] [4294901688] mtlk3(mtlk_core_set_n_rate_bo:6689): CID-0000: Can't send UMI_N_RATES_BO request to MAC (err=-4)
[ 234.517581] mtlk_core_set_n_rate_bo -4
[ 234.521311] [4294901704] mtlk3(_mtlk_mbss_preactivate:3091): CID-0000: _mtlk_mbss_preactivate returned with error
[ 234.531661] [4294901712] mtlk3(mtlk_mbss_init:3461): CID-0000: mtlk_mbss_init: call to _mtlk_mbss_preactivate_if_needed returned with error
[ 234.544290] [4294901728] mtlk0(mtlk_mbss_init:3477): CID-0000: before _mtlk_mbss_undo_preactivate
[ 234.553361] [4294901736] mtlk0(mtlk_mbss_init:3482): CID-0000: after _mtlk_mbss_undo_preactivate
[ 234.561955] [4294901744] mtlk3(_mtlk_core_activate:4285): CID-0000: Failed to activate the core
[ 234.570960] [4294901752] mtlk3(_mtlk_core_mac_get_stats:6383): CID-0000: MAC Get Stat sending failure (-4)
if[ 234.580723] [4294901764] mtlk3(_mtlk_process_mac_fatal_log:3921): Unable to notify LogServer
[ 234.589210] [4294901772] mtlk3(mtlk_core_set_net_state:776): CID-0000: Going to net state HALTED (net_state=4)
[ 234.599323] [4294901780] mtlk0(rcvry_initiate:1114): CID-0000: FAST recovery initiated
c[ 234.607239] [4294901788] mtlk0(rcvry_initiate:1118): CID-0000: Fast: 1 (3), Full: 0 (1)
[ 234.615398] [4294901796] mtlk3(_mtlk_hw_set_prop:4593): CID-0000: Asserting FW: hw_state=3
[ 234.623672] [4294901804] mtlk4(_mtlk_mmb_cause_mac_assert:1756): FW MAC assert is done
[ 234.631726] [4294901812] mtlk4(_mtlk_process_mac_hang:3883): CID-0000: MAC Hang detected, event = 6
[ 234.640790] [4294901824] mtlk4(mtlk_df_ui_notify_notify_fw_hang:4758): CID-0000: FW CPU#1 hang detected
[ 234.650343] [4294901832] mtlk0(master_recovery:963): CID-0000: Master Recovery Started
[ 234.658325] [4294901840] mtlk3(_rcvry_start_notify:886): CID-0000: Unable to notify application: message = 6
[ 234.668171] [4294901852] mtlk0(_rcvry_isolate:389): CID-0000: Isolation started
[ 234.675595] [4294901856] mtlk0(_rcvry_fw_dump:179): CID-0000: FW dump started
[ 234.682655] [4294901864] mtlk4(_rcvry_fw_dump:228): Cannot notify application about RECOVERY process initiation
[ 234.692804] [4294901876] mtlk0(_rcvry_restore:356): CID-0000: Restoration started
[ 234.700263] [4294901884] mtlk4(_mtlk_mmb_cleanup_reset_mac:3256): FW CPU reset is done
onfig: SIOCSIFFLAGS: Resource temporarily unavailable
root@AP254:/# [ 234.786616] [4294901968] mtlk0(get_firmware_version:1161): CID-0000: ap_upper_wave300.bin: @@@ VERSION INFO @@@ version number: FW_3.4.2_r3444 MIPS: Upper CPU(TMC AGG AP) interface: PCI phy type: real phy on Feb 12 2014 at 17:30:38@@@ END @@@
[ 234.786616]
[ 234.820292] [4294902004] mtlk0(get_firmware_version:1161): CID-0000: contr_lm.bin: @@@ VERSION INFO @@@ version number: FW_3.4.2_r3444 MIPS: Lower MAC interface: -- phy type: real phy on Feb 12 2014 at 17:29:55@@@ END @@@
[ 234.820292]
[ 234.907842] command buffer dump 82daa2ac:
[ 234.910406] 0000: 448a0000
[ 234.913194] 0001: 7b010000
[ 234.915893] 0002: 58840000
[ 234.918516] 0003: 7b010000
[ 234.921289] 0004: 007e0000
[ 234.923987] 0005: a0000000
[ 234.926601] 0006: 20680000
[ 234.929418] 0007: c8000000
[ 234.932133] 0008: 409c0000
[ 234.934698] 0009: 0e000000
[ 234.937499] 000a: e8630000
[ 234.940182] 000b: 02000000
[ 234.942792] 000c: 6c820000
[ 234.945621] 000d: 01000000
[ 234.948275] 000e: 80800000
[ 234.950887] 000f: 01000000
[ 234.953671] 0010: edfeadbe
[ 234.956392] 0011: f0000000
[ 234.958966] 0012: 0001fed4
[ 234.961792] 0013: 0000d804
[ 234.964465] 0014: 827a0010
[ 234.967076] 0015: 027a0010
[ 234.969866] 0016: 000057b8
[ 234.972562] 0017: b4f70100
[ 234.975171] 0018: 04000000
[ 234.977953] 0019: 78000200
[ 234.980656] 001a: ccfd0100
[ 234.983273] 001b: f8020200
[ 234.986052] 001c: ccf70100
[ 234.988752] 001d: 01010000
[ 234.991361] 001e: 04000000
[ 234.994178] 001f: b801f7b4
[ 234.996846] 0020: 00040000
[ 234.999455] 0021: 8194b310
[ 235.002237] 0022: 00180000
[ 235.004939] 0023: 00000003
[ 235.007554] 0024: 00000000
[ 235.010350] 0025: 00000020
[ 235.013034] 0026: 00000005
[ 235.015643] 0027: 0000000e
[ 235.018426] 0028: c1012900
[ 235.021158] 0029: 00000000
[ 235.023829] 002a: 00000000
[ 235.026439] 002b: 00000001
[ 235.029222] 002c: 00000001
[ 235.031920] 002d: 00008a44
[ 235.034535] 002e: 017b0016
[ 235.037337] 002f: 00008458
[ 235.040016] 0030: 017b0017
[ 235.042627] 0031: c8000000
[ 235.045440] 0032: b8006820
[ 235.048119] 0033: 001c0000
[ 235.050722] 0034: 83b8c010
[ 235.053504] 0035: 00280000
[ 235.056207] 0036: 00000003
[ 235.058821] 0037: 00000000
[ 235.061600] 0038: 00000000
[ 235.064316] 0039: 00000001
[ 235.066897] 003a: 7e012900
[ 235.069719] 003b: 83b8c014
[ 235.072399] 003c: 83b8df2c
[ 235.075005] 003d: 000000c8
[ 235.077788] 003e: 00000000
[ 235.080490] 003f: 00000001
[ 235.083100] 0040: 85012900
[ 235.085897] 0041: 82daa3b0
[ 235.088604] 0042: 82daa3b0
[ 235.091180] 0043: 00000000
[ 235.093974] 0044: 00000000
[ 235.096684] 0045: 00000001
[ 235.099290] 0046: 7c012900
[ 235.102075] 0047: 00000000
[ 235.104787] 0048: 00000000
[ 235.107370] 0049: 0000003f
[ 235.110172] 004a: 00000000
[ 235.112870] 004b: 000000c8
[ 235.115479] 004c: 00000000
[ 235.118261] 004d: 00c80000
[ 235.120964] 004e: a0000000
[ 235.123582] 004f: b8007e00
[ 235.128272] [MTLKD] ERR: entry fail
[ 235.130327] [MTLKD] ERR: entry fail
[ 235.134015] [MTLKD] ERR: entry fail
[ 235.137392] [MTLKD] ERR: entry fail
[ 235.143847] CPU 0 Unable to handle kernel paging request at virtual address 0c0c0c1c, epc == 804dbc70, ra == 8009ba78
[ 235.153267] Oops[#1]:
[ 235.155498] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 4.14.171 #0
[ 235.161602] task: 806527c0 task.stack: 80640000
[ 235.166094] $ 0 : 00000000 00000001 0c0c0c0c 8253deb8
[ 235.171313] $ 4 : 8253deb0 81092cec 00000001 b8ffb600
[ 235.176536] $ 8 : 00000036 00000000 00000036 b8ffb600
[ 235.181758] $12 : 00000000 00000036 1dcd6501 00000000
[ 235.186985] $16 : 81092e60 81092cec 81092ce0 00000036
[ 235.192203] $20 : 00000001 00000001 8064fcc0 b8c2e56d
[ 235.197426] $24 : 00000036 b7176e00
[ 235.202648] $28 : 80640000 8380de38 b8c2e56d 8009ba78
[ 235.207882] Hi : 0017184b
[ 235.210714] Lo : 59800000
[ 235.213777] epc : 804dbc70 timerqueue_add+0x50/0x10c
[ 235.218856] ra : 8009ba78 __hrtimer_run_queues+0x19c/0x230
[ 235.224500] Status: 11007f02 KERNEL EXL
[ 235.228424] Cause : 00800208 (ExcCode 02)
[ 235.232416] BadVA : 0c0c0c1c
[ 235.235273] PrId : 00019556 (MIPS 34Kc)
[ 235.239192] Modules linked in: mtlk
[ 235.572070]
Dears,
I reply to myself. For the rogue minds, I have uploaded the patches to the following git:
I have made the build with full hostapd. It may require the addition of kmod-mac80211 and kmod_cfg80211
Make sure you do a ./script/feeds update -a and ./script/feeds install -a prior to menuconfig
It's hard to say the status of it. It's not working but it seems this is due to the mtlk driver, not hostapd itself so in this regards it could be my particular setup:
root@OpenWrt:/# hostapd /sbin/mtlkconfig.conf
Configuration file: /sbin/mtlkconfig.conf
[ 138.251721] [4294805460] mtlk0(__mtlk_dump:69): dump of UMI_DEACTIVATE:
[ 138.256983] cp= 0x86f642e0 l=4
[ 138.260040] 0000: 00 00 00 00
mtlk driver initialization failed.
wlan0: interface state UNINITIALIZED->DISABLED
wlan0: AP-DISABLED
wlan0: CTRL-EVENT-TERMINATING
hostapd_free_hapd_data: Interface wlan0 wasn't started
ELOOP: remaining socket: sock=5 eloop_data=0x77f16e70 user_data=0 handler=0x450bc5
Take care
Smim0
242
@Mandrake-Lee
is it needed to apply the kernel's patches from @suleiman's instructions or they are not needed?
Cheers
@Smim0
I'm using them but I believe they are not necessary as far as the wave300 driver is compiled with IRQ POLLING (not msi irq or other)
The problem is linked with our platform ARV7519RW22 and the fact that wave300 is using PCIe bus, which I think is very rare.
By the way, I was reading @suleiman 's post and he also announced that he had ported hostapd (so it looks my work is redundant). It's a pity he hasn't published his work.
Regards
An update for TP-LINK W8980 V1 with 5GHz Wave300. I am able to turn on the WiFi on v18.06.8 with just a normal sysupgrade image downloaded from OpenWrt and the driver compiled with the source.
But for some reason I am not able to connect to it with my phone. As soon as my phone sees the WiFi the router crashes. My phone only works with highest channels 153, 160 etc but still the router crashes.
Smim0
245
I built openwrt from your repo but hostapd doesn't work, it doesn't recognize the mtlk driver as if it wasn't patched at all. Maybe I have done something wrong, the package to add to the openwrt image is hostapd right? not hostapd-mini ot hostapd-openssl
I had to recompile hostapd from the sources in the begining of this topic and everything is fine again, wlan0 is up with encryption.
The only issue that is still remaining is the router crash when I unload the mtlk.ro
Smim0
246
It looks like the drivers behaves differently, as you have 5ghz did you try to use cal_wlan0.bin file?