amiga_boottest

annotate src/boot/boot.s @ 2:58ebd84822e7

it works
author John Tsiombikas <nuclear@member.fsf.org>
date Thu, 22 Feb 2018 12:44:20 +0200
parents 48093e4bd99a
children
rev   line source
nuclear@0 1 | vi:filetype=gas68k:
nuclear@0 2 .equ CMD_READ, 2
nuclear@2 3 .equ EXEC_DO_IO, -0x1c8
nuclear@2 4 .equ LOADADDR, 0x10000
nuclear@0 5
nuclear@2 6 start:
nuclear@0 7 | starting with trackdisk device I/O request pointer in a1
nuclear@1 8 | load the program at 0x100 and jump there
nuclear@1 9 | program length is patched by mk_adf just before start
nuclear@2 10 move.l -6(%pc), %d0 | get program size
nuclear@2 11 move.w #0x080, 0xdff180
nuclear@1 12 move.l %d0, 0x24(%a1) | I/O length
nuclear@2 13 move.l #LOADADDR, 0x28(%a1) | I/O data pointer
nuclear@0 14 move.l #512, 0x2c(%a1) | I/O offset (skip first sector)
nuclear@0 15 move.w #CMD_READ, 0x1c(%a1) | I/O command
nuclear@0 16 jsr EXEC_DO_IO(%a6)
nuclear@2 17 move.w #0xf0f, 0xdff180
nuclear@0 18
nuclear@2 19 jmp LOADADDR
nuclear@0 20 .align 4