Kexec -p 命令无法工作

使用下面的命令测试kexec功能时,出现内核不能引导第二个内核

#kexec -p ./Image --append=“root=/dev/mmcblk2p6 maxcpus=1”

#echo c > /proc/sysrq-trigger

执行之后串口提示信息如下:

[root@linx ~]#echo c > /proc/sysrq-trigger
[ 545.531798] sysrq: Trigger a crash
[ 545.531841] Kernel panic - not syncing: sysrq triggered crash
[ 545.531841]
[ 545.542460] CPU: 5 PID: 2208 Comm: bash Kdump: loaded Tainted: G O 4.19.172 #13
[ 545.551073] Hardware name: Rockchip RK3399 Excavator Board (Linux Opensource) (DT)
[ 545.558637] Call trace:
[ 545.561110] dump_backtrace+0x0/0x188
[ 545.564786] show_stack+0x24/0x30
[ 545.568117] dump_stack+0x8c/0xb4
[ 545.571442] panic+0x160/0x2f0
[ 545.574507] sysrq_handle_reboot+0x0/0x20
[ 545.578526] __handle_sysrq+0x98/0x148
[ 545.582283] write_sysrq_trigger+0xa8/0xb0
[ 545.586395] proc_reg_write+0x7c/0xbc
[ 545.590069] __vfs_write+0x60/0x178
[ 545.593567] vfs_write+0xd0/0x18c
[ 545.596892] ksys_write+0x74/0xe4
[ 545.600216] __arm64_sys_write+0x24/0x30
[ 545.604153] el0_svc_common.constprop.0+0xe8/0x168
[ 545.608947] el0_svc_handler+0x70/0x8c
[ 545.612705] el0_svc+0x8/0xc
[ 545.615613] SMP: stopping secondary CPUs

我根据提示信息,查看相关资料和分析代码流程,发现crash时,对应的发生crash的cpu会向其他在线cpu发送crash中断(ipi 3号中断),停止其他cpu,然后引导kexec中的painc内核。但是rk3399平台没有一直停在这里(SMP: stopping secondary CPUs)。

drivers/irqchip/irq-gic-v3.c
static void gic_send_sgi(u64 cluster_id, u16 tlist, unsigned int irq)
{
u64 val;
val = (MPIDR_TO_SGI_AFFINITY(cluster_id, 3) |
MPIDR_TO_SGI_AFFINITY(cluster_id, 2) |
irq << ICC_SGI1R_SGI_ID_SHIFT |
MPIDR_TO_SGI_AFFINITY(cluster_id, 1) |
MPIDR_TO_SGI_RS(cluster_id) |
tlist << ICC_SGI1R_TARGET_LIST_SHIFT);

 pr_debug("CPU%d: ICC_SGI1R_EL1 %llx\n", smp_processor_id(), val);
                                                    
 gic_write_sgi1r(val);

}

现在我不知到该如何进行下一步调试,能不能请给我一些建议谢谢。