debugging with Qemu
bakul at BitBlocks.com
Wed Jun 8 18:55:12 GMT 2005
Hmm... I've used qemu a bit to debug the kernel. Even used
it to debug a loadable module. Here is what I did:
# qemu -s img
# cd <path to where the kernel was built on the host>
# gdb kernel.debug
(gdb) target remote localhost:1234
(gdb) l kldload
740 * MPSAFE
743 kldload(struct thread *td, struct kldload_args *uap)
745 char *kldname, *modname;
746 char *pathname = NULL;
747 linker_file_t lf;
748 int error = 0;
(gdb) b 743
Breakpoint 3, kldload (td=0xc1419c00, uap=0xc8105d14)
Program received signal 0, Signal 0.
cpu_idle_default () at /usr/src/sys/i386/i386/machdep.c:1113
Ending remote debugging.
I am using kqemu and qemu built from May 2 snapshot if that
matters. This was a stock 5.4-RELEASE complied locallly
added the kernel config file. The host was also running 5.4
but that should not matter.
May be if you describe the exact symptoms....
More information about the freebsd-hackers