lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Thu, 28 Oct 2021 15:01:58 -0700
From:   Doug Anderson <dianders@...omium.org>
To:     Stephen Boyd <swboyd@...omium.org>
Cc:     Jan Kiszka <jan.kiszka@...mens.com>,
        Kieran Bingham <kbingham@...nel.org>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Johannes Berg <johannes.berg@...el.com>,
        LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] scripts/gdb: Handle split debug for vmlinux

Hi,

On Thu, Oct 28, 2021 at 3:00 PM Stephen Boyd <swboyd@...omium.org> wrote:
>
> Quoting Douglas Anderson (2021-10-28 14:08:49)
> > This is related to two previous changes. Commit dfe4529ee4d3
> > ("scripts/gdb: find vmlinux where it was before") and commit
> > da036ae14762 ("scripts/gdb: handle split debug").
> >
> > Although Chrome OS has been using the debug suffix for modules for a
> > while, it has just recently started using it for vmlinux as well. That
> > means we've now got to improve the detection of "vmlinux" to also
> > handle that it might end with ".debug".
> >
> > Cc: Stephen Boyd <swboyd@...omium.org>
> > Signed-off-by: Douglas Anderson <dianders@...omium.org>
> > ---
> >
> >  scripts/gdb/linux/symbols.py | 3 ++-
> >  scripts/gdb/vmlinux-gdb.py   | 0
> >  2 files changed, 2 insertions(+), 1 deletion(-)
> >  mode change 100644 => 100755 scripts/gdb/vmlinux-gdb.py
> >
> > diff --git a/scripts/gdb/linux/symbols.py b/scripts/gdb/linux/symbols.py
> > index 08d264ac328b..46f7542db08c 100644
> > --- a/scripts/gdb/linux/symbols.py
> > +++ b/scripts/gdb/linux/symbols.py
> > @@ -148,7 +148,8 @@ lx-symbols command."""
> >          # drop all current symbols and reload vmlinux
> >          orig_vmlinux = 'vmlinux'
> >          for obj in gdb.objfiles():
> > -            if obj.filename.endswith('vmlinux'):
> > +            if (obj.filename.endswith('vmlinux') or
> > +                obj.filename.endswith('vmlinux.debug')):
>
> Looks good.
>
> >                  orig_vmlinux = obj.filename
> >          gdb.execute("symbol-file", to_string=True)
> >          gdb.execute("symbol-file {0}".format(orig_vmlinux))
> > diff --git a/scripts/gdb/vmlinux-gdb.py b/scripts/gdb/vmlinux-gdb.py
> > old mode 100644
> > new mode 100755
>
> Is this mode change important?

Ah, shoot. While I was debugging what could have gone wrong, I changed
it and I didn't notice that it had made it into the commit. Let me do
a quick v2. Thanks for catching!

-Doug

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ