summaryrefslogtreecommitdiff
path: root/docs/Linking_overview.md
diff options
context:
space:
mode:
authorKevin O'Connor <kevin@koconnor.net>2015-10-09 11:53:02 -0400
committerKevin O'Connor <kevin@koconnor.net>2015-10-15 14:15:19 -0400
commitb4cca861a2f813a3826afe33d548cd6b1a5bd705 (patch)
tree82bde56843c7d4e940c8e9a94350cab2b99963d5 /docs/Linking_overview.md
parenta1b4dd09d73d34308435ce6e77c986e6e25ee737 (diff)
downloadqemu-seabios-b4cca861a2f813a3826afe33d548cd6b1a5bd705.tar.gz
stacks: Use macro wrappers for call32() and stack_hop_back()
The C code only uses _cfuncX_ prefixes for parameters to the call32(), stack_hop_back(), and call32_params() functions. It's simpler to use macro wrappers around those functions which provide the required prefix. This also changes the parameter order of stack_hop() and stack_hop_back() to use the more natural (func, params) ordering. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'docs/Linking_overview.md')
-rw-r--r--docs/Linking_overview.md14
1 files changed, 3 insertions, 11 deletions
diff --git a/docs/Linking_overview.md b/docs/Linking_overview.md
index 965e926..bcb8298 100644
--- a/docs/Linking_overview.md
+++ b/docs/Linking_overview.md
@@ -92,17 +92,9 @@ those situations where an address of a C function in another mode is
required the build supports symbols with a special "\_cfuncX_"
prefix. The layoutrom.py script detects these references and will emit
a corresponding symbol definitions in the linker script that points to
-the C code of the specified mode. This is typically seen with code
-like:
-
-```
-extern void _cfunc32flat_process_op(void);
-return call32(_cfunc32flat_process_op, 0, 0);
-```
-
-In the above example, when the build finds the symbol
-"\_cfunc32flat_process_op" it will emit that symbol with the physical
-address of the 32bit "flat" version of the process_op() C function.
+the C code of the specified mode. The call32() and stack_hop_back()
+macros automatically add the required prefix for C code, but the
+prefixes need to be explicitly added in assembler code.
Build garbage collection
------------------------