WIP FPC-III support
[linux/fpc-iii.git] / arch / powerpc / include / asm / fadump.h
blob526a6a6473128a81ff5b0bdfd1e8315889fa2ca4
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2 /*
3 * Firmware Assisted dump header file.
5 * Copyright 2011 IBM Corporation
6 * Author: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com>
7 */
9 #ifndef _ASM_POWERPC_FADUMP_H
10 #define _ASM_POWERPC_FADUMP_H
12 #ifdef CONFIG_FA_DUMP
14 extern int crashing_cpu;
16 extern int is_fadump_memory_area(u64 addr, ulong size);
17 extern int setup_fadump(void);
18 extern int is_fadump_active(void);
19 extern int should_fadump_crash(void);
20 extern void crash_fadump(struct pt_regs *, const char *);
21 extern void fadump_cleanup(void);
23 #else /* CONFIG_FA_DUMP */
24 static inline int is_fadump_active(void) { return 0; }
25 static inline int should_fadump_crash(void) { return 0; }
26 static inline void crash_fadump(struct pt_regs *regs, const char *str) { }
27 static inline void fadump_cleanup(void) { }
28 #endif /* !CONFIG_FA_DUMP */
30 #if defined(CONFIG_FA_DUMP) || defined(CONFIG_PRESERVE_FA_DUMP)
31 extern int early_init_dt_scan_fw_dump(unsigned long node, const char *uname,
32 int depth, void *data);
33 extern int fadump_reserve_mem(void);
34 #endif
35 #endif /* _ASM_POWERPC_FADUMP_H */