File: frame.h

package info (click to toggle)
linux 6.19.5-1~exp1
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 1,759,704 kB
  • sloc: ansic: 27,007,363; asm: 273,421; sh: 151,330; python: 81,278; makefile: 58,557; perl: 34,311; xml: 21,064; cpp: 5,986; yacc: 4,841; lex: 2,901; awk: 1,707; sed: 30; ruby: 25
file content (48 lines) | stat: -rw-r--r-- 1,116 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
/* SPDX-License-Identifier: GPL-2.0-only */
#ifndef __ASM_STACKTRACE_FRAME_H
#define __ASM_STACKTRACE_FRAME_H

/*
 * - FRAME_META_TYPE_NONE
 *
 *   This value is reserved.
 *
 * - FRAME_META_TYPE_FINAL
 *
 *   The record is the last entry on the stack.
 *   Unwinding should terminate successfully.
 *
 * - FRAME_META_TYPE_PT_REGS
 *
 *   The record is embedded within a struct pt_regs, recording the registers at
 *   an arbitrary point in time.
 *   Unwinding should consume pt_regs::pc, followed by pt_regs::lr.
 *
 * Note: all other values are reserved and should result in unwinding
 * terminating with an error.
 */
#define FRAME_META_TYPE_NONE		0
#define FRAME_META_TYPE_FINAL		1
#define FRAME_META_TYPE_PT_REGS		2

#ifndef __ASSEMBLER__
/* 
 * A standard AAPCS64 frame record.
 */
struct frame_record {
	u64 fp;
	u64 lr;
};

/*
 * A metadata frame record indicating a special unwind.
 * The record::{fp,lr} fields must be zero to indicate the presence of
 * metadata.
 */
struct frame_record_meta {
	struct frame_record record;
	u64 type;
};
#endif /* __ASSEMBLER__ */

#endif /* __ASM_STACKTRACE_FRAME_H */