but throws a kernel-panic when wmt_launcher is running:
root@bpi-r2:~# wmt_loader
init combo device
Opened combo device
get de[ 282.101063] Internal error: Oops: 17 [#1] SMP ARM
[ 282.106861] Modules linked in:
set device id [ 282.111265] CPU: 3 PID: 12863 Comm: wmt_loader Not tainted 4.14.6-00012-g3bf8d6a #21
: 30243
[ 282.120309] Hardware name: Mediatek Cortex-A7 (Device Tree)
[ 282.126687] task: db54e000 task.stack: dc228000
[ 282.131193] PC is at __list_del_entry_valid+0x28/0xdc
[ 282.136212] LR is at wakeup_source_remove+0x34/0x88
[ 282.141055] pc : [<c03c8534>] lr : [<c04829a0>] psr: 800e0093
[ 282.147275] sp : dc229df8 ip : 00000000 fp : dc229e0c
[ 282.152461] r10: c0b01b40 r9 : ffffffff r8 : c0f3eb9c
[ 282.157647] r7 : 0be00000 r6 : 00000001 r5 : a00e0013 r4 : c0f3f1b0
[ 282.164128] r3 : c0f3f1b4 r2 : c0efc308 r1 : 00000000 r0 : c0f3f1b4
[ 282.170609] Flags: Nzcv IRQs off FIQs on Mode SVC_32 ISA ARM Segment none
[ 282.177781] Control: 10c5387d Table: 9c53006a DAC: 00000051
[ 282.183484] Process wmt_loader (pid: 12863, stack limit = 0xdc228218)
[ 282.189878] Stack: (0xdc229df8 to 0xdc22a000)
[ 282.194203] 9de0: c04c4b60 c0482994
[ 282.202328] 9e00: dc229e24 dc229e10 c04829a0 c03c8518 c0e538cc 00000000 dc229e3c dc229e28
[ 282.210453] 9e20: c04c3820 c0482978 c0f3eb9c c0e53868 dc229e64 dc229e40 c04a544c c04c3800
[ 282.218578] 9e40: ffffffff c047149c dc229ea4 c0f3eb9c c0e53868 c0e5384c dc229ea4 dc229e68
[ 282.226703] 9e60: c04c0548 c04a542c c0b01b40 c017672c dc229e94 00000000 c0177360 c0e53970
[ 282.234826] 9e80: 00007623 00007623 00007623 00007623 debeecb0 00000000 dc229ec4 dc229ea8
[ 282.242951] 9ea0: c04c7940 c04c02fc 00007623 80047704 00007623 00007623 dc229edc dc229ec8
[ 282.251076] 9ec0: c04c7794 c04c78d8 c0e5396c 80047704 dc229efc dc229ee0 c04c6c4c c04c7784
[ 282.259200] 9ee0: c04c6af8 dd9cf600 dd9cf600 80047704 dc229f7c dc229f00 c02776f8 c04c6b04
[ 282.267325] 9f00: 00000020 00000000 00000000 00000000 ddacd000 c0264c70 ddacd000 dd9c99c0
[ 282.275450] 9f20: 00000017 dedd57a0 00000000 00000002 dd9c99c8 00000000 dc229f74 dc229f48
[ 282.283575] 9f40: c0264d44 c02a9a40 00000000 00000000 00000000 dd9cf600 dd9cf600 80047704
[ 282.291700] 9f60: 00007623 00000003 dc228000 00000000 dc229fa4 dc229f80 c0277f88 c0277658
[ 282.299825] 9f80: 00000000 bea12c58 00000000 00000000 00000036 c0108d64 00000000 dc229fa8
[ 282.307950] 9fa0: c0108b80 c0277f50 bea12c58 00000000 00000003 80047704 00007623 00000000
[ 282.316075] 9fc0: bea12c58 00000000 00000000 00000036 00000000 00000000 b6ffa000 00000000
[ 282.324200] 9fe0: 00021010 bea12c1c 000105b7 b6f73766 20080030 00000003 00000000 00000000
[ 282.332338] [<c03c8534>] (__list_del_entry_valid) from [<c04829a0>] (wakeup_source_remove+0x34/0x88)
[ 282.341418] [<c04829a0>] (wakeup_source_remove) from [<c04c3820>] (wmt_plat_deinit+0x2c/0xc0)
[ 282.349892] [<c04c3820>] (wmt_plat_deinit) from [<c04a544c>] (wmt_lib_deinit+0x2c/0x178)
[ 282.357934] [<c04a544c>] (wmt_lib_deinit) from [<c04c0548>] (mtk_wcn_soc_common_drv_init+0x258/0x324)
[ 282.367096] [<c04c0548>] (mtk_wcn_soc_common_drv_init) from [<c04c7940>] (do_common_drv_init+0x74/0x1c0)
[ 282.376519] [<c04c7940>] (do_common_drv_init) from [<c04c7794>] (do_connectivity_driver_init+0x1c/0x154)
[ 282.385940] [<c04c7794>] (do_connectivity_driver_init) from [<c04c6c4c>] (wmt_detect_unlocked_ioctl+0x154/0x1b0)
[ 282.396053] [<c04c6c4c>] (wmt_detect_unlocked_ioctl) from [<c02776f8>] (do_vfs_ioctl+0xac/0x8f8)
[ 282.404785] [<c02776f8>] (do_vfs_ioctl) from [<c0277f88>] (SyS_ioctl+0x44/0x6c)
[ 282.412052] [<c0277f88>] (SyS_ioctl) from [<c0108b80>] (ret_fast_syscall+0x0/0x54)
[ 282.419575] Code: e3510c01 0a00000a e35c0c02 0a000023 (e59cc000)
[ 282.425628] ---[ end trace a2052d2229096773 ]---
[ 282.430494] [WMT-DETECT][I]wmt_detect_close:close major 154 minor 0 (pid 12863)
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.101063] Internal error: Oops: 17 [#1] SMP ARM
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.183484] Process wmt_loader (pid: 12863, stack limit = 0xdc228218)
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.189878] Stack: (0xdc229df8 to 0xdc22a000)
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.194203] 9de0: c04c4b60 c0482994
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.202328] 9e00: dc229e24 dc229e10 c04829a0 c03c8518 c0e538cc 00000000 dc229e3c dc229e28
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.210453] 9e20: c04c3820 c0482978 c0f3eb9c c0e53868 dc229e64 dc229e40 c04a544c c04c3800
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.218578] 9e40: ffffffff c047149c dc229ea4 c0f3eb9c c0e53868 c0e5384c dc229ea4 dc229e68
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.226703] 9e60: c04c0548 c04a542c c0b01b40 c017672c dc229e94 00000000 c0177360 c0e53970
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.234826] 9e80: 00007623 00007623 00007623 00007623 debeecb0 00000000 dc229ec4 dc229ea8
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.242951] 9ea0: c04c7940 c04c02fc 00007623 80047704 00007623 00007623 dc229edc dc229ec8
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.251076] 9ec0: c04c7794 c04c78d8 c0e5396c 80047704 dc229efc dc229ee0 c04c6c4c c04c7784
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.259200] 9ee0: c04c6af8 dd9cf600 dd9cf600 80047704 dc229f7c dc229f00 c02776f8 c04c6b04
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.267325] 9f00: 00000020 00000000 00000000 00000000 ddacd000 c0264c70 ddacd000 dd9c99c0
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.275450] 9f20: 00000017 dedd57a0 00000000 00000002 dd9c99c8 00000000 dc229f74 dc229f48
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.283575] 9f40: c0264d44 c02a9a40 00000000 00000000 00000000 dd9cf600 dd9cf600 80047704
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.291700] 9f60: 00007623 00000003 dc228000 00000000 dc229fa4 dc229f80 c0277f88 c0277658
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.299825] 9f80: 00000000 bea12c58 00000000 00000000 00000036 c0108d64 00000000 dc229fa8
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.307950] 9fa0: c0108b80 c0277f50 bea12c58 00000000 00000003 80047704 00007623 00000000
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.316075] 9fc0: bea12c58 00000000 00000000 00000036 00000000 00000000 b6ffa000 00000000
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.324200] 9fe0: 00021010 bea12c1c 000105b7 b6f73766 20080030 00000003 00000000 00000000
Message from syslogd@bpi-r2 at Dec 14 15:22:50 ...
kernel:[ 282.419575] Code: e3510c01 0a00000a e35c0c02 0a000023 (e59cc000)
Segmentation fault
any idea? @garywang have the wifi-helper-tools/firmware changed?
wmt_plat_deinit is the first function from top i’ve found in source…
drivers/misc/mediatek/connectivity/common/combo/platform/alps/wmt_plat_alps.c
INT32 wmt_plat_deinit(VOID)
{
INT32 iret;
/* 1. de-init cmb_hw */
iret = mtk_wcn_cmb_hw_deinit();
/* 2. unreg to cmb_stub */
iret += mtk_wcn_cmb_stub_unreg();
/*3. wmt wakelock deinit */
#ifdef CFG_WMT_WAKELOCK_SUPPORT
wake_lock_destroy(&wmtWakeLock);
osal_sleepable_lock_deinit(&gOsSLock);
WMT_DBG_FUNC("destroy wmtWakeLock\n");
#endif
WMT_DBG_FUNC("WMT-PLAT: ALPS platform init (%d)\n", iret);
return 0;
}
Last init-function (drivers/misc/mediatek/connectivity/common/conn_soc/linux/pri/wmt_dev.c):
int mtk_wcn_soc_common_drv_init(void)
{
return WMT_init(); //this call is not in stacktrace
}
static int WMT_init(void)
{
dev_t devID = MKDEV(gWmtMajor, 0);
INT32 cdevErr = -1;
INT32 ret = -1;
WMT_INFO_FUNC("WMT Version= %s DATE=%s\n", MTK_WMT_VERSION, MTK_WMT_DATE);
/* Prepare a UINT8 device */
/*static allocate chrdev */
gWmtInitDone = 0;
init_waitqueue_head((wait_queue_head_t *) &gWmtInitWq);
stp_drv_init();
ret = register_chrdev_region(devID, WMT_DEV_NUM, WMT_DRIVER_NAME);
if (ret) {
WMT_ERR_FUNC("fail to register chrdev\n");
return ret;
}
cdev_init(&gWmtCdev, &gWmtFops);
gWmtCdev.owner = THIS_MODULE;
cdevErr = cdev_add(&gWmtCdev, devID, WMT_DEV_NUM);
if (cdevErr) {
WMT_ERR_FUNC("cdev_add() fails (%d)\n", cdevErr);
goto error;
}
WMT_INFO_FUNC("driver(major %d) installed\n", gWmtMajor);
#if WMT_CREATE_NODE_DYNAMIC
wmt_class = class_create(THIS_MODULE, "stpwmt");
if (IS_ERR(wmt_class))
goto error;
wmt_dev = device_create(wmt_class, NULL, devID, NULL, "stpwmt");
if (IS_ERR(wmt_dev))
goto error;
#endif
#if 0
pWmtDevCtx = wmt_drv_create();
if (!pWmtDevCtx) {
WMT_ERR_FUNC("wmt_drv_create() fails\n");
goto error;
}
ret = wmt_drv_init(pWmtDevCtx);
if (ret) {
WMT_ERR_FUNC("wmt_drv_init() fails (%d)\n", ret);
goto error;
}
WMT_INFO_FUNC("stp_btmcb_reg\n");
wmt_cdev_btmcb_reg();
ret = wmt_drv_start(pWmtDevCtx);
if (ret) {
WMT_ERR_FUNC("wmt_drv_start() fails (%d)\n", ret);
goto error;
}
#endif
ret = wmt_lib_init();
if (ret) {
WMT_ERR_FUNC("wmt_lib_init() fails (%d)\n", ret);
goto error;
}
#if CFG_WMT_DBG_SUPPORT
wmt_dev_dbg_setup();
#endif
#if CFG_WMT_PROC_FOR_AEE
wmt_dev_proc_for_aee_setup();
#endif
WMT_INFO_FUNC("wmt_dev register thermal cb\n");
wmt_lib_register_thermal_ctrl_cb(wmt_dev_tm_temp_query);
wmt_dev_bgw_desense_init();
gWmtInitDone = 1;
wake_up(&gWmtInitWq);
osal_sleepable_lock_init(&g_es_lr_lock);
INIT_WORK(&gPwrOnOffWork, wmt_pwr_on_off_handler);
#ifdef CONFIG_EARLYSUSPEND
register_early_suspend(&wmt_early_suspend_handler);
WMT_INFO_FUNC("register_early_suspend finished\n");
#else
wmt_fb_notifier.notifier_call = wmt_fb_notifier_callback;
ret = fb_register_client(&wmt_fb_notifier);
if (ret)
WMT_ERR_FUNC("wmt register fb_notifier failed! ret(%d)\n", ret);
else
WMT_INFO_FUNC("wmt register fb_notifier OK!\n");
#endif
WMT_INFO_FUNC("success\n");
return 0;
error:
wmt_lib_deinit();
#if CFG_WMT_DBG_SUPPORT
wmt_dev_dbg_remove();
#endif
#if WMT_CREATE_NODE_DYNAMIC
if (!(IS_ERR(wmt_dev)))
device_destroy(wmt_class, devID);
if (!(IS_ERR(wmt_class))) {
class_destroy(wmt_class);
wmt_class = NULL;
}
#endif
if (cdevErr == 0)
cdev_del(&gWmtCdev);
if (ret == 0) {
unregister_chrdev_region(devID, WMT_DEV_NUM);
gWmtMajor = -1;
}
WMT_ERR_FUNC("fail\n");
return -1;
}
Is there any debug-mode to see on which step it failes? There are messages with WMT_INFO_FUNC and WMT_ERR_FUNC…how to display them?
try to add some printk’s like it’s recommended here: https://elinux.org/Debugging_by_printing (Author’s practical advice) oh, is see the messages only in dmesg
[ 37.004665] [WMT-DETECT][I]wmt_detect_open:open major 154 minor 0 (pid 1339)
[ 37.004699] [WMT-DETECT][I]wmt_detect_unlocked_ioctl:cmd (-2147191037),arg(0)
[ 37.004763] [WMT-DETECT][I]wmt_detect_unlocked_ioctl:cmd (1074034433),arg(302
43)
[ 37.004768] set current consys chipid (0x7623)
[ 37.004783] [WMT-DETECT][I]wmt_detect_unlocked_ioctl:cmd (-2147191036),arg(30
243)
[ 37.004789] [WMT-MOD-INIT][I]do_common_drv_init:start to do common driver ini
t, chipid:0x00007623
[ 37.004796] DEBUG: Passed WMT_init 2396
[ 37.005267] DEBUG: Passed WMT_init 2404
[ 37.005274] DEBUG: Passed WMT_init 2407
[ 37.005282] DEBUG: Passed WMT_init 2414
[ 37.005358] DEBUG: Passed WMT_init 2419
[ 37.006734] DEBUG: Passed WMT_init 2423
[ 37.008914] [WMT-DEV][E]wmt_dev_read_file(1458):error code:-2
[ 37.008930] [WMT-DEV][E]wmt_dev_patch_get(1575):load file (/system/etc/firmwa
re/WMT_SOC.cfg) fail, iRet(-2) <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
[ 37.008937] [WMT-CONF][E]wmt_conf_read_file(516):read /system/etc/firmware/WM
T_SOC.cfg file fails
[ 37.008943] drivers/misc/mediatek/connectivity/common/conn_soc/core/wmt_conf.
c, 517, (0)
[ 37.008949] [WMT-LIB][E]wmt_lib_init(179):read wmt config file fail(-1)
[ 37.008953] DEBUG: Passed WMT_init 2452
[ 37.008958] [WMT-DEV][E]WMT_init(2454):wmt_lib_init() fails (-1)
[ 37.008966] [WMT-LIB][E]wmt_lib_deinit(306):osal_thread_stop(0xc0efca60) fail
(-1)
[ 37.008970] [cmb_stub] unregistered
[ 37.008989] Unable to handle kernel NULL pointer dereference at virtual addre
ss 00000000
then comes the oops listed above…and also the WMT-mesages are here…
wmt_dev.c (68,8 KB) wmt_plat_alps.c (44,9 KB)
seems that the problem is that my cfg could not be loaded…have lowercase filename instead of uppercase (for whatever reason) after renaming, kernel hangs…seems that kernel has crashed more than i thought…the renaming was not present after a reset…so i renamed again and started wmt_loader:
root@bpi-r2:~# wmt_loader
init combo device
Opened combo device
get device id : 30243
set device id : 30243
do module init: 30243
failed to init module <<<< can be ignored, same as 4.4.70
second step:
root@bpi-r2:~# stp_uart_launcher -p /etc/firmware &
[1] 1482
open device node[ 263.950509] Internal error: Oops: 17 [#1] SMP ARM
succeed.(Node:/[ 263.956093] Modules linked in:
dev/stpwmt, fd:3[ 263.960498] CPU: 3 PID: 1118 Comm: mtk_wmtd Not tainted 4.14.
6-00012-g3bf8d6a-dirty #25
)
chip id is 0[ 263.969808] Hardware name: Mediatek Cortex-A7 (Device Tree)
x7623
chiId:0x7[ 263.976704] task: debdd400 task.stack: dc87e000
623, setting to [ 263.982574] PC is at mutex_lock+0x28/0x54
property((null))[ 263.987917] LR is at regulator_set_mode+0x2c/0xb4
chiId:0x7623
[ 263.993950] pc : [<c08d100c>] lr : [<c0428ba0>] psr: 60080013
run SOC chip flo[ 264.001538] sp : dc87fd80 ip : dc87fd90 fp : dc87fd8c
w
create pwr on[ 264.008088] r10: 00000000 r9 : 00000000 r8 : 00000000
thread ok
root[ 264.014641] r7 : 00000001 r6 : c0efd204 r5 : 00000040 r4 : 00000000
@bpi-r2:~# [ 264.022488] r3 : debdd400 r2 : dc87fd80 r1 : 00000008 r0 : 0000
0040
[ 264.029901] Flags: nZCv IRQs on FIQs on Mode SVC_32 ISA ARM Segment none
[ 264.036985] Control: 10c5387d Table: 9df2806a DAC: 00000051
[ 264.042688] Process mtk_wmtd (pid: 1118, stack limit = 0xdc87e218)
[ 264.048823] Stack: (0xdc87fd80 to 0xdc880000)
... (removed memory-dump)
[ 264.215660] [<c08d100c>] (mutex_lock) from [<c0428ba0>] (regulator_set_mode+0
x2c/0xb4)
[ 264.223534] [<c0428ba0>] (regulator_set_mode) from [<c04c21e4>] (mtk_wcn_cons
ys_hw_reg_ctrl+0x84/0x69c)
[ 264.232870] [<c04c21e4>] (mtk_wcn_consys_hw_reg_ctrl) from [<c04c29b0>] (mtk_
wcn_consys_hw_pwr_on+0x50/0xc4)
[ 264.242636] [<c04c29b0>] (mtk_wcn_consys_hw_pwr_on) from [<c04c478c>] (wmt_pl
at_pwr_ctrl+0xa4/0x124)
[ 264.251713] [<c04c478c>] (wmt_plat_pwr_ctrl) from [<c04a1c88>] (wmt_ctrl_hw_p
wr_on+0x68/0x88)
[ 264.260186] [<c04a1c88>] (wmt_ctrl_hw_pwr_on) from [<c04a1d78>] (wmt_ctrl+0x4
4/0xc0)
[ 264.267882] [<c04a1d78>] (wmt_ctrl) from [<c049e2cc>] (wmt_core_ctrl+0x4c/0xc
c)
[ 264.275146] [<c049e2cc>] (wmt_core_ctrl) from [<c04a028c>] (opfunc_pwr_on+0x5
c/0x204)
[ 264.282928] [<c04a028c>] (opfunc_pwr_on) from [<c04a0490>] (opfunc_func_on+0x
5c/0x358)
[ 264.290795] [<c04a0490>] (opfunc_func_on) from [<c049e1f4>] (wmt_core_opid_ha
ndler+0x34/0x54)
[ 264.299266] [<c049e1f4>] (wmt_core_opid_handler) from [<c049e240>] (wmt_core_
opid+0x2c/0x6c)
[ 264.307651] [<c049e240>] (wmt_core_opid) from [<c04a7508>] (wmtd_thread+0x18c
/0x244)
[ 264.315348] [<c04a7508>] (wmtd_thread) from [<c0146118>] (kthread+0x13c/0x16c
)
[ 264.322530] [<c0146118>] (kthread) from [<c0108c68>] (ret_from_fork+0x14/0x2c
)
dmesg
[ 26.210065] [WMT-MOD-INIT][I]do_common_drv_init:finish common driver init
[ 26.210070] [BT-MOD-INIT][I]do_bluetooth_drv_init:CONFIG_MTK_COMBO_BT is not
defined
[ 26.210075] [WCN-MOD-INIT][E]do_connectivity_driver_init(57):do common driver
init failed, ret:-1
[ 26.210079] [GPS-MOD-INIT][I]do_gps_drv_init:CONFIG_MTK_COMBO_GPS is not defi
ned
[ 26.210083] [WCN-MOD-INIT][E]do_connectivity_driver_init(62):do common driver
init failed, ret:-1
[ 26.210086] [FM-MOD-INIT][I]do_fm_drv_init:start to do fm module init
[ 26.210089] [FM-MOD-INIT][I]do_fm_drv_init:finish fm module init
[ 26.210093] [WLAN-MOD-INIT][I]do_wlan_drv_init:start to do wlan module init 0
x7623
[ 26.213412] [MTK-WIFI] WIFI_init: mtk_wmt_WIFI_chrdev driver(major 153) insta
lled.
[ 26.213423] [WLAN-MOD-INIT][I]do_wlan_drv_init:WMT-WIFI char dev init, ret:0
[ 26.214325] [WLAN-MOD-INIT][I]do_wlan_drv_init:WLAN-GEN2 driver init, ret:0
[ 26.214333] [WLAN-MOD-INIT][I]do_wlan_drv_init:finish wlan module init
[ 26.214731] [WMT-DETECT][I]wmt_detect_close:close major 154 minor 0 (pid 1114
)
[ 263.950064] [WMT-DEV][W]WMT_unlocked_ioctl:chipid = 0x7623
[ 263.950151] [WMT-LIB][W]wmt_lib_set_hif:new hifType: 2, fm:2
[ 263.950203] [WMT-CORE][E]opfunc_hif_conf(874):WMT-CORE: WMT HIF info added
[ 263.950236] [WMT-DEV][W]WMT_unlocked_ioctl:unknown cmd (-2147180516)
[ 263.950486] Unable to handle kernel NULL pointer dereference at virtual addre
ss 00000040
[ 263.950491] pgd = c0004000
[ 263.950496] [00000040] *pgd=00000000
[ 263.950509] Internal error: Oops: 17 [#1] SMP ARM
[ 263.956093] Modules linked in:
[ 263.960498] CPU: 3 PID: 1118 Comm: mtk_wmtd Not tainted 4.14.6-00012-g3bf8d6a
-dirty #25
[ 263.969808] Hardware name: Mediatek Cortex-A7 (Device Tree)
[ 263.976704] task: debdd400 task.stack: dc87e000
[ 263.982574] PC is at mutex_lock+0x28/0x54
[ 263.987917] LR is at regulator_set_mode+0x2c/0xb4
root@bpi-r2:~# stp_uart_launcher -p /etc/firmware &
[1] 1308
root@bpi-r2:~# open device node succeed.(Node:/
[ 33.157686] Internal error: Oops: 17 [#1] SMP ARM << here the kernel oops, after that my r2 is not responsible
dev/stpwmt, fd:3
chip id is 0
have opened a ssh-session in second terminal looking live at dmesg:
root@bpi-r2:~# dmesg -wH
[Dec15 14:07] [WMT-DETECT][I]wmt_detect_open:open major 154 minor 0 (pid 1415)
[ +0.000034] [WMT-DETECT][I]wmt_detect_unlocked_ioctl:cmd (-2147191037),arg(0)
[ +0.000062] [WMT-DETECT][I]wmt_detect_unlocked_ioctl:cmd (1074034433),arg(30243)
[ +0.000005] set current consys chipid (0x7623)
[ +0.000014] [WMT-DETECT][I]wmt_detect_unlocked_ioctl:cmd (-2147191036),arg(30243)
[ +0.000006] [WMT-MOD-INIT][I]do_common_drv_init:start to do common driver init, chipid:0x00007623
[ +0.000007] DEBUG: Passed WMT_init 2396
[ +0.000483] DEBUG: Passed WMT_init 2404
[ +0.000007] DEBUG: Passed WMT_init 2407
[ +0.000007] DEBUG: Passed WMT_init 2414
[ +0.000076] DEBUG: Passed WMT_init 2419
[ +0.001493] DEBUG: Passed WMT_init 2423
[ +0.001085] [WMT-CONF][E]wmt_conf_parse_pair(323):unknown field 'mt6620.defAnt'.
[ +0.000012] [WMT-CONF][W]wmt_conf_parse:parse fail (mt6620.defAnt, mt6620_ant_m3.cfg, -1)
[ +0.000007] [WMT-CONF][E]wmt_conf_parse_pair(323):unknown field 'mt6628.defAnt'.
[ +0.000007] [WMT-CONF][W]wmt_conf_parse:parse fail (mt6628.defAnt, mt6628_ant_m1.cfg, -1)
[ +0.000007] [WMT-CONF][E]wmt_conf_parse_pair(323):unknown field 'mt6630.defAnt'.
[ +0.000007] [WMT-CONF][W]wmt_conf_parse:parse fail (mt6630.defAnt, mt6630_ant_m1.cfg, -1)
[ +0.002628] [WMT-CONSYS-HW][E]mtk_wmt_probe(122):Wmt Cannot find pinctrl default!
[ +0.000304] OF: /consys@18070000: could not get #reset-cells for /watchdog@10007000
[ +0.000008] [WMT-CONSYS-HW][E]mtk_wmt_probe(170):CanNot get consys reset. ret=-22
[ +0.000410] mt7623consys: probe of 18070000.consys failed with error -22
[ +0.000659] DEBUG: Passed WMT_init 2452
[ +0.000006] DEBUG: Passed WMT_init 2457
[ +0.000016] DEBUG: Passed WMT_init 2460
[ +0.000011] DEBUG: Passed WMT_init 2465
[ +0.000005] DEBUG: Passed WMT_init 2470
[ +0.000025] DEBUG: Passed WMT_init 2472
[ +0.000004] DEBUG: Passed WMT_init 2475
[ +0.000004] DEBUG: Passed WMT_init 2477
[ +0.000003] DEBUG: Passed WMT_init 2486
[ +0.000007] [WMT-MOD-INIT][I]do_common_drv_init:finish common driver init
[ +0.000004] [BT-MOD-INIT][I]do_bluetooth_drv_init:CONFIG_MTK_COMBO_BT is not defined
[ +0.000006] [WCN-MOD-INIT][E]do_connectivity_driver_init(57):do common driver init failed, ret:-1
[ +0.000003] [GPS-MOD-INIT][I]do_gps_drv_init:CONFIG_MTK_COMBO_GPS is not defined
[ +0.000005] [WCN-MOD-INIT][E]do_connectivity_driver_init(62):do common driver init failed, ret:-1
[ +0.000003] [FM-MOD-INIT][I]do_fm_drv_init:start to do fm module init
[ +0.000003] [FM-MOD-INIT][I]do_fm_drv_init:finish fm module init
[ +0.000008] [WLAN-MOD-INIT][I]do_wlan_drv_init:start to do wlan module init 0x7623
[ +0.003067] [MTK-WIFI] WIFI_init: mtk_wmt_WIFI_chrdev driver(major 153) installed.
[ +0.000010] [WLAN-MOD-INIT][I]do_wlan_drv_init:WMT-WIFI char dev init, ret:0
[ +0.000870] [WLAN-MOD-INIT][I]do_wlan_drv_init:WLAN-GEN2 driver init, ret:0
[ +0.000010] [WLAN-MOD-INIT][I]do_wlan_drv_init:finish wlan module init
[ +0.000460] [WMT-DETECT][I]wmt_detect_close:close major 154 minor 0 (pid 1415)
Message from syslogd@bpi-r2 at Dec 15 14:08:14 ...
kernel:[ 131.083366] Internal error: Oops: 17 [#1] SMP ARM <<<<oops happens here
[Dec15 14:08] [WMT-DEV][W]WMT_unlocked_ioctl:chipid = 0x7623
[ +0.000123] [WMT-LIB][W]wmt_lib_set_hif:new hifType: 2, fm:2
[ +0.000039] [WMT-DEV][W]WMT_unlocked_ioctl:unknown cmd (-2147180516)
[ +0.000036] [WMT-CORE][E]opfunc_hif_conf(874):WMT-CORE: WMT HIF info added
[ +0.000187] DEBUG: Passed mtk_wcn_consys_hw_reg_ctrl 232 <<< beginning of mtk_wcn_consys_hw_reg_ctrl
[ +0.000016] vcn18: mode operation not allowed
[ +0.000004] DEBUG: Passed mtk_wcn_consys_hw_reg_ctrl 236
[ +0.000003] DEBUG: Passed mtk_wcn_consys_hw_reg_ctrl 239
[ +0.000007] DEBUG: Passed mtk_wcn_consys_hw_reg_ctrl 241
[ +0.000509] DEBUG: Passed mtk_wcn_consys_hw_reg_ctrl 248
[ +0.000316] DEBUG: Passed mtk_wcn_consys_hw_reg_ctrl 275
[ +0.000004] ------------[ cut here ]------------
[ +0.000017] WARNING: CPU: 0 PID: 1420 at drivers/reset/core.c:230 reset_control_reset+0x130/0x150
[ +0.000004] Modules linked in:
[ +0.000012] CPU: 0 PID: 1420 Comm: mtk_wmtd Not tainted 4.14.6-00012-g3bf8d6a-dirty #27
[ +0.000004] Hardware name: Mediatek Cortex-A7 (Device Tree)
[ +0.000023] [<c0113208>] (unwind_backtrace) from [<c010d6b0>] (show_stack+0x20/0x24)
[ +0.000014] [<c010d6b0>] (show_stack) from [<c08b91e0>] (dump_stack+0x9c/0xb0)
[ +0.000015] [<c08b91e0>] (dump_stack) from [<c0125478>] (__warn+0xf8/0x110)
[ +0.000012] [<c0125478>] (__warn) from [<c0125560>] (warn_slowpath_null+0x30/0x38)
[ +0.000011] [<c0125560>] (warn_slowpath_null) from [<c042e6a4>] (reset_control_reset+0x130/0x150)
[ +0.000013] [<c042e6a4>] (reset_control_reset) from [<c04c2374>] (mtk_wcn_consys_hw_reg_ctrl+0x214/0x6a0)
[ +0.000011] [<c04c2374>] (mtk_wcn_consys_hw_reg_ctrl) from [<c04c29b4>] (mtk_wcn_consys_hw_pwr_on+0x50/0xc4)
[ +0.000010] [<c04c29b4>] (mtk_wcn_consys_hw_pwr_on) from [<c04c4790>] (wmt_plat_pwr_ctrl+0xa4/0x124)
[ +0.000012] [<c04c4790>] (wmt_plat_pwr_ctrl) from [<c04a1c88>] (wmt_ctrl_hw_pwr_on+0x68/0x88)
[ +0.000010] [<c04a1c88>] (wmt_ctrl_hw_pwr_on) from [<c04a1d78>] (wmt_ctrl+0x44/0xc0)
[ +0.000009] [<c04a1d78>] (wmt_ctrl) from [<c049e2cc>] (wmt_core_ctrl+0x4c/0xcc)
[ +0.000009] [<c049e2cc>] (wmt_core_ctrl) from [<c04a028c>] (opfunc_pwr_on+0x5c/0x204)
[ +0.000009] [<c04a028c>] (opfunc_pwr_on) from [<c04a0490>] (opfunc_func_on+0x5c/0x358)
[ +0.000009] [<c04a0490>] (opfunc_func_on) from [<c049e1f4>] (wmt_core_opid_handler+0x34/0x54)
[ +0.000009] [<c049e1f4>] (wmt_core_opid_handler) from [<c049e240>] (wmt_core_opid+0x2c/0x6c)
[ +0.000010] [<c049e240>] (wmt_core_opid) from [<c04a7508>] (wmtd_thread+0x18c/0x244)
[ +0.000012] [<c04a7508>] (wmtd_thread) from [<c0146118>] (kthread+0x13c/0x16c)
[ +0.000012] [<c0146118>] (kthread) from [<c0108c68>] (ret_from_fork+0x14/0x2c)
[ +0.000020] ---[ end trace ddb7121164b33204 ]---
[ +0.000004] DEBUG: Passed mtk_wcn_consys_hw_reg_ctrl 277
[ +0.000071] DEBUG: Passed mtk_wcn_consys_hw_reg_ctrl 279
[ +0.000025] Unable to handle kernel NULL pointer dereference at virtual address 00000010
[ +0.000004] pgd = c0004000
[ +0.000004] [00000010] *pgd=00000000
[ +0.000012] Internal error: Oops: 17 [#1] SMP ARM
[ +0.005920] Modules linked in:
[ +0.003039] CPU: 0 PID: 1420 Comm: mtk_wmtd Tainted: G W 4.14.6-00012-g3bf8d6a-dirty #27
[ +0.009165] Hardware name: Mediatek Cortex-A7 (Device Tree)
[ +0.005536] task: db0f3c00 task.stack: dc688000
[ +0.004503] PC is at clk_core_enable+0x6c/0x234
[ +0.004498] LR is at clk_core_enable+0x4c/0x234
... removed memory dump
[ +0.008137] [<c0419228>] (clk_core_enable) from [<c0419564>] (clk_core_enable_lock+0x28/0x3c)
[ +0.008473] [<c0419564>] (clk_core_enable_lock) from [<c041959c>] (clk_enable+0x24/0x28)
[ +0.008041] [<c041959c>] (clk_enable) from [<c04c256c>] (mtk_wcn_consys_hw_reg_ctrl+0x40c/0x6a0)
[ +0.008731] [<c04c256c>] (mtk_wcn_consys_hw_reg_ctrl) from [<c04c29b4>] (mtk_wcn_consys_hw_pwr_on+0x50/0xc4)
[ +0.009765] [<c04c29b4>] (mtk_wcn_consys_hw_pwr_on) from [<c04c4790>] (wmt_plat_pwr_ctrl+0xa4/0x124)
[ +0.009075] [<c04c4790>] (wmt_plat_pwr_ctrl) from [<c04a1c88>] (wmt_ctrl_hw_pwr_on+0x68/0x88)
[ +0.008472] [<c04a1c88>] (wmt_ctrl_hw_pwr_on) from [<c04a1d78>] (wmt_ctrl+0x44/0xc0)
[ +0.007695] [<c04a1d78>] (wmt_ctrl) from [<c049e2cc>] (wmt_core_ctrl+0x4c/0xcc)
[ +0.007263] [<c049e2cc>] (wmt_core_ctrl) from [<c04a028c>] (opfunc_pwr_on+0x5c/0x204)
[ +0.007781] [<c04a028c>] (opfunc_pwr_on) from [<c04a0490>] (opfunc_func_on+0x5c/0x358)
[ +0.007866] [<c04a0490>] (opfunc_func_on) from [<c049e1f4>] (wmt_core_opid_handler+0x34/0x54)
[ +0.008469] [<c049e1f4>] (wmt_core_opid_handler) from [<c049e240>] (wmt_core_opid+0x2c/0x6c)
[ +0.008385] [<c049e240>] (wmt_core_opid) from [<c04a7508>] (wmtd_thread+0x18c/0x244)
[ +0.007697] [<c04a7508>] (wmtd_thread) from [<c0146118>] (kthread+0x13c/0x16c)
[ +0.007180] [<c0146118>] (kthread) from [<c0108c68>] (ret_from_fork+0x14/0x2c)
[ +0.007177] Code: e595307c e3530000 ca00003b e5943004 (e5933010)
[ +0.006053] ---[ end trace ddb7121164b33205 ]---
seems that i must rework my dts(i)