ftrace.h (ac7127e1cc65aeb578998c992a05dbc80fa18f0f) | ftrace.h (a51ac5246d2505b58229242959d2bc73d113ca50) |
---|---|
1/* SPDX-License-Identifier: GPL-2.0 */ 2/* 3 * Copyright (C) 2022 Loongson Technology Corporation Limited 4 */ 5 6#ifndef _ASM_LOONGARCH_FTRACE_H 7#define _ASM_LOONGARCH_FTRACE_H 8 | 1/* SPDX-License-Identifier: GPL-2.0 */ 2/* 3 * Copyright (C) 2022 Loongson Technology Corporation Limited 4 */ 5 6#ifndef _ASM_LOONGARCH_FTRACE_H 7#define _ASM_LOONGARCH_FTRACE_H 8 |
9#define GRAPH_FAKE_OFFSET (sizeof(struct pt_regs) - offsetof(struct pt_regs, regs[1])) 10 |
|
9#ifdef CONFIG_FUNCTION_TRACER 10 11#define MCOUNT_INSN_SIZE 4 /* sizeof mcount call */ 12 13#ifndef __ASSEMBLY__ 14 15#ifndef CONFIG_DYNAMIC_FTRACE 16 17#define mcount _mcount 18extern void _mcount(void); 19extern void prepare_ftrace_return(unsigned long self_addr, unsigned long callsite_sp, unsigned long old); 20 21#else 22 23struct dyn_ftrace; 24struct dyn_arch_ftrace { }; 25 26#define ARCH_SUPPORTS_FTRACE_OPS 1 | 11#ifdef CONFIG_FUNCTION_TRACER 12 13#define MCOUNT_INSN_SIZE 4 /* sizeof mcount call */ 14 15#ifndef __ASSEMBLY__ 16 17#ifndef CONFIG_DYNAMIC_FTRACE 18 19#define mcount _mcount 20extern void _mcount(void); 21extern void prepare_ftrace_return(unsigned long self_addr, unsigned long callsite_sp, unsigned long old); 22 23#else 24 25struct dyn_ftrace; 26struct dyn_arch_ftrace { }; 27 28#define ARCH_SUPPORTS_FTRACE_OPS 1 |
29#define HAVE_FUNCTION_GRAPH_RET_ADDR_PTR |
|
27 28#define ftrace_init_nop ftrace_init_nop 29int ftrace_init_nop(struct module *mod, struct dyn_ftrace *rec); 30 31static inline unsigned long ftrace_call_adjust(unsigned long addr) 32{ 33 return addr; 34} --- 27 unchanged lines hidden --- | 30 31#define ftrace_init_nop ftrace_init_nop 32int ftrace_init_nop(struct module *mod, struct dyn_ftrace *rec); 33 34static inline unsigned long ftrace_call_adjust(unsigned long addr) 35{ 36 return addr; 37} --- 27 unchanged lines hidden --- |