- 论坛徽章:
- 0
|
本帖最后由 cuic139 于 2012-02-07 15:21 编辑
回复 3# linuxfellow 你用的是什么版本的内核,我用的是2.6.39,sgi上只有一个给3.0的patch。。。凑合patch上了结果在多核环境下一进入断点或者是单步执行就会出现重入reenter的情况,分析了好几天源码,觉得是在kdb的处理函数里,断点和单步的情况下没有进给其他cpu发送ipi中断的处理流程,但是代码里写的好像就是不该进入。。。也不知道问谁,CU的大神们,求救 - if (smp_processor_id() == lkdb_initial_cpu &&
- !KDB_STATE(DOING_SS) &&
- !KDB_STATE(RECURSE)) {
- /*
- * (Re)install the global breakpoints and cleanup the cached
- * symbol table. This is only done once from the initial
- * processor on go.
- */
- KDB_DEBUG_STATE("kdb 12", reason);
- if (!kdb_quiet(reason) || smp_processor_id() == 0) {
- lkdb_bp_install_global(regs);
- lkdbnearsym_cleanup();
- ldebug_kusage();
- }
- if (!KDB_STATE(GO1)) {
- /*
- * Release all other cpus which will see KDB_STATE(LEAVING) is set.
- */
- int i;
- for (i = 0; i < NR_CPUS; ++i) {
- if (KDB_STATE_CPU(KDB, i))
- KDB_STATE_SET_CPU(LEAVING, i);
- KDB_STATE_CLEAR_CPU(WAIT_IPI, i);
- KDB_STATE_CLEAR_CPU(HOLD_CPU, i);
- }
- /* Wait until all the other processors leave kdb */
- while (kdb_previous_event() != 1)
- ;
- if (!kdb_quiet(reason))
- notify_die(DIE_KDEBUG_LEAVE, "KDEBUG LEAVE", regs, error, 0, 0);
- lkdb_initial_cpu = -1; /* release kdb control */
- KDB_DEBUG_STATE("kdb 13", reason);
- }
- }
复制代码 |
|