linux/drivers/remoteproc
Fernando Guzman Lugo 8afd519c34 remoteproc: add rproc_report_crash function to notify rproc crashes
Allow low-level remoteproc drivers to report rproc crashes by exporting
a new rproc_report_crash() function (invoking this from non-rproc drivers
is probably wrong, and should be carefully scrutinized if ever needed).

rproc_report_crash() can be called from any context; it offloads the
tasks of handling the crash to a separate thread.

Handling the crash from a separate thread is helpful because:
- Ability to call invoke rproc_report_crash() from atomic context, due to
  the fact that many crashes trigger an interrupt, so this function can be
  called directly from ISR context.
- Avoiding deadlocks which could happen if rproc_report_crash() is called
  from a function which indirectly holds the rproc lock.

Handling the crash might involve:
- Remoteproc register dump
- Remoteproc stack dump
- Remoteproc core dump
- Saving Remoteproc traces so they can be read after the crash
- Reseting the remoteproc in order to make it functional again (hard recovery)

Right now, we only print the crash type which was detected, and only the
mmufault type is supported. Remoteproc low-level drivers can add more types
when needed.

Signed-off-by: Fernando Guzman Lugo <fernando.lugo@ti.com>
[ohad: some commentary, white space and commit log changes]
Signed-off-by: Ohad Ben-Cohen <ohad@wizery.com>
2012-09-18 12:53:22 +03:00
..
Kconfig remoteproc: Add dependency to HAS_DMA 2012-09-18 07:05:06 +03:00
Makefile remoteproc: Move Elf related functions to separate file 2012-07-15 11:25:27 +03:00
omap_remoteproc.c remoteproc/omap: set bootaddr support 2012-09-11 15:24:14 +03:00
omap_remoteproc.h remoteproc/omap: add a remoteproc driver for OMAP4 2012-02-08 22:53:47 +02:00
remoteproc_core.c remoteproc: add rproc_report_crash function to notify rproc crashes 2012-09-18 12:53:22 +03:00
remoteproc_debugfs.c remoteproc: maintain a generic child device for each rproc 2012-07-06 00:53:03 +03:00
remoteproc_elf_loader.c A batch of remoteproc patches for 3.6: 2012-07-26 16:19:08 -07:00
remoteproc_internal.h remoteproc: Support custom firmware handlers 2012-07-15 11:39:01 +03:00
remoteproc_virtio.c remoteproc: remove the now-redundant kref 2012-07-06 00:53:25 +03:00