diff options
Diffstat (limited to 'sys/arch/mvme68k/stand/bugcrt/bugcrtS.S')
-rw-r--r-- | sys/arch/mvme68k/stand/bugcrt/bugcrtS.S | 57 |
1 files changed, 29 insertions, 28 deletions
diff --git a/sys/arch/mvme68k/stand/bugcrt/bugcrtS.S b/sys/arch/mvme68k/stand/bugcrt/bugcrtS.S index f460f97386d..09cd41a69bc 100644 --- a/sys/arch/mvme68k/stand/bugcrt/bugcrtS.S +++ b/sys/arch/mvme68k/stand/bugcrt/bugcrtS.S @@ -1,4 +1,4 @@ -/* $OpenBSD: bugcrtS.S,v 1.1 2012/12/31 21:35:32 miod Exp $ */ +/* $OpenBSD: bugcrtS.S,v 1.2 2013/02/02 13:36:06 miod Exp $ */ /* * Copyright (c) 2012 Miodrag Vallat. @@ -21,11 +21,12 @@ .text +GLOBAL(__bootxx_start) ASLOCAL(__stack_end) .long _ASM_LABEL(__stack_end) | sp - .long _C_LABEL(start) | pc + .long _C_LABEL(__start) | pc -ENTRY(start) +ENTRY(__start) /* * On entry, d0-d1, d4, a0-a6 contain the BUG incoming parameters. */ @@ -33,21 +34,21 @@ ENTRY(start) * Set up stack. This is already done if booted by the BUG, but not * if invoked from an old bootxx' bugexec(). */ - leal _ASM_LABEL(__stack_end):l, sp + leal _ASM_LABEL(__stack_end):l, %sp /* * Push arguments on stack. */ - movl MVMEPROM_REG_NBARGEND, sp@- - movl MVMEPROM_REG_NBARGSTART, sp@- - movl MVMEPROM_REG_ARGEND, sp@- - movl MVMEPROM_REG_ARGSTART, sp@- - movl MVMEPROM_REG_CONFBLK, sp@- - movl MVMEPROM_REG_ENTRY, sp@- - movl MVMEPROM_REG_CTRLADDR, sp@- - movl MVMEPROM_REG_FLAGS, sp@- - movl MVMEPROM_REG_CTRLLUN, sp@- - movl MVMEPROM_REG_DEVLUN, sp@- + movl MVMEPROM_REG_NBARGEND, %sp@- + movl MVMEPROM_REG_NBARGSTART, %sp@- + movl MVMEPROM_REG_ARGEND, %sp@- + movl MVMEPROM_REG_ARGSTART, %sp@- + movl MVMEPROM_REG_CONFBLK, %sp@- + movl MVMEPROM_REG_ENTRY, %sp@- + movl MVMEPROM_REG_CTRLADDR, %sp@- + movl MVMEPROM_REG_FLAGS, %sp@- + movl MVMEPROM_REG_CTRLLUN, %sp@- + movl MVMEPROM_REG_DEVLUN, %sp@- /* * Invoke the rest of the startup as C code. @@ -61,32 +62,32 @@ ENTRY(bugexec_final) /* * Pop arguments to the appropriate registers. */ - movl sp@(4 * 1), MVMEPROM_REG_DEVLUN - movl sp@(4 * 2), MVMEPROM_REG_CTRLLUN - movl sp@(4 * 3), MVMEPROM_REG_FLAGS - movl sp@(4 * 4), MVMEPROM_REG_CTRLADDR - movl sp@(4 * 5), MVMEPROM_REG_ENTRY - movl sp@(4 * 6), MVMEPROM_REG_CONFBLK - movl sp@(4 * 7), MVMEPROM_REG_ARGSTART - movl sp@(4 * 8), MVMEPROM_REG_ARGEND - movl sp@(4 * 9), MVMEPROM_REG_NBARGSTART - movl sp@(4 * 10), MVMEPROM_REG_NBARGEND + movl %sp@(4 * 1), MVMEPROM_REG_DEVLUN + movl %sp@(4 * 2), MVMEPROM_REG_CTRLLUN + movl %sp@(4 * 3), MVMEPROM_REG_FLAGS + movl %sp@(4 * 4), MVMEPROM_REG_CTRLADDR + movl %sp@(4 * 5), MVMEPROM_REG_ENTRY + movl %sp@(4 * 6), MVMEPROM_REG_CONFBLK + movl %sp@(4 * 7), MVMEPROM_REG_ARGSTART + movl %sp@(4 * 8), MVMEPROM_REG_ARGEND + movl %sp@(4 * 9), MVMEPROM_REG_NBARGSTART + movl %sp@(4 * 10), MVMEPROM_REG_NBARGEND /* * Pop return address */ - movl sp@(4 * 11), d2 + movl %sp@(4 * 11), %d2 /* * Pop stack address */ - movl sp@(4 * 12), sp + movl %sp@(4 * 12), %sp /* * Push return address */ - movl _ASM_LABEL(bugexec_returned), sp@- - movl d2, sp@- + movl _ASM_LABEL(bugexec_returned), %sp@- + movl %d2, %sp@- rts ASLOCAL(bugexec_returned) |