aboutsummaryrefslogtreecommitdiff
path: root/sys/sys/linker.h
diff options
context:
space:
mode:
authorJohn Birrell <jb@FreeBSD.org>2007-11-18 00:23:31 +0000
committerJohn Birrell <jb@FreeBSD.org>2007-11-18 00:23:31 +0000
commitf6c153016281166734ed871b98aac47c2011515f (patch)
tree55bd23df13e645c28c563525f2433dd5ff2447ea /sys/sys/linker.h
parentdd43ab7d9b9e8d13ea9ec9652208635637c10ae6 (diff)
downloadsrc-f6c153016281166734ed871b98aac47c2011515f.tar.gz
src-f6c153016281166734ed871b98aac47c2011515f.zip
Add a function to list symbols in a file and their values at the
same time rather than having to list the symbols and then go back and look each one up by name.
Notes
Notes: svn path=/head/; revision=173714
Diffstat (limited to 'sys/sys/linker.h')
-rw-r--r--sys/sys/linker.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/sys/sys/linker.h b/sys/sys/linker.h
index 83774e66b7f7..f9ce2a42a307 100644
--- a/sys/sys/linker.h
+++ b/sys/sys/linker.h
@@ -59,6 +59,8 @@ typedef struct linker_symval {
size_t size;
} linker_symval_t;
+typedef int (*linker_function_nameval_callback_t)(linker_file_t, linker_symval_t *, void *);
+
struct common_symbol {
STAILQ_ENTRY(common_symbol) link;
char* name;
@@ -154,6 +156,12 @@ int linker_file_lookup_set(linker_file_t _file, const char *_name,
void *_start, void *_stop, int *_count);
/*
+ * List all functions in a file.
+ */
+int linker_file_function_listall(linker_file_t, int (*)(linker_file_t,
+ linker_symval_t *, void *), void *);
+
+/*
* Functions soley for use by the linker class handlers.
*/
int linker_add_class(linker_class_t _cls);