Skip to content

Commit a470b95

Browse files
committed
sh: Fix up ftrace build error when STACK_DEBUG=n.
Presently the closest reference to function_trace_stop is within a CONFIG_STACK_DEBUG block. When this is turned off, the build bails out with a pcrel too far error. Reorder things a bit to handle the various combinations. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
1 parent fe27932 commit a470b95

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

‎arch/sh/lib/mcount.S‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -192,14 +192,17 @@ ftrace_call:
192192
#endif /* CONFIG_FUNCTION_GRAPH_TRACER */
193193
#endif /* CONFIG_DYNAMIC_FTRACE */
194194

195+
.align 2
196+
.Lfunction_trace_stop:
197+
.long function_trace_stop
198+
195199
/*
196200
* NOTE: From here on the locations of the .Lftrace_stub label and
197201
* ftrace_stub itself are fixed. Adding additional data here will skew
198202
* the displacement for the memory table and break the block replacement.
199203
* Place new labels either after the ftrace_stub body, or before
200204
* ftrace_caller. You have been warned.
201205
*/
202-
.align 2
203206
.Lftrace_stub:
204207
.long ftrace_stub
205208

@@ -223,8 +226,6 @@ stack_panic:
223226
nop
224227

225228
.align 2
226-
.Lfunction_trace_stop:
227-
.long function_trace_stop
228229
.L_ebss:
229230
.long _ebss
230231
.L_init_thread_union:

0 commit comments

Comments
 (0)