Contributors: 9
Author |
Tokens |
Token Proportion |
Commits |
Commit Proportion |
Sami Tolvanen |
120 |
75.95% |
2 |
18.18% |
Jeremy Fitzhardinge |
11 |
6.96% |
1 |
9.09% |
Masami Hiramatsu |
9 |
5.70% |
1 |
9.09% |
Kai Germaschewski |
6 |
3.80% |
1 |
9.09% |
Linus Torvalds (pre-git) |
6 |
3.80% |
2 |
18.18% |
Peter Zijlstra |
2 |
1.27% |
1 |
9.09% |
Aaron Tomlin |
2 |
1.27% |
1 |
9.09% |
Andrew Morton |
1 |
0.63% |
1 |
9.09% |
Greg Kroah-Hartman |
1 |
0.63% |
1 |
9.09% |
Total |
158 |
|
11 |
|
/* SPDX-License-Identifier: GPL-2.0 */
/*
* Clang Control Flow Integrity (CFI) support.
*
* Copyright (C) 2022 Google LLC
*/
#ifndef _LINUX_CFI_H
#define _LINUX_CFI_H
#include <linux/bug.h>
#include <linux/module.h>
#ifdef CONFIG_CFI_CLANG
enum bug_trap_type report_cfi_failure(struct pt_regs *regs, unsigned long addr,
unsigned long *target, u32 type);
static inline enum bug_trap_type report_cfi_failure_noaddr(struct pt_regs *regs,
unsigned long addr)
{
return report_cfi_failure(regs, addr, NULL, 0);
}
#endif /* CONFIG_CFI_CLANG */
#ifdef CONFIG_ARCH_USES_CFI_TRAPS
bool is_cfi_trap(unsigned long addr);
#else
static inline bool is_cfi_trap(unsigned long addr) { return false; }
#endif
#ifdef CONFIG_MODULES
#ifdef CONFIG_ARCH_USES_CFI_TRAPS
void module_cfi_finalize(const Elf_Ehdr *hdr, const Elf_Shdr *sechdrs,
struct module *mod);
#else
static inline void module_cfi_finalize(const Elf_Ehdr *hdr,
const Elf_Shdr *sechdrs,
struct module *mod) {}
#endif /* CONFIG_ARCH_USES_CFI_TRAPS */
#endif /* CONFIG_MODULES */
#endif /* _LINUX_CFI_H */