Take care of the case that <start_of_video> < <memtop>

This commit is contained in:
leo 1996-03-18 21:06:19 +00:00
parent 4973a32e6d
commit d36f15a208
4 changed files with 31 additions and 12 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: xxboot.ahdi.s,v 1.1.1.1 1996/02/29 11:36:51 leo Exp $ */
/* $NetBSD: xxboot.ahdi.s,v 1.2 1996/03/18 21:06:19 leo Exp $ */
/*
* Copyright (c) 1995 Waldi Ravens.
@ -80,7 +80,11 @@ main: movml d3-d7/a3-a5,sp@-
lea pc@(m_top),a6
movl _memtop:w,d3
cmpl #MINTOP,d3
movl _v_bas_ad:w,d0
cmpl d0,d3
blts 0f | memtop < v_bas_ad
movl d0,d3
0: cmpl #MINTOP,d3
blts exit | memtop < MINTOP
andw #-4,d3
@ -195,6 +199,6 @@ m_key: .asciz "\007\r\npress any key... @\r\n"
regsav: .long 0
fill: .space 54 | 510-(fill-start)
fill: .space 44 | 510-(fill-start)
.word 0 | checksum
end:

View File

@ -1,4 +1,4 @@
/* $NetBSD: fdboot.s,v 1.1.1.1 1996/02/29 11:36:52 leo Exp $ */
/* $NetBSD: fdboot.s,v 1.2 1996/03/18 21:06:35 leo Exp $ */
/*
* Copyright (c) 1995 Waldi Ravens.
@ -58,15 +58,22 @@ start: bras main
* ROM loader does not save any register!
*/
main: movml d1-d7/a0-a6,sp@-
lea pc@(m_bot),a3
movl _membot:w,d3
lea MAXBOT,a6
cmpl a6,d3
bhis exit | membot > MAXBOT
lea pc@(m_top),a3
movl _memtop:w,d3
cmpl #MINTOP,d3
movl _v_bas_ad:w,d0
cmpl d0,d3
blts 0f | memtop < v_bas_ad
movl d0,d3
0: cmpl #MINTOP,d3
blts exit | memtop < MINTOP
andw #-4,d3
movl d3,a0
movl sp,a0@-
@ -215,6 +222,6 @@ m_sbl: .asciz "fdboot: bootxx => 0x#\r\n"
m_rds: .asciz "fdboot: Floprd => 0x#\r\n"
m_key: .asciz "\007\r\npress any key... @\r\n"
fill: .space 22 | 510-(fill-start)
fill: .space 12 | 510-(fill-start)
.word 0 | checksum
end:

View File

@ -1,4 +1,4 @@
/* $NetBSD: sdboot.s,v 1.1.1.1 1996/02/29 11:36:53 leo Exp $ */
/* $NetBSD: sdboot.s,v 1.2 1996/03/18 21:06:37 leo Exp $ */
/*
* Copyright (c) 1995 Waldi Ravens
@ -69,7 +69,11 @@ main: lea pc@(regsav),a0
bhis exit | membot > MAXBOT
movl _memtop:w,d0
cmpl #MINTOP,d0
movl _v_bas_ad:w,d1
cmpl d1,d0
blts 0f | memtop < v_bas_ad
movl d1,d0
0: cmpl #MINTOP,d0
blts exit | memtop < MINTOP
andw #-4,d0
@ -200,7 +204,7 @@ r0com: .long 0x0000008a
regsav: .long 0
fill: .space 24
fill: .space 14
.ascii "NetBSD"
hd_siz: .long 0

View File

@ -1,4 +1,4 @@
/* $NetBSD: wdboot.s,v 1.1.1.1 1996/02/29 11:36:53 leo Exp $ */
/* $NetBSD: wdboot.s,v 1.2 1996/03/18 21:06:39 leo Exp $ */
/*
* Copyright (c) 1995 Waldi Ravens
@ -64,7 +64,11 @@ main: lea pc@(regsav),a0
bhis exit | membot > MAXBOT
movl _memtop:w,d3
cmpl #MINTOP,d3
movl _v_bas_ad:w,d0
cmpl d0,d3
blts 0f | memtop < v_bas_ad
movl d0,d3
0: cmpl #MINTOP,d3
blts exit | memtop < MINTOP
andw #-4,d3
@ -188,7 +192,7 @@ err: movq #-1,d0
regsav: .long 0
fill: .space 34
fill: .space 24
dpar: .byte 0 | tracks/cylinder
.byte 0 | sectors/track