xref: /openbmc/linux/arch/s390/include/asm/dwarf.h (revision b2959fdd)
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef _ASM_S390_DWARF_H
3 #define _ASM_S390_DWARF_H
4 
5 #ifdef __ASSEMBLY__
6 
7 #define CFI_STARTPROC		.cfi_startproc
8 #define CFI_ENDPROC		.cfi_endproc
9 #define CFI_DEF_CFA_OFFSET	.cfi_def_cfa_offset
10 #define CFI_ADJUST_CFA_OFFSET	.cfi_adjust_cfa_offset
11 #define CFI_RESTORE		.cfi_restore
12 #define CFI_REL_OFFSET		.cfi_rel_offset
13 
14 #ifdef CONFIG_AS_CFI_VAL_OFFSET
15 #define CFI_VAL_OFFSET		.cfi_val_offset
16 #else
17 #define CFI_VAL_OFFSET		#
18 #endif
19 
20 #ifndef BUILD_VDSO
21 	/*
22 	 * Emit CFI data in .debug_frame sections and not in .eh_frame
23 	 * sections.  The .eh_frame CFI is used for runtime unwind
24 	 * information that is not being used.  Hence, vmlinux.lds.S
25 	 * can discard the .eh_frame sections.
26 	 */
27 	.cfi_sections .debug_frame
28 #else
29 	/*
30 	 * For vDSO, emit CFI data in both, .eh_frame and .debug_frame
31 	 * sections.
32 	 */
33 	.cfi_sections .eh_frame, .debug_frame
34 #endif
35 
36 #endif	/* __ASSEMBLY__ */
37 
38 #endif	/* _ASM_S390_DWARF_H */
39