• Home
  • Raw
  • Download

Lines Matching refs:state

12 unsigned long unwind_get_return_address(struct unwind_state *state)  in unwind_get_return_address()  argument
14 if (unwind_done(state)) in unwind_get_return_address()
16 return __kernel_text_address(state->ip) ? state->ip : 0; in unwind_get_return_address()
20 static bool outside_of_stack(struct unwind_state *state, unsigned long sp) in outside_of_stack() argument
22 return (sp <= state->sp) || in outside_of_stack()
23 (sp > state->stack_info.end - sizeof(struct stack_frame)); in outside_of_stack()
26 static bool update_stack_info(struct unwind_state *state, unsigned long sp) in update_stack_info() argument
28 struct stack_info *info = &state->stack_info; in update_stack_info()
29 unsigned long *mask = &state->stack_mask; in update_stack_info()
32 if (get_stack_info(sp, state->task, info, mask) != 0 || in update_stack_info()
39 bool unwind_next_frame(struct unwind_state *state) in unwind_next_frame() argument
41 struct stack_info *info = &state->stack_info; in unwind_next_frame()
47 regs = state->regs; in unwind_next_frame()
49 if (state->reuse_sp) { in unwind_next_frame()
50 sp = state->sp; in unwind_next_frame()
51 state->reuse_sp = false; in unwind_next_frame()
54 if (unlikely(outside_of_stack(state, sp))) { in unwind_next_frame()
55 if (!update_stack_info(state, sp)) in unwind_next_frame()
65 state->regs = NULL; in unwind_next_frame()
66 return unwind_next_frame(state); in unwind_next_frame()
69 sf = (struct stack_frame *) state->sp; in unwind_next_frame()
73 if (unlikely(outside_of_stack(state, sp))) { in unwind_next_frame()
74 if (!update_stack_info(state, sp)) in unwind_next_frame()
82 sp = state->sp + STACK_FRAME_OVERHEAD; in unwind_next_frame()
96 ip = ftrace_graph_ret_addr(state->task, &state->graph_idx, in unwind_next_frame()
101 state->sp = sp; in unwind_next_frame()
102 state->ip = ip; in unwind_next_frame()
103 state->regs = regs; in unwind_next_frame()
104 state->reliable = reliable; in unwind_next_frame()
108 state->error = true; in unwind_next_frame()
110 state->stack_info.type = STACK_TYPE_UNKNOWN; in unwind_next_frame()
115 void __unwind_start(struct unwind_state *state, struct task_struct *task, in __unwind_start() argument
118 struct stack_info *info = &state->stack_info; in __unwind_start()
119 unsigned long *mask = &state->stack_mask; in __unwind_start()
124 memset(state, 0, sizeof(*state)); in __unwind_start()
125 state->task = task; in __unwind_start()
126 state->regs = regs; in __unwind_start()
139 state->error = true; in __unwind_start()
158 ip = ftrace_graph_ret_addr(state->task, &state->graph_idx, in __unwind_start()
163 state->sp = sp; in __unwind_start()
164 state->ip = ip; in __unwind_start()
165 state->reliable = reliable; in __unwind_start()
166 state->reuse_sp = reuse_sp; in __unwind_start()