Skip to content

Commit

Permalink
sh: dynamic ftrace support.
Browse files Browse the repository at this point in the history
First cut at dynamic ftrace support.

[
  Steven Rostedt - only updated the recordmcount.pl file.
    There are updates for PowerPC that will conflict with this,
    and we need to base off of these changes.
]

Signed-off-by: Matt Fleming <mjf@gentoo.org>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
  • Loading branch information
Matt Fleming authored and Ingo Molnar committed Nov 23, 2008
1 parent a0a70c7 commit 0da85c0
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions scripts/recordmcount.pl
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,17 @@
$objcopy .= " -O elf32-i386";
$cc .= " -m32";

} elsif ($arch eq "sh") {
$section_regex = "Disassembly of section\\s+(\\S+):";
$function_regex = "^([0-9a-fA-F]+)\\s+<(.*?)>:";
$mcount_regex = "^\\s*([0-9a-fA-F]+):.*\\smcount\$";
$type = ".long";

# force flags for this arch
$ld .= " -m shlelf_linux";
$objcopy .= " -O elf32-sh-linux";
$cc .= " -m32";

} else {
die "Arch $arch is not supported with CONFIG_FTRACE_MCOUNT_RECORD";
}
Expand Down

0 comments on commit 0da85c0

Please sign in to comment.