]>
Commit | Line | Data |
---|---|---|
d37c90d4 MH |
1 | /* SPDX-License-Identifier: GPL-2.0-or-later */ |
2 | /* | |
3 | * Copyright (C) 2020 Matt Helsley <mhelsley@vmware.com> | |
4 | */ | |
5 | ||
6 | #ifndef _OBJTOOL_H | |
7 | #define _OBJTOOL_H | |
8 | ||
9 | #include <stdbool.h> | |
10 | #include <linux/list.h> | |
11 | #include <linux/hashtable.h> | |
12 | ||
13 | #include "elf.h" | |
14 | ||
eda3dc90 JT |
15 | #define __weak __attribute__((weak)) |
16 | ||
d37c90d4 MH |
17 | struct objtool_file { |
18 | struct elf *elf; | |
19 | struct list_head insn_list; | |
20 | DECLARE_HASHTABLE(insn_hash, 20); | |
1e7e4788 | 21 | struct list_head static_call_list; |
d37c90d4 MH |
22 | bool ignore_unreachables, c_file, hints, rodata; |
23 | }; | |
24 | ||
6545eb03 JT |
25 | struct objtool_file *objtool_open_read(const char *_objname); |
26 | ||
d44becb9 | 27 | int check(struct objtool_file *file); |
0decf1f8 MH |
28 | int orc_dump(const char *objname); |
29 | int create_orc(struct objtool_file *file); | |
30 | int create_orc_sections(struct objtool_file *file); | |
31 | ||
d37c90d4 | 32 | #endif /* _OBJTOOL_H */ |