Commit 81e88fdc authored by Huang Ying's avatar Huang Ying Committed by Len Brown

ACPI, APEI, Generic Hardware Error Source POLL/IRQ/NMI notification type support

Generic Hardware Error Source provides a way to report platform
hardware errors (such as that from chipset). It works in so called
"Firmware First" mode, that is, hardware errors are reported to
firmware firstly, then reported to Linux by firmware. This way, some
non-standard hardware error registers or non-standard hardware link
can be checked by firmware to produce more valuable hardware error
information for Linux.

This patch adds POLL/IRQ/NMI notification types support.

Because the memory area used to transfer hardware error information
from BIOS to Linux can be determined only in NMI, IRQ or timer
handler, but general ioremap can not be used in atomic context, so a
special version of atomic ioremap is implemented for that.

Known issue:

- Error information can not be printed for recoverable errors notified
  via NMI, because printk is not NMI-safe. Will fix this via delay
  printing to IRQ context via irq_work or make printk NMI-safe.

v2:

- adjust printk format per comments.
Signed-off-by: default avatarHuang Ying <ying.huang@intel.com>
Reviewed-by: default avatarAndi Kleen <ak@linux.intel.com>
Signed-off-by: default avatarLen Brown <len.brown@intel.com>
parent 32c361f5
...@@ -504,6 +504,7 @@ int acpi_gsi_to_irq(u32 gsi, unsigned int *irq) ...@@ -504,6 +504,7 @@ int acpi_gsi_to_irq(u32 gsi, unsigned int *irq)
return 0; return 0;
} }
EXPORT_SYMBOL_GPL(acpi_gsi_to_irq);
int acpi_isa_irq_to_gsi(unsigned isa_irq, u32 *gsi) int acpi_isa_irq_to_gsi(unsigned isa_irq, u32 *gsi)
{ {
......
...@@ -240,6 +240,7 @@ unsigned __kprobes long oops_begin(void) ...@@ -240,6 +240,7 @@ unsigned __kprobes long oops_begin(void)
bust_spinlocks(1); bust_spinlocks(1);
return flags; return flags;
} }
EXPORT_SYMBOL_GPL(oops_begin);
void __kprobes oops_end(unsigned long flags, struct pt_regs *regs, int signr) void __kprobes oops_end(unsigned long flags, struct pt_regs *regs, int signr)
{ {
......
This diff is collapsed.
...@@ -34,6 +34,7 @@ static int pause_on_oops_flag; ...@@ -34,6 +34,7 @@ static int pause_on_oops_flag;
static DEFINE_SPINLOCK(pause_on_oops_lock); static DEFINE_SPINLOCK(pause_on_oops_lock);
int panic_timeout; int panic_timeout;
EXPORT_SYMBOL_GPL(panic_timeout);
ATOMIC_NOTIFIER_HEAD(panic_notifier_list); ATOMIC_NOTIFIER_HEAD(panic_notifier_list);
......
...@@ -9,6 +9,7 @@ ...@@ -9,6 +9,7 @@
#include <linux/mm.h> #include <linux/mm.h>
#include <linux/sched.h> #include <linux/sched.h>
#include <linux/io.h> #include <linux/io.h>
#include <linux/module.h>
#include <asm/cacheflush.h> #include <asm/cacheflush.h>
#include <asm/pgtable.h> #include <asm/pgtable.h>
...@@ -90,3 +91,4 @@ int ioremap_page_range(unsigned long addr, ...@@ -90,3 +91,4 @@ int ioremap_page_range(unsigned long addr,
return err; return err;
} }
EXPORT_SYMBOL_GPL(ioremap_page_range);
...@@ -1175,6 +1175,7 @@ void unmap_kernel_range_noflush(unsigned long addr, unsigned long size) ...@@ -1175,6 +1175,7 @@ void unmap_kernel_range_noflush(unsigned long addr, unsigned long size)
{ {
vunmap_page_range(addr, addr + size); vunmap_page_range(addr, addr + size);
} }
EXPORT_SYMBOL_GPL(unmap_kernel_range_noflush);
/** /**
* unmap_kernel_range - unmap kernel VM area and flush cache and TLB * unmap_kernel_range - unmap kernel VM area and flush cache and TLB
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment