From fa9d72b1ddc8103c210663f3075af580633c6937 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Revol?= Date: Thu, 3 Jan 2008 00:02:54 +0000 Subject: [PATCH] Test code for stage1... git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23225 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/system/boot/platform/atari_m68k/stage1.S | 23 +++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/src/system/boot/platform/atari_m68k/stage1.S b/src/system/boot/platform/atari_m68k/stage1.S index ecd201dca7..eb477c82dc 100644 --- a/src/system/boot/platform/atari_m68k/stage1.S +++ b/src/system/boot/platform/atari_m68k/stage1.S @@ -15,7 +15,10 @@ * http://www.fortunecity.com/skyscraper/apple/308/html/chap3.htm * http://leonard.oxg.free.fr/articles/multi_atari/multi_atari.html * http://alive.atari.org/alive10/btmania.php + * gas stuff: + * http://www.gnu.org/software/binutils/manual/gas-2.9.1/html_chapter/as_18.html#SEC214 * + * x86: * The offset of the partition in 512 byte blocks must be written at * position PARTITION_OFFSET_OFFSET (32 bit little endian; makebootable does * that) or otherwise the code can't find the partition. @@ -55,13 +58,23 @@ // BIOS calls +#ifndef _ASSEMBLER +#error plop +#endif - - - - +.loop: + move #'.',%d0 + bsr putc + bra .loop rts - +/* prints the char in d0.b to the console */ +putc: + move.w d0,-(%sp) + move.w #2,-(%sp) // DEV_CON + move.w #3,-(%sp) // Bconout + trap #13 + addi #6,%sp + rts