From: daniel.thompson@linaro.org (Daniel Thompson)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 3.17-rc4 v7 0/6] arm: Implement arch_trigger_all_cpu_backtrace
Date: Thu, 16 Oct 2014 10:23:52 +0100 [thread overview]
Message-ID: <543F8EA8.6080905@linaro.org> (raw)
In-Reply-To: <CAD8Lp44gPOBh_q1zDy3y1GkrRVAvix5YaNr-+E92+g8Q7fLKJA@mail.gmail.com>
On 14/10/14 23:37, Daniel Drake wrote:
> Hi,
>
> Thanks a lot for working on this!
>
> On Wed, Sep 17, 2014 at 10:10 AM, Daniel Thompson
> <daniel.thompson@linaro.org> wrote:
>> Changes *before* v1:
>>
>> * This patchset is a hugely cut-down successor to "[PATCH v11 00/19]
>> arm: KGDB NMI/FIQ support". Thanks to Thomas Gleixner for suggesting
>> the new structure. For historic details see:
>> https://lkml.org/lkml/2014/9/2/227
>
> What's the right way to extend your work in order to get a NMI-like
> watchdog hard lockup detector similar to the one on x86?
There are a few things to get into place for this.
1. Figure out what number to put into the PMU to get an interrupt every
10s and provide the stub functions for the lock up detector.
2. Modify the current ARM PMU support to make is possible for this code
to run from a FIQ handler. This should be feasible by replicating
the design pattern used on x86. Nevertheless this is a fairly big
chunk of code review and testing.
3. Modify the Linux IRQ support to allow some kind of flag to
hint/demand that an interrupt be treated as NMI-ish in order to
switch (unshared) interrupts into FIQ mode and hook this up in
the GIC.
[Side note, this approach was suggested by Thomas Gleixner in
response to some rather hacky patches from me. My patches are
robust enough but are poorly designed and hard to maintain.
Thus if you want to do any quick prototyping you might skip this
step and dig out my old patches:
https://git.linaro.org/people/daniel.thompson/linux.git/shortlog/refs/heads/dev/kdb-fiq
Note also that, as a side effect of the above, tools like oprofile would
also get a very significant boost for kernel profiling because they
would no longer attribute time spent in interrupt handlers to interrupt
unmask functions.
At present I've done a little work towards all three of the above but
none are complete (most of the code has never been executed).
> I'm testing your patches on Exynos4412 and I guess in their current
> state they don't go quite this deep, as the only callers of
> trigger_all_cpu_backtrace() are sysrq, hung_task and spinlock debug
> code - none of which seem as fail-safe as a trigger like a
> pre-programmed watchdog NMI interrupt would be.
>
> Do I need to find a way to get CONFIG_FIQ available on this platform
> first? and/or CONFIG_HARDLOCKUP_DETECTOR?
You need CONFIG_FIQ working first. Be aware that this may be impossible
on Exynos unless you control the TrustZone. For this reason most of my
development is on Freescale i.MX6 (because i.MX6 boots in secure mode).
Daniel.
next prev parent reply other threads:[~2014-10-16 9:23 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-17 16:10 [PATCH 3.17-rc4 v7 0/6] arm: Implement arch_trigger_all_cpu_backtrace Daniel Thompson
2014-09-17 16:10 ` [PATCH 3.17-rc4 v7 1/6] ARM: remove unused do_unexp_fiq() function Daniel Thompson
2014-09-17 16:10 ` [PATCH 3.17-rc4 v7 2/6] arm: fiq: Replace default FIQ handler Daniel Thompson
2014-09-17 16:10 ` [PATCH 3.17-rc4 v7 3/6] arm64: Introduce dummy version of asm/fiq.h Daniel Thompson
2014-09-22 9:16 ` Catalin Marinas
2014-09-17 16:10 ` [PATCH 3.17-rc4 v7 4/6] irqchip: gic: Add support for IPI FIQ Daniel Thompson
2014-09-17 18:51 ` Russell King - ARM Linux
2014-09-17 20:12 ` Daniel Thompson
2014-09-17 21:07 ` Russell King - ARM Linux
2014-09-18 7:48 ` Russell King - ARM Linux
2014-09-18 21:46 ` Marc Zyngier
2014-09-18 8:17 ` Russell King - ARM Linux
2014-09-18 21:20 ` Daniel Thompson
2014-09-17 16:10 ` [PATCH 3.17-rc4 v7 5/6] ARM: add basic support for on-demand backtrace of other CPUs Daniel Thompson
2014-09-17 16:10 ` [PATCH 3.17-rc4 v7 6/6] arm: smp: Handle ipi_cpu_backtrace() using FIQ (if available) Daniel Thompson
2014-10-14 22:37 ` [PATCH 3.17-rc4 v7 0/6] arm: Implement arch_trigger_all_cpu_backtrace Daniel Drake
2014-10-14 23:31 ` Russell King - ARM Linux
2014-10-16 9:33 ` Daniel Thompson
2014-11-04 17:05 ` Daniel Thompson
2014-11-04 17:19 ` Russell King - ARM Linux
2014-10-16 9:23 ` Daniel Thompson [this message]
2014-10-16 12:23 ` Russell King - ARM Linux
2014-10-16 13:15 ` Daniel Thompson
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=543F8EA8.6080905@linaro.org \
--to=daniel.thompson@linaro.org \
--cc=linux-arm-kernel@lists.infradead.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).