Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Vimal <j.vimal@gmail.com>
To: gdb@sourceware.org, tromey <tromey@redhat.com>
Subject: Re: Multiple breakpoint issue when debugging loadable kernel module
Date: Wed, 26 Oct 2011 12:25:00 -0000	[thread overview]
Message-ID: <CAK3Ji13Vwh9ZBENNtBkuHfqww1=OhcUGKeCWwgYVmT++a5c4UQ@mail.gmail.com> (raw)
In-Reply-To: <CAK3Ji13etC=V-mVsbTYLOrTa4ErgaCF8xd+QPU1gtDbngdJpZw@mail.gmail.com>

Hi,

With some suggestions from IRC folks sergiodj and SamB, I ran a git
bisect on the HEAD of git://sourceware.org/git/gdb.git.

It seems like the first bad commit is:
2cdbbe44126601596aad7891de05cb7fc6bb21c8, which seems pretty big
~6000lines.

Quoted below is my first mail to the list, with few details about the
problem.  Also, here's an output from an actual run:
http://pastebin.com/4PhDAHwW...

Tom Tromey: is this a known issue?

Thanks,
--
Vimal


On 23 October 2011 20:16, Vimal <j.vimal@gmail.com> wrote:
> Hi,
>
> I have a loadable kernel module, and I am facing issues when setting
> breakpoints.
>
> I am using gdb 7.3.1 from ftp://ftp.gnu.org/gnu/gdb.
>
> 1. I start the kernel under qemu-kvm and load the kernel module.  The
> kernel module was compiled with CFLAGS=-O0 -g
>
> 2. I generate the add-symbol-path command by using section address
> information from /sys/module/$mod/sections/.*
>
> 3. I enter the add-symbol-path command into gdb, which is connected to
> qemu's gdb stub via "target remote" command.
>
> 4. After loading the symbols, I do: "info line function" and am able
> to see the function name's line number.   Also, "list function" shows
> the source code from the correct file.
>
> 5. I do "break function", I see this message:
>    Breakpoint 1 at address (2 locations)
>
> After the last step, if I run "info line function", I see "No line
> number information available for address..."
>
> When I type "info break", I see the two breakpoints inserted at
> "function+4" and "function+31".
>
> This error does not happen in gdb-7.1.   The reason I am using
> gdb-7.3.1 is that I want to use gdb.Breakpoint from a python script.
>
> Is there a way to fix this error?   Why are two breakpoints being set?
>  This error happens across a few kernel modules that I tested.
>
> Thanks,
> --
> Vimal
>



-- 
Vimal


  parent reply	other threads:[~2011-10-25  2:58 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-24  2:20 Vimal
2011-10-24 14:11 ` Vimal
2011-10-26 12:25 ` Vimal [this message]
2011-10-27  0:22   ` Jan Kiszka
2011-10-27  0:43     ` Vimal
2011-10-27  7:21       ` Jan Kiszka
2011-10-27 14:59         ` Vimal
2011-10-27 16:12           ` Jan Kiszka
2011-10-28  0:16         ` Tom Tromey
2011-10-31 17:20           ` Jan Kiszka
2011-10-27 19:38     ` Tom Tromey
2011-10-28  3:40       ` Vimal
2011-10-28 21:07         ` Vimal
2011-10-31 17:18           ` Jan Kiszka
2011-10-31 21:33             ` Tom Tromey
2011-11-01 15:32               ` Jan Kiszka
2011-11-01 20:13                 ` Jan Kratochvil
2011-11-05  2:07                   ` Vimal
2011-11-05  5:39                     ` Jan Kratochvil
2011-11-08  0:33                   ` Jan Kratochvil
2011-11-05  2:10             ` Vimal

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAK3Ji13Vwh9ZBENNtBkuHfqww1=OhcUGKeCWwgYVmT++a5c4UQ@mail.gmail.com' \
    --to=j.vimal@gmail.com \
    --cc=gdb@sourceware.org \
    --cc=tromey@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox