summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDale S. Rahn <rahnds@cvs.openbsd.org>1997-02-06 23:44:57 +0000
committerDale S. Rahn <rahnds@cvs.openbsd.org>1997-02-06 23:44:57 +0000
commitc543e78d580e70c8e906d10beb85c20c6fe6412e (patch)
treea8d418bb93cfd3c943acda0f8c29436a829195ba
parentdc706f1f441dbdaa5214115bbe398f1fdb59e9c3 (diff)
Add zlib support for booting gzipped kernels.
Clean up to allow this to happen.
-rw-r--r--sys/arch/powerpc/stand/Locore.c7
-rw-r--r--sys/arch/powerpc/stand/Makefile9
-rw-r--r--sys/arch/powerpc/stand/alloc.c4
-rw-r--r--sys/arch/powerpc/stand/boot.c4
4 files changed, 13 insertions, 11 deletions
diff --git a/sys/arch/powerpc/stand/Locore.c b/sys/arch/powerpc/stand/Locore.c
index 5400658f594..9992209d0f5 100644
--- a/sys/arch/powerpc/stand/Locore.c
+++ b/sys/arch/powerpc/stand/Locore.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: Locore.c,v 1.2 1996/12/28 06:31:06 rahnds Exp $ */
+/* $OpenBSD: Locore.c,v 1.3 1997/02/06 23:44:54 rahnds Exp $ */
/* $NetBSD: Locore.c,v 1.1 1996/09/30 16:34:58 ws Exp $ */
/*
@@ -34,7 +34,9 @@
#include <stand.h>
#include <openfirm.h>
+/*
#include <machine/cpu.h>
+*/
static int (*openfirmware)(void *);
@@ -53,9 +55,6 @@ _start(vpd, res, openfirm, arg, argl)
{
extern char etext;
-#ifdef FIREPOWERBUGS
- syncicache((void *)RELOC, &etext - (char *)RELOC);
-#endif
openfirmware = openfirm; /* Save entry to Open Firmware */
setup();
main(arg, argl);
diff --git a/sys/arch/powerpc/stand/Makefile b/sys/arch/powerpc/stand/Makefile
index 7c3f70bed88..8d1b8d6b7b3 100644
--- a/sys/arch/powerpc/stand/Makefile
+++ b/sys/arch/powerpc/stand/Makefile
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile,v 1.3 1997/01/09 05:21:27 rahnds Exp $
+# $OpenBSD: Makefile,v 1.4 1997/02/06 23:44:55 rahnds Exp $
# $NetBSD: Makefile,v 1.1 1996/09/30 16:34:59 ws Exp $
SUBDIR= boot
@@ -6,15 +6,18 @@ SUBDIR= boot
SAREL=
KERNREL=
KERN_AS=library
+Z_AS=library
+SA_ZLIB=smth
.include "Makefile.inc"
+.include "$S/lib/libz/Makefile.inc"
.include "$S/lib/libsa/Makefile.inc"
.include "$S/lib/libkern/Makefile.inc"
-all: ${SALIB} ${KERNLIB} _SUBDIRUSE
+all: ${ZLIB} ${SALIB} ${KERNLIB} _SUBDIRUSE
libdep:
- @echo ${.OBJDIR}/${SALIB} $(KERNLIB)
+ @echo ${.OBJDIR}/${SALIB} $(KERNLIB) ${ZLIB}
${PROG}:
diff --git a/sys/arch/powerpc/stand/alloc.c b/sys/arch/powerpc/stand/alloc.c
index 65dbf7c6637..be3051c217b 100644
--- a/sys/arch/powerpc/stand/alloc.c
+++ b/sys/arch/powerpc/stand/alloc.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: alloc.c,v 1.3 1997/01/09 05:21:28 rahnds Exp $ */
+/* $OpenBSD: alloc.c,v 1.4 1997/02/06 23:44:55 rahnds Exp $ */
/* $NetBSD: alloc.c,v 1.1 1996/09/30 16:35:00 ws Exp $ */
/*
@@ -92,10 +92,12 @@ free(ptr, size)
{
struct ml *f = (struct ml *)(ptr - ALIGN(sizeof(struct ml)));
+#if IGNORE_FOR_NOW
if (f->size != roundup(ALIGN(size) + ALIGN(sizeof(struct ml)), NBPG))
panic("free: wrong size (%x != %x)",
f->size,
roundup(ALIGN(size) + ALIGN(sizeof(struct ml)), NBPG));
+#endif
f->next = fl;
fl = f;
}
diff --git a/sys/arch/powerpc/stand/boot.c b/sys/arch/powerpc/stand/boot.c
index 818b98eb63e..c4d2e085589 100644
--- a/sys/arch/powerpc/stand/boot.c
+++ b/sys/arch/powerpc/stand/boot.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: boot.c,v 1.3 1997/01/09 03:52:51 rahnds Exp $ */
+/* $OpenBSD: boot.c,v 1.4 1997/02/06 23:44:56 rahnds Exp $ */
/* $NetBSD: boot.c,v 1.2 1996/10/07 21:43:02 cgd Exp $ */
/*
@@ -44,7 +44,6 @@
#include <sys/disklabel.h>
#include <sys/exec_elf.h>
-#include <machine/cpu.h>
#include "ofdev.h"
#include "openfirm.h"
@@ -211,7 +210,6 @@ loadfile(fd, addr, args)
}
#endif
close(fd);
- syncicache(addr, exec_addr);
if (floppyboot) {
printf("Please insert root disk and press ENTER ");
getchar();