linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Holger Brunck <holger.brunck@keymile.com>
To: linuxppc-dev@lists.ozlabs.org
Cc: dave.hansen@linux.intel.com, mingo@kernel.org
Subject: debug problems on ppc 83xx target due to changed struct task_struct
Date: Fri, 12 Aug 2016 16:50:38 +0200	[thread overview]
Message-ID: <dc38afe9-6b78-f3f5-666b-986939e40fc6@keymile.com> (raw)

Hi all,
we are currently trying to update from kernel 3.10 to latest stable kernel 4.4
and we encounter the following problem.

When I try to debug our multithreaded userspace application with gdb I  get
stuck when trying to single step code.

Due to the fact that our ppc 8360 target is mainlined (kmeter1) I was able to
bisect the kernel to check when this problem was introduced. It turns out to be
introduced with commit:

commit 0c8c0f03e3a292e031596484275c14cf39c0ab7a
Author: Dave Hansen <dave@sr71.net>
Date:   Fri Jul 17 12:28:11 2015 +0200

    x86/fpu, sched: Dynamically allocate 'struct fpu'

This patch moves the definition of "struct thread_struct thread;" from the
middle of the "struct task_struct" to the end (include/linux/sched.h). When I
move back the definition to the original place and recompile, everything works
fine. I double-checked this with the latest kernel 4.7 and I have the  same
behaviour.

I also tried a different toolchain (I got poky/jethro with gcc 5.2) and tried a
eldk 5.4 with gcc 4.7, as I am not sure if this is really a kernel problem  or
related to a gdb or gcc. But I still have the same behaviour with a different
toolchain.

Does anyone have an idea why the change in sched.h break my debug usecase?
Anyone out here who is debugging ppc83xx targets flawlessly with a recent kernel?

Any help is apreciated.

Best regards
Holger Brunck

             reply	other threads:[~2016-08-12 14:56 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-12 14:50 Holger Brunck [this message]
2016-08-12 15:14 ` debug problems on ppc 83xx target due to changed struct task_struct Dave Hansen
2016-08-12 15:47   ` Holger Brunck
2016-08-12 16:09     ` Dave Hansen
2016-08-15 14:35       ` Holger Brunck
2016-08-15 16:19         ` Dave Hansen
2016-08-16 17:27           ` christophe leroy
2016-08-16 17:36             ` Dave Hansen
2016-08-17  8:22               ` Christophe Leroy
2016-08-17 15:27             ` Holger Brunck
2016-08-18  8:23               ` Christophe Leroy
2016-08-19 11:03               ` Christophe Leroy
2016-08-19 11:14                 ` Holger Brunck
2016-08-19 13:44                   ` Christophe Leroy
2016-08-19 16:26                     ` Holger Brunck
2016-08-16 22:13           ` Benjamin Herrenschmidt
2016-08-17 15:05             ` Holger Brunck
2016-08-17 14:59           ` Holger Brunck

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=dc38afe9-6b78-f3f5-666b-986939e40fc6@keymile.com \
    --to=holger.brunck@keymile.com \
    --cc=dave.hansen@linux.intel.com \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=mingo@kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).