summaryrefslogtreecommitdiff
path: root/api_examples/glue.h
diff options
context:
space:
mode:
authorRafal Jaworowski <raj@semihalf.com>2009-01-23 13:27:15 +0100
committerWolfgang Denk <wd@denx.de>2009-02-18 00:39:34 +0100
commitb84d7d8f1e1066f810866304a16a3583f88e7c98 (patch)
tree78ce8c7adbc218545cd2d94185c54a593767fc58 /api_examples/glue.h
parent86b4bafdfaf669ede8fd99044abc7e27ea29b4f5 (diff)
downloadu-boot-imx-b84d7d8f1e1066f810866304a16a3583f88e7c98.zip
u-boot-imx-b84d7d8f1e1066f810866304a16a3583f88e7c98.tar.gz
u-boot-imx-b84d7d8f1e1066f810866304a16a3583f88e7c98.tar.bz2
API: Use stack pointer as API signature search hint in the glue layer.
De-hardcode range in RAM we search for the API signature. Instead use the stack pointer as a hint to narrow down the range in which the signature could reside (it is malloc'ed on the U-Boot heap, and is hoped to remain in some proximity from stack area). Adjust PowerPC code in API demo to the new scheme. Signed-off-by: Rafal Czubak <rcz@semihalf.com> Signed-off-by: Rafal Jaworowski <raj@semihalf.com>
Diffstat (limited to 'api_examples/glue.h')
-rw-r--r--api_examples/glue.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/api_examples/glue.h b/api_examples/glue.h
index a82f783..0adb8b3 100644
--- a/api_examples/glue.h
+++ b/api_examples/glue.h
@@ -30,12 +30,12 @@
#ifndef _API_GLUE_H_
#define _API_GLUE_H_
-#define API_SEARCH_START (255 * 1024 * 1024) /* start at 1MB below top RAM */
-#define API_SEARCH_END (256 * 1024 * 1024 - 1) /* ...and search to the end */
+#define API_SEARCH_LEN (3 * 1024 * 1024) /* 3MB search range */
-int syscall(int, int *, ...);
-void * syscall_ptr;
+extern void *syscall_ptr;
+extern uint32_t search_hint;
+int syscall(int, int *, ...);
int api_search_sig(struct api_signature **sig);
/*