Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1544049 > unrolled thread

[BUG] kernel freeze, rcu_sched self-detected stall on CPU

Started byJohanna Abrahamsson <johanna@mjao.org>
First post2016-12-17 23:30 +0100
Last post2016-12-19 10:10 +0100
Articles 3 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [BUG] kernel freeze, rcu_sched self-detected stall on CPU Johanna Abrahamsson <johanna@mjao.org> - 2016-12-17 23:30 +0100
    Re: [BUG] kernel freeze, rcu_sched self-detected stall on CPU Davidlohr Bueso <dave@stgolabs.net> - 2016-12-18 17:40 +0100
      Re: [BUG] kernel freeze, rcu_sched self-detected stall on CPU Johanna Abrahamsson <johanna@mjao.org> - 2016-12-19 10:10 +0100

#1544049 — [BUG] kernel freeze, rcu_sched self-detected stall on CPU

FromJohanna Abrahamsson <johanna@mjao.org>
Date2016-12-17 23:30 +0100
Subject[BUG] kernel freeze, rcu_sched self-detected stall on CPU
Message-ID<sPvEl-7do-13@gated-at.bofh.it>
A bug has been introduced in ipc/sem.c by a patch '[PATCH -next 2/2] ipc/sem: avoid idr tree lookup for interrupted semop' (https://marc.info/?l=linux-kernel&m=147870885903619, commit 370b262c896e5565b271a3ea3abee4d0914ba443).
The bug results in a kernel freeze and several "INFO: rcu_sched self-detected stall on CPU". The system becomes unresponsible and has to be rebooted to work again as far as I can tell.
My repro case is, hilariously enough, packaging the linux kernel for debian with `make -j8 deb-pkg`. I'm sure a smaller repro case could be constructed, but so far I've had 100% reproducibility from this one. The freeze always occurs at the Makefiles.headerinst part of packaging, after the kernel is built.
The bug is present in next-20161124 and linux-next versions going forward from that and has now been merged to linus/master. However, in linus/master it doesn't trigger a bug. This seems to indicate that it only triggers a bug in combination with a commit that is present in next-20161216 but not present in linus/master.
I've confirmed that doing `git revert 370b262c896e5565b271a3ea3abee4d0914ba443` on next-20161216 fixes the bug.

In all repro cases I've tested on virtual machines with multiple cpu cores running under either Xen or Virtualbox.

I will try to investigate this further but as I have limited knowledge of RCU and how the kernel works with semaphores don't expect any miracles :)

Best Regards,
Johanna Abrahamsson

[toc] | [next] | [standalone]


#1544166

FromDavidlohr Bueso <dave@stgolabs.net>
Date2016-12-18 17:40 +0100
Message-ID<sPMFb-2zL-1@gated-at.bofh.it>
In reply to#1544049
On Sat, 17 Dec 2016, Johanna Abrahamsson wrote:

>I will try to investigate this further but as I have limited knowledge of RCU and how the kernel works with semaphores don't expect any miracles :)

Please see if this helps: https://lkml.org/lkml/2016/12/18/79

Thanks,
Davidlohr

[toc] | [prev] | [next] | [standalone]


#1544382

FromJohanna Abrahamsson <johanna@mjao.org>
Date2016-12-19 10:10 +0100
Message-ID<sQ27g-5M1-29@gated-at.bofh.it>
In reply to#1544166
On Sun, Dec 18, 2016 at 08:32:23AM -0800, Davidlohr Bueso wrote:
> Please see if this helps: https://lkml.org/lkml/2016/12/18/79

That does help, thank you! I would never have fixed this myself in reasonable time :)


Best Regards,
Johanna Abrahamsson

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web