Hi, Thanks to the positive feedback during last summit, I''m submitting debuggers patch, kdb+gdbsx. - gdbsx: debug guests, PV or HVM, 32 or 64. - kdb: debug mostly hypervisor, but limited guest debugging also. Both are fairly stable, and gdbsx is being used by couple groups here for linux kernel/module development and feedback is good. The attached patch is only changes to the hyp code. Additionally, there is - a new file, arch/x86/debug.c shared by both kdb and gdbsx - gdbsx code in tools/debugger/gdbsx - kdb code in xen/kdb Please see http://xenbits.xensource.com/ext/debuggers.hg for these new files. This is not official patch, but I can submit one with any changes. Thanks, Mukesh PS: at present, i''ve implemented following commands in kdb: {"f", kdb_cmdf_f, 1, "[vcpu ptr]", "Display stack frames", KDB_REPEAT_NONE}, {"fg", kdb_cmdf_fg, 1, "domid ipaddr(eip) spaddr(esp)", "Display stack given ip and sp for guest", KDB_REPEAT_NONE}, {"dw", kdb_cmdf_dw, 1, "<vaddr|sym>[num(dec)][domid]","Display word", KDB_REPEAT_NO_ARGS}, {"dd", kdb_cmdf_dd, 1, "<vaddr|sym>[num(dec)][domid]","Display dword", KDB_REPEAT_NO_ARGS}, {"dwm",kdb_cmdf_dwm, 1, "<maddr|sym>[num(dec)]","Display machine word", KDB_REPEAT_NO_ARGS}, {"ddm",kdb_cmdf_ddm, 1, "<maddr|sym>[num(dec)]","Display machine dword", KDB_REPEAT_NO_ARGS}, {"dr", kdb_cmdf_dr, 1, "[sp]", "Display [special]Registers", KDB_REPEAT_NONE}, {"drg", kdb_cmdf_drg, 1, "", "Display guest/stack registers", KDB_REPEAT_NONE}, {"dis",kdb_cmdf_dis, 1, "[addr|sym][num][0xdomid]", "Disassemble", KDB_REPEAT_NO_ARGS}, {"dism",kdb_cmdf_dism, 1, "", "toggle Intel/ATT modes", KDB_REPEAT_NO_ARGS}, {"mw", kdb_cmdf_mw, 1, "<vaddr|sym><val>[domid]", "Modify Mem Word", KDB_REPEAT_NONE}, {"md", kdb_cmdf_md, 1, "<vaddr|sym><val>[domid]", "Modify Mem DWord", KDB_REPEAT_NONE}, {"mr", kdb_cmdf_mr, 1, "<reg><val>", "Modify Register", KDB_REPEAT_NONE}, {"bc", kdb_cmdf_bc, 0, "<num|all>", "brkpt delete", KDB_REPEAT_NONE}, {"bp", kdb_cmdf_bp, 1, "[addr|sym][0xdomid]", "brkpt list/set(on all cpus)", KDB_REPEAT_NONE}, {"ni", kdb_cmdf_ni, 0, "", "next instr after call", KDB_REPEAT_NO_ARGS}, {"ss", kdb_cmdf_ss, 0, "", "Single Step", KDB_REPEAT_NO_ARGS}, {"ssb",kdb_cmdf_ssb,0, "", "Single Step to branch", KDB_REPEAT_NO_ARGS}, {"go", kdb_cmdf_go, 0, "", "Continue Execution", KDB_REPEAT_NONE}, {"cpu",kdb_cmdf_cpu, 1, "[all|num]", "Switch CPU", KDB_REPEAT_NONE}, {"nmi",kdb_cmdf_nmi, 1, "<cpu|all>", "send nmi to cpu/s", KDB_REPEAT_NONE}, {"sym", kdb_cmdf_sym, 1, "sym ? for usage", "Load guest symbols", KDB_REPEAT_NONE}, {"vcpuh",kdb_cmdf_vcpuh, 1, "<ptr>", "Display hvm_vcpu{}", KDB_REPEAT_NONE}, {"vcpu",kdb_cmdf_vcpu, 1, "[all|ptr]", "Display vcpu/s", KDB_REPEAT_NONE}, {"dom", kdb_cmdf_dom, 1, "[all|0xdomid]", "Display dom/s", KDB_REPEAT_NONE}, {"mmu", kdb_cmdf_mmu, 1, "", "Basic mmu info", KDB_REPEAT_NONE}, {"p2m", kdb_cmdf_p2m, 1, "0xdomid 0xgpfn", "gpfn to mfn", KDB_REPEAT_NONE}, {"m2p", kdb_cmdf_m2p, 1, "0xmfn", "mfn to pfn", KDB_REPEAT_NONE}, {"dpage", kdb_cmdf_dpage, 1, "mfn|page-ptr", "Display page info", KDB_REPEAT_NONE}, {"dtrq", kdb_cmdf_dtrq, 1, "", "Dump timer queues", KDB_REPEAT_NONE}, {"didt", kdb_cmdf_didt, 1, "", "Dump IDT current table", KDB_REPEAT_NONE}, {"dgdt", kdb_cmdf_dgdt, 1, "", "Dump GDT table ", KDB_REPEAT_NONE}, {"dirq", kdb_cmdf_dirq, 1, "", "Dump IRQs bindings", KDB_REPEAT_NONE}, {"dvmc", kdb_cmdf_dvmc, 1, "[0xdomid][0xvcpuid]", "Dump vmcs/vmcb", KDB_REPEAT_NONE}, /* tracing related commands */ {"trcon", kdb_cmdf_trcon, 0, "", "turn tracing on", KDB_REPEAT_NONE}, {"trcoff", kdb_cmdf_trcoff, 0, "", "turn tracing off", KDB_REPEAT_NONE}, {"trcz", kdb_cmdf_trcz, 0, "", "zero entire trace buffer", KDB_REPEAT_NONE}, {"trcp", kdb_cmdf_trcp, 1, "", "hints to print trace buffer via dd cmd", KDB_REPEAT_NONE}, _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel