summaryrefslogtreecommitdiffstats
path: root/tools/lib/symbol/kallsyms.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/lib/symbol/kallsyms.c')
-rw-r--r--tools/lib/symbol/kallsyms.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/lib/symbol/kallsyms.c b/tools/lib/symbol/kallsyms.c
index 18bc271a4bbc..5e431077fcd6 100644
--- a/tools/lib/symbol/kallsyms.c
+++ b/tools/lib/symbol/kallsyms.c
@@ -2,6 +2,12 @@
#include <stdio.h>
#include <stdlib.h>
+u8 kallsyms2elf_type(char type)
+{
+ type = tolower(type);
+ return (type == 't' || type == 'w') ? STT_FUNC : STT_OBJECT;
+}
+
int kallsyms__parse(const char *filename, void *arg,
int (*process_symbol)(void *arg, const char *name,
char type, u64 start))
OpenPOWER on IntegriCloud