Subject: port-next68k/8962: boot fails on machines which do not have 32M of memory
To: None <gnats-bugs@gnats.netbsd.org>
From: None <chris@nice.ch>
List: netbsd-bugs
Date: 12/06/1999 11:27:38
>Number: 8962
>Category: port-next68k
>Synopsis: boot fails on machines which do not have 32M of memory
>Confidential: no
>Severity: critical
>Priority: high
>Responsible: port-next68k-maintainer (NetBSD/next68k Portmaster)
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Mon Dec 6 11:27:00 1999
>Last-Modified:
>Originator: Christian Limpach
>Organization:
>Release: 1.4.1
>Environment:
NetBSD arkin.pin.lu 1.4.1 NetBSD 1.4.1 (ARKIN) #0: Fri Oct 22 16:39:49 CEST 1999
root@arkin.pin.lu:/mnt/devel/netbsd/src-1.4.1/sys/arch/next68k/compile/ARKIN next68k
>Description:
machines which do not have 32M of memory fail to boot while the rom-monitor is still used to output messages.
>How-To-Repeat:
boot on a machine with 16M
>Fix:
Here's a patch to fix this. Copying the next-rom-image into the kernel failed because it assumed a wrong absolute address for the rom-image on machines which don't have 32M
The patch is also available at http://www.nice.ch/~chris/netbsd/next16M.patch in case the send-pr form messes it up...
Index: nextrom.c
===================================================================
RCS file: /cvs/netbsd/current/src/sys/arch/next68k/next68k/nextrom.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- nextrom.c 1999/10/24 22:14:40 1.1
+++ nextrom.c 1999/12/06 14:07:10 1.2
@@ -106,6 +106,7 @@
u_char *rom_return_sp;
u_int rom_mon_stack;
u_char rom_image[0x2000];
+vm_offset_t rom_image_base;
u_int rom_vbr;;
paddr_t rom_reboot_vect;
@@ -211,6 +212,7 @@
* top of memory
*/
RELOC(phys_seg_list[j-1].ps_end, vm_offset_t) -= 0x2000;
+ RELOC(rom_image_base, vm_offset_t) = RELOC(phys_seg_list[j-1].ps_end, vm_offset_t);
/* pmap is unhappy if it is not null terminated */
for(;j<MAX_PHYS_SEGS;j++) {
@@ -288,7 +290,7 @@
RELOC(rom_reboot_vect, paddr_t) = MONRELOC(paddr_t *, MG_vbr)[45]; /* trap #13 */
for(i=0;i<sizeof(rom_image);i++) {
- RELOC(rom_image[i], u_char) = *(u_char *)(0x6000000-0x2000+i);
+ RELOC(rom_image[i], u_char) = *(u_char *)(RELOC(rom_image_base, vm_offset_t) + i);
}
}
>Audit-Trail:
>Unformatted: