]> oss.titaniummirror.com Git - msp430-libc.git/blobdiff - src/stdlib/__init_stack.S
Imported msp430-libc-20100207
[msp430-libc.git] / src / stdlib / __init_stack.S
diff --git a/src/stdlib/__init_stack.S b/src/stdlib/__init_stack.S
new file mode 100644 (file)
index 0000000..9a23291
--- /dev/null
@@ -0,0 +1,14 @@
+/*****************************************************************
+ * Set stack pointer
+ * can be overwriten by user function with the same name
+ *****************************************************************/
+        .section .init2, "ax", @progbits
+
+        .weak   __init_stack
+        .func   __init_stack
+
+__init_stack:
+        mov     #__stack, r1    ; stack always located on first 64K, so 430 instruction
+                                ; is acceptable here for 430X core too.
+
+        .endfunc