Re: [Qemu-devel] Failed to use gdb with qemu 15.1 (with and without kvm support)

2012-01-22 Thread Francis Moreau
On Sun, Jan 22, 2012 at 10:15 PM, Jan Kiszka wrote: > On 2012-01-22 20:58, Francis Moreau wrote: >> On Sun, Jan 22, 2012 at 8:21 PM, Jan Kiszka wrote: >>> On 2012-01-22 20:16, Max Filippov wrote: > When stopping the guest with -S before it booted, gdb will interrupt it > while it is still

Re: [Qemu-devel] Failed to use gdb with qemu 15.1 (with and without kvm support)

2012-01-22 Thread Jan Kiszka
On 2012-01-22 20:58, Francis Moreau wrote: > On Sun, Jan 22, 2012 at 8:21 PM, Jan Kiszka wrote: >> On 2012-01-22 20:16, Max Filippov wrote: When stopping the guest with -S before it booted, gdb will interrupt it while it is still in 16-bit real mode. Later on, when Linux runs, the g

Re: [Qemu-devel] Failed to use gdb with qemu 15.1 (with and without kvm support)

2012-01-22 Thread Francis Moreau
On Sun, Jan 22, 2012 at 8:21 PM, Jan Kiszka wrote: > On 2012-01-22 20:16, Max Filippov wrote: >>> When stopping the guest with -S before it booted, gdb will interrupt it >>> while it is still in 16-bit real mode. Later on, when Linux runs, the >>> guest is in 64-bit protected mode. gdb is not prep

Re: [Qemu-devel] Failed to use gdb with qemu 15.1 (with and without kvm support)

2012-01-22 Thread Francis Moreau
On Sun, Jan 22, 2012 at 8:28 PM, Jan Kiszka wrote: > On 2012-01-22 20:25, Francis Moreau wrote: >> Hello, >> >> Thanks for you hints ! >> >> On Sun, Jan 22, 2012 at 7:49 PM, Jan Kiszka wrote: >>> On 2012-01-22 15:20, Francis Moreau wrote: Hello, I'm trying to debug a 64 bits kernel

Re: [Qemu-devel] Failed to use gdb with qemu 15.1 (with and without kvm support)

2012-01-22 Thread Michael Tokarev
On 22.01.2012 23:11, Francis Moreau wrote: [] > I'm not sure to understand: it seems that you think that I want to > debug qemu itself, but I don't. > > I want to debug a kernel running inside a VM. > > Am I mis understanding your comment ? It is the other way around: it was me who misunderstood

Re: [Qemu-devel] Failed to use gdb with qemu 15.1 (with and without kvm support)

2012-01-22 Thread Francis Moreau
hello, On Sun, Jan 22, 2012 at 8:16 PM, Max Filippov wrote: >> When stopping the guest with -S before it booted, gdb will interrupt it >> while it is still in 16-bit real mode. Later on, when Linux runs, the >> guest is in 64-bit protected mode. gdb is not prepared for such a >> switch. All you c

Re: [Qemu-devel] Failed to use gdb with qemu 15.1 (with and without kvm support)

2012-01-22 Thread Jan Kiszka
On 2012-01-22 20:25, Francis Moreau wrote: > Hello, > > Thanks for you hints ! > > On Sun, Jan 22, 2012 at 7:49 PM, Jan Kiszka wrote: >> On 2012-01-22 15:20, Francis Moreau wrote: >>> Hello, >>> >>> I'm trying to debug a 64 bits kernel (3.2) using qemu (with and >>> without KVM support). The hos

Re: [Qemu-devel] Failed to use gdb with qemu 15.1 (with and without kvm support)

2012-01-22 Thread Francis Moreau
Hello, Thanks for you hints ! On Sun, Jan 22, 2012 at 7:49 PM, Jan Kiszka wrote: > On 2012-01-22 15:20, Francis Moreau wrote: >> Hello, >> >> I'm trying to debug a 64 bits kernel (3.2) using qemu (with and >> without KVM support). The host is also 64 bits. Version of gdb I'm >> using is 7.1. >>

Re: [Qemu-devel] Failed to use gdb with qemu 15.1 (with and without kvm support)

2012-01-22 Thread Jan Kiszka
On 2012-01-22 20:16, Max Filippov wrote: >> When stopping the guest with -S before it booted, gdb will interrupt it >> while it is still in 16-bit real mode. Later on, when Linux runs, the >> guest is in 64-bit protected mode. gdb is not prepared for such a >> switch. All you can do: > > Try > >

Re: [Qemu-devel] Failed to use gdb with qemu 15.1 (with and without kvm support)

2012-01-22 Thread Max Filippov
> When stopping the guest with -S before it booted, gdb will interrupt it > while it is still in 16-bit real mode. Later on, when Linux runs, the > guest is in 64-bit protected mode. gdb is not prepared for such a > switch. All you can do: Try set arch i386:x86-64 in the GDB prompt. -- Thanks.

Re: [Qemu-devel] Failed to use gdb with qemu 15.1 (with and without kvm support)

2012-01-22 Thread Francis Moreau
Hello, On Sun, Jan 22, 2012 at 6:11 PM, Michael Tokarev wrote: > On 22.01.2012 18:20, Francis Moreau wrote: >> Hello, >> >> I'm trying to debug a 64 bits kernel (3.2) using qemu (with and >> without KVM support). The host is also 64 bits. Version of gdb I'm >> using is 7.1. > > I'm not sure how i

Re: [Qemu-devel] Failed to use gdb with qemu 15.1 (with and without kvm support)

2012-01-22 Thread Jan Kiszka
On 2012-01-22 15:20, Francis Moreau wrote: > Hello, > > I'm trying to debug a 64 bits kernel (3.2) using qemu (with and > without KVM support). The host is also 64 bits. Version of gdb I'm > using is 7.1. > > To do that I simply start qemu like the following: > > $ qemu-system-x86_64 -kernel bz

Re: [Qemu-devel] Failed to use gdb with qemu 15.1 (with and without kvm support)

2012-01-22 Thread Michael Tokarev
On 22.01.2012 18:20, Francis Moreau wrote: > Hello, > > I'm trying to debug a 64 bits kernel (3.2) using qemu (with and > without KVM support). The host is also 64 bits. Version of gdb I'm > using is 7.1. I'm not sure how it is relevant but at least last (1.0) qemu is compiled as PIE executable b

[Qemu-devel] Failed to use gdb with qemu 15.1 (with and without kvm support)

2012-01-22 Thread Francis Moreau
Hello, I'm trying to debug a 64 bits kernel (3.2) using qemu (with and without KVM support). The host is also 64 bits. Version of gdb I'm using is 7.1. To do that I simply start qemu like the following: $ qemu-system-x86_64 -kernel bzImage -append "root=/dev/sda1 console=ttyS0 3" -serial stdio