Re: Kernel Debugging using Qemu

2015-08-15 Thread Aruna Hewapathirane
Hi Saket, Thank you so much for the clear instructions. I really wanted to get qemu to work on my 64bit system so I kept trying and finally I got things to work. After following your instructions I could get further but gdb complained about a "Remote 'g' packet reply is too long".Your way works f

Re: Kernel Debugging using Qemu

2015-08-14 Thread Saket Sinha
Hi Aruna, Please find the steps below - The kernel needs to be compiled with debugging support, for the same add -g option in KBUILD_CFLAGS and KBUILD_CXXFLAGS. CONFIG_DEBUG_INFO=y make ARCH=i386 menuconfig make ARCH=i386 bzImage -j 5 Now we have compiled the 32 bit binaries Starting the qemu

Kernel Debugging using Qemu

2015-08-14 Thread Aruna Hewapathirane
Hi, If anyone uses Qemu can someone please show me how to get started ? I tried : sudo qemu-system-x86_64 -s -S -kernel arch/x86/boot/bzImage -initrd /boot/initrd.img-4.1.2-vtaqemu+ /dev/zero And it does allow me to access through gdb using target remote localhost:1234 but when I set a breakpoi