TI中文支持网
TI专业的中文技术问题搜集分享网站

PROCESSOR-SDK-AM335X: linux kernel 出现崩溃

Part Number:PROCESSOR-SDK-AM335X

请教一下,kernel在空闲状态的情况下出现下面这种错误,请问一下该怎么调试

看崩溃的信息,是在drivers/cpufreq/cpufreq_governor.c,是cpu 频率调整的相关代码

sdk 使用的是 am335x-evm-linux-sdk-src-08.02.00.24.tar.xz,linux kernel 是5.10.100

编译的相关信息

[    0.000000] Linux version 5.10.100-g7a7a3af903 (terry@ubuntu1604) (arm-linux-gnueabihf-gcc (Linaro GCC 6.3-2017.02) 6.3.1 20170109, GNU ld (Linaro_Binutils-2017.02) 2.27.0.20161019) #6 PREEMPT Mon Feb 6 14:10:25 CST 2023

root@am335x:~#[ 1732.181432] Internal error: Oops – undefined instruction: 0 [#1] PREEMPT ARM
[ 1732.188582] Modules linked in:
[ 1732.191706] CPU: 0 PID: 447 Comm: kworker/0:1 Not tainted 5.10.100-g7a7a3af903 #6
[ 1732.199240] Hardware name: Generic AM33XX (Flattened Device Tree)
[ 1732.205424] Workqueue: events dbs_work_handler
[ 1732.209933] PC is at regulator_check_voltage+0x74/0x11c
[ 1732.215210] LR is at regulator_set_voltage_unlocked+0x64/0x11c
[ 1732.221086] pc : [<c0563388>] lr : [<c0565f6c>] psr: 20010013
[ 1732.227397] sp : c1893e08 ip : 00000000 fp : c1fb5c00
[ 1732.232662] r10: c10088a0 r9 : 2aea5400 r8 : 000ec928
[ 1732.237925] r7 : 00000000 r6 : 00000000 r5 : c1fe7400 r4 : c1fb5a00
[ 1732.244500] r3 : 000e34b8 r2 : c1893e08 r1 : c1893e0c r0 : c1fe7400
[ 1732.251080] Flags: nzCv IRQs on FIQs on Mode SVC_32 ISA ARM Segment none
[ 1732.258268] Control: 10c5387d Table: 82ae8019 DAC: 00000051
[ 1732.264072] Process kworker/0:1 (pid: 447, stack limit = 0x10d7b978)
[ 1732.270473] Stack: (0xc1893e08 to 0xc1894000)
[ 1732.274881] 3e00: 00000000 000e34b8 c1003248 c1fb5a00 000e34b8 c0566290
[ 1732.283126] 3e20: 00000000 c2bf92c0 000003c6 00000002 00000000 0ed77bf8 11e1a300 c1fb5b3c
[ 1732.291370] 3e40: c1fb5a00 00000000 c10088a0 c082b8e4 c1eb8f80 11e1a300 c1003248 c1fb5a00
[ 1732.299613] 3e60: c1eba400 11e1a300 c1003248 c1fb5a00 00000000 c082d29c c1fb4200 ffffe000
[ 1732.307861] 3e80: c1003248 c1fb5b00 c1fb5c38 c1fb5b3c 11e1a300 0ed77bf8 c2bf92f0 c1fb4200
[ 1732.316107] 3ea0: 00000000 c1003248 c10f4ba4 00000000 00000000 000493e0 00000000 c0832688
[ 1732.324352] 3ec0: c100e64c c1fb4200 000afc80 000493e0 000000a1 0ed77bf8 c2bf92c0 c1fb5e00
[ 1732.332595] 3ee0: c1fb4200 0002fda0 00036b00 c1fb5e80 c1fb69c0 c1fb5e34 c100e64c c08352bc
[ 1732.340839] 3f00: c1fb5e30 00000000 c1fb5e04 c1fb4200 c10a5e94 00000000 c1fb5e34 c083639c
[ 1732.349083] 3f20: c1fb5e30 c1f7d700 00000000 ef5c6200 00000000 c0144dd0 c1892000 c1078fa0
[ 1732.357329] 3f40: c1f7d700 c1f7d714 c100e64c c1892000 c1078fa0 c100e660 00000008 c01454dc
[ 1732.365573] 3f60: 00000000 c2abdc00 c1892000 c2abd800 00000000 c0145484 c1f7d700 c1f4fec0
[ 1732.373817] 3f80: c2abdc20 c014b2f8 00000000 c2abd800 c014b1a8 00000000 00000000 00000000
[ 1732.382062] 3fa0: 00000000 00000000 00000000 c0100148 00000000 00000000 00000000 00000000
[ 1732.390304] 3fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
[ 1732.398545] 3fe0: 00000000 00000000 00000000 00000000 00000013 00000000 00000000 00000000
[ 1732.406819] [<c0563388>] (regulator_check_voltage) from [<c0566290>] (regulator_set_voltage+0x44/0x74)
[ 1732.416215] [<c0566290>] (regulator_set_voltage) from [<c082b8e4>] (_set_opp_voltage+0x30/0x94)
[ 1732.424996] [<c082b8e4>] (_set_opp_voltage) from [<c082d29c>] (dev_pm_opp_set_rate+0x3e8/0x4fc)
[ 1732.433769] [<c082d29c>] (dev_pm_opp_set_rate) from [<c0832688>] (__cpufreq_driver_target+0x250/0x570)
[ 1732.443151] [<c0832688>] (__cpufreq_driver_target) from [<c08352bc>] (od_dbs_update+0xe0/0x168)
[ 1732.451921] [<c08352bc>] (od_dbs_update) from [<c083639c>] (dbs_work_handler+0x2c/0x50)
[ 1732.460017] [<c083639c>] (dbs_work_handler) from [<c0144dd0>] (process_one_work+0x218/0x488)
[ 1732.468534] [<c0144dd0>] (process_one_work) from [<c01454dc>] (worker_thread+0x58/0x614)
[ 1732.476705] [<c01454dc>] (worker_thread) from [<c014b2f8>] (kthread+0x150/0x180)
[ 1732.484171] [<c014b2f8>] (kthread) from [<c0100148>] (ret_from_fork+0x14/0x2c)
[ 1732.491442] Exception stack(0xc1893fb0 to 0xc1893ff8)
[ 1732.496538] 3fa0: 00000000 00000000 00000000 00000000
[ 1732.504783] 3fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
[ 1732.513024] 3fe0: 00000000 00000000 00000000 00000000 00000013 00000000
[ 1732.519702] Code: d3a00000 ca000016 e28dd008 e8bd8070 (e7f001f2)
[ 1732.525854] —[ end trace b78e79c39bd37d52 ]—

xing lui:

另外,请教一下,如果想让CPU 一直工作在最高频率1GHz,有什么好办法吗?

,

Shine:

xing lui 说:看崩溃的信息,是在drivers/cpufreq/cpufreq_governor.c,是cpu 频率调整的相关代码

请问是自己的板子还是EVM板?

不调整频率没有这个问题是么?

,

xing lui:

请问是自己的板子还是EVM板?

—>是自己的板子

不调整频率没有这个问题是么?

—->不是的。是我们有需求,就是说不希望kernel主动去降频,因为我们是直接用AC,没有省电的需求,希望kernel能快速响应操作

,

Shine:

如果不需要smartreflex和DVFS的话,可以把他们disable掉,请参考下面的文档。https://software-dl.ti.com/processor-sdk-linux/esd/docs/latest/linux/Foundational_Components/Kernel/Kernel_Drivers/Power_Management.html

,

xing lui:

谢谢!!

能再针对上面的 Internal error: Oops – undefined instruction: 0 这种问题, 提供一些方法,怎么调试这种问题吗?

,

Shine:

可以看一下下面的培训视频。https://training.ti.com/intro-to-debug-embedded-linux-training-series

赞(0)
未经允许不得转载:TI中文支持网 » PROCESSOR-SDK-AM335X: linux kernel 出现崩溃
分享到: 更多 (0)