aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorHuang Ying <ying.huang@intel.com>2011-12-07 22:25:49 -0500
committerLen Brown <len.brown@intel.com>2012-01-17 03:54:44 -0500
commitb54ac6d2a25084667da781c7ca2cebef52a2bcdd (patch)
treeb4dbaa790dcecff6b5b0772846d43b360f6389d7 /include/linux
parentb4e008dc53a31cb4bf6a12d9dbaf1d5c6070a838 (diff)
ACPI, Record ACPI NVS regions
Some firmware will access memory in ACPI NVS region via APEI. That is, instructions in APEI ERST/EINJ table will read/write ACPI NVS region. The original resource conflict checking in APEI code will check memory/ioport accessed by APEI via general resource management mechanism. But ACPI NVS region is marked as busy already, so that the false resource conflict will prevent APEI ERST/EINJ to work. To fix this, this patch record ACPI NVS regions, so that we can avoid request resources for memory region inside it. Signed-off-by: Huang Ying <ying.huang@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/acpi.h20
1 files changed, 14 insertions, 6 deletions
diff --git a/include/linux/acpi.h b/include/linux/acpi.h
index 6001b4da39dd..26b75442ff7a 100644
--- a/include/linux/acpi.h
+++ b/include/linux/acpi.h
@@ -306,6 +306,11 @@ extern acpi_status acpi_pci_osc_control_set(acpi_handle handle,
306 u32 *mask, u32 req); 306 u32 *mask, u32 req);
307extern void acpi_early_init(void); 307extern void acpi_early_init(void);
308 308
309extern int acpi_nvs_register(__u64 start, __u64 size);
310
311extern int acpi_nvs_for_each_region(int (*func)(__u64, __u64, void *),
312 void *data);
313
309#else /* !CONFIG_ACPI */ 314#else /* !CONFIG_ACPI */
310 315
311#define acpi_disabled 1 316#define acpi_disabled 1
@@ -348,15 +353,18 @@ static inline int acpi_table_parse(char *id,
348{ 353{
349 return -1; 354 return -1;
350} 355}
351#endif /* !CONFIG_ACPI */
352 356
353#ifdef CONFIG_ACPI_SLEEP 357static inline int acpi_nvs_register(__u64 start, __u64 size)
354int suspend_nvs_register(unsigned long start, unsigned long size);
355#else
356static inline int suspend_nvs_register(unsigned long a, unsigned long b)
357{ 358{
358 return 0; 359 return 0;
359} 360}
360#endif 361
362static inline int acpi_nvs_for_each_region(int (*func)(__u64, __u64, void *),
363 void *data)
364{
365 return 0;
366}
367
368#endif /* !CONFIG_ACPI */
361 369
362#endif /*_LINUX_ACPI_H*/ 370#endif /*_LINUX_ACPI_H*/