linux/arch/blackfin/mach-common
Robin Getz b9a3899d59 Blackfin: make deferred hardware errors more exact
Hardware errors on the Blackfin architecture are queued by nature of the
hardware design.  Things that could generate a hardware level queue up at
the system interface and might not process until much later, at which
point the system would send a notification back to the core.

As such, it is possible for user space code to do something that would
trigger a hardware error, but have it delay long enough for the process
context to switch.  So when the hardware error does signal, we mistakenly
evaluate it as a different process or as kernel context and panic (erp!).
This makes it pretty difficult to find the offending context.  But wait,
there is good news somewhere.

By forcing a SSYNC in the interrupt entry, we force all pending queues at
the system level to be processed and all hardware errors to be signaled.
Then we check the current interrupt state to see if the hardware error is
now signaled.  If so, we re-queue the current interrupt and return thus
allowing the higher priority hardware error interrupt to process properly.
Since we haven't done any other context processing yet, the right context
will be selected and killed.  There is still the possibility that the
exact offending instruction will be unknown, but at least we'll have a
much better idea of where to look.

The downside of course is that this causes system-wide syncs at every
interrupt point which results in significant performance degradation.
Since this situation should not occur in any properly configured system
(as hardware errors are triggered by things like bad pointers), make it a
debug configuration option and disable it by default.

Signed-off-by: Robin Getz <robin.getz@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-06-12 06:11:44 -04:00
..
arch_checks.c Blackfin: work around anomaly 05000220 2009-06-12 06:11:41 -04:00
cache-c.c Blackfin arch: rewrite blackfin_invalidate_entire_dcache function 2008-11-18 17:48:22 +08:00
cache.S Blackfin: simplify the do_flush macro 2009-06-12 06:03:48 -04:00
clocks-init.c Blackfin: add note about anomaly 05000242 being worked around 2009-06-12 06:11:42 -04:00
cpufreq.c Blackfin: detect anomaly 05000274 2009-06-12 06:11:35 -04:00
dpmc.c [Blackfin] arch: Functional power management support: Add CPU and platform voltage scaling support 2008-05-07 11:41:26 +08:00
dpmc_modes.S Blackfin arch: fix bug - On bf548-ezkit, ethernet fails to work after wakeup from "mem" 2009-03-05 18:41:24 +08:00
entry.S Blackfin: make deferred hardware errors more exact 2009-06-12 06:11:44 -04:00
head.S Blackfin: workaround anomaly 05000227 2009-06-12 06:11:32 -04:00
interrupt.S Blackfin: make deferred hardware errors more exact 2009-06-12 06:11:44 -04:00
ints-priority.c Blackfin: add support for gptimer0 as a tick source 2009-06-12 06:11:37 -04:00
irqpanic.c Blackfin arch: remove hardware PM code, oprofile not use it 2009-01-07 23:14:39 +08:00
lock.S Blackfin arch: rename cache_lock() to bfin_cache_lock() 2008-11-18 17:48:22 +08:00
Makefile Blackfin arch: fix bugs and unify BFIN_KERNEL_CLOCK option 2009-01-07 23:14:39 +08:00
pm.c Blackfin arch: Blacklist Hibernate (PM_SUSPEND_MEM) on BF561 as well 2009-03-28 23:14:41 +08:00
smp.c Blackfin: add support for gptimer0 as a tick source 2009-06-12 06:11:37 -04:00