summaryrefslogtreecommitdiff
path: root/sys/arch
diff options
context:
space:
mode:
Diffstat (limited to 'sys/arch')
-rw-r--r--sys/arch/alpha/stand/OSFpal.c4
-rw-r--r--sys/arch/alpha/stand/boot/Makefile6
-rw-r--r--sys/arch/alpha/stand/boot/boot.c3
-rw-r--r--sys/arch/alpha/stand/boot/disk.c3
-rw-r--r--sys/arch/alpha/stand/bootxx.c3
-rw-r--r--sys/arch/alpha/stand/headersize.c14
-rw-r--r--sys/arch/alpha/stand/loadfile.c7
-rw-r--r--sys/arch/alpha/stand/netboot/Makefile6
-rw-r--r--sys/arch/alpha/stand/netboot/getsecs.c4
-rw-r--r--sys/arch/alpha/stand/netboot/if_prom.c4
-rw-r--r--sys/arch/alpha/stand/netboot/netboot.c3
-rw-r--r--sys/arch/alpha/stand/prom.c4
12 files changed, 38 insertions, 23 deletions
diff --git a/sys/arch/alpha/stand/OSFpal.c b/sys/arch/alpha/stand/OSFpal.c
index 0bf89c96fd0..5a69e70d125 100644
--- a/sys/arch/alpha/stand/OSFpal.c
+++ b/sys/arch/alpha/stand/OSFpal.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: OSFpal.c,v 1.4 1996/10/30 22:40:27 niklas Exp $ */
+/* $OpenBSD: OSFpal.c,v 1.5 1996/11/27 19:54:45 niklas Exp $ */
/* $NetBSD: OSFpal.c,v 1.4 1996/10/13 03:00:24 christos Exp $ */
/*
@@ -30,8 +30,8 @@
#include <sys/types.h>
-#include <machine/prom.h>
#include <machine/rpb.h>
+#include <machine/prom.h>
void
OSFpal()
diff --git a/sys/arch/alpha/stand/boot/Makefile b/sys/arch/alpha/stand/boot/Makefile
index bf32ff1073a..6bfa14e729b 100644
--- a/sys/arch/alpha/stand/boot/Makefile
+++ b/sys/arch/alpha/stand/boot/Makefile
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile,v 1.5 1996/10/30 22:40:38 niklas Exp $
+# $OpenBSD: Makefile,v 1.6 1996/11/27 19:54:51 niklas Exp $
# $NetBSD: Makefile,v 1.10 1996/10/18 06:01:41 thorpej Exp $
.PATH: ${.CURDIR}/.. ${.CURDIR}/../../../../lib/libsa
@@ -10,13 +10,13 @@ BOOT_SRCS = start.S boot.c loadfile.c disk.c conf.c prom.c prom_disp.S OSFpal.c
BOOT_SRCS+= alloc.c bzero.c close.c dev.c devopen.c disklabel.c dkcksum.c
BOOT_SRCS+= getfile.c gets.c ioctl.c lseek.c open.c printf.c read.c
-BOOT_SRCS+= strcmp.c ufs.c write.c bcopy.c filesystem.c strlen.c
+BOOT_SRCS+= strcmp.c ufs.c write.c filesystem.c strlen.c
BOOT_SRCS+= ntohl.c prom_swpal.S
BOOT_OBJS = ${BOOT_SRCS:N*.h:R:S/$/.o/g}
HEADERSIZE_PROG = headersize
-DEFNS= -DCOMPAT_UFS -DALPHA_BOOT_ECOFF -DALPHA_BOOT_ELF
+DEFNS= -DCOMPAT_UFS -DALPHA_BOOT_ECOFF # -DALPHA_BOOT_ELF
AFLAGS += -DASSEMBLER ${DEFNS}
CPPFLAGS += -I${.CURDIR}/../.. -I${.CURDIR}/../../../..
diff --git a/sys/arch/alpha/stand/boot/boot.c b/sys/arch/alpha/stand/boot/boot.c
index 706b614c072..2ddaef27e5d 100644
--- a/sys/arch/alpha/stand/boot/boot.c
+++ b/sys/arch/alpha/stand/boot/boot.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: boot.c,v 1.7 1996/11/27 12:07:55 mickey Exp $ */
+/* $OpenBSD: boot.c,v 1.8 1996/11/27 19:54:52 niklas Exp $ */
/* $NetBSD: boot.c,v 1.8 1996/09/17 22:00:26 cgd Exp $ */
/*
@@ -46,6 +46,7 @@
#include <sys/exec.h>
#include <sys/exec_ecoff.h>
+#include <machine/rpb.h>
#include <machine/prom.h>
#define _KERNEL
diff --git a/sys/arch/alpha/stand/boot/disk.c b/sys/arch/alpha/stand/boot/disk.c
index 5b70adf9a61..e29a2b2a116 100644
--- a/sys/arch/alpha/stand/boot/disk.c
+++ b/sys/arch/alpha/stand/boot/disk.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: disk.c,v 1.4 1996/10/30 22:40:42 niklas Exp $ */
+/* $OpenBSD: disk.c,v 1.5 1996/11/27 19:54:52 niklas Exp $ */
/* $NetBSD: disk.c,v 1.3 1995/11/23 02:39:40 cgd Exp $ */
/*
@@ -44,6 +44,7 @@
#include <sys/param.h>
#include <sys/disklabel.h>
+#include <machine/rpb.h>
#include <machine/prom.h>
#include "disk.h"
diff --git a/sys/arch/alpha/stand/bootxx.c b/sys/arch/alpha/stand/bootxx.c
index 6586fff8011..6e10ef53afa 100644
--- a/sys/arch/alpha/stand/bootxx.c
+++ b/sys/arch/alpha/stand/bootxx.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: bootxx.c,v 1.5 1996/10/30 22:40:29 niklas Exp $ */
+/* $OpenBSD: bootxx.c,v 1.6 1996/11/27 19:54:47 niklas Exp $ */
/* $NetBSD: bootxx.c,v 1.3 1996/06/14 20:04:45 cgd Exp $ */
/*
@@ -29,6 +29,7 @@
*/
#include <sys/param.h>
+#include <machine/rpb.h>
#include <machine/prom.h>
#include "bbinfo.h"
diff --git a/sys/arch/alpha/stand/headersize.c b/sys/arch/alpha/stand/headersize.c
index c7e853d5e18..77acda5881e 100644
--- a/sys/arch/alpha/stand/headersize.c
+++ b/sys/arch/alpha/stand/headersize.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: headersize.c,v 1.4 1996/10/30 22:40:30 niklas Exp $ */
+/* $OpenBSD: headersize.c,v 1.5 1996/11/27 19:54:47 niklas Exp $ */
/* $NetBSD: headersize.c,v 1.5 1996/09/23 04:32:59 cgd Exp $ */
/*
@@ -48,7 +48,9 @@ main(argc, argv)
{
char buf[HDR_BUFSIZE], *fname;
struct ecoff_exechdr *ecoffp;
+#ifdef ALPHA_BOOT_ELF
Elf_Ehdr *elfp;
+#endif
int fd;
unsigned long loadaddr;
@@ -64,11 +66,15 @@ main(argc, argv)
if (read(fd, &buf, HDR_BUFSIZE) < HDR_BUFSIZE)
err(1, "%s: read failed", fname);
ecoffp = (struct ecoff_exechdr *)buf;
+#ifdef ALPHA_BOOT_ELF
elfp = (Elf_Ehdr *)buf;
+#endif
if (!ECOFF_BADMAG(ecoffp)) {
printf("%d\n", ECOFF_TXTOFF(ecoffp));
- } else if (memcmp(Elf_e_ident, elfp->e_ident, Elf_e_siz) == 0) {
+ }
+#ifdef ALPHA_BOOT_ELF
+ else if (memcmp(Elf_e_ident, elfp->e_ident, Elf_e_siz) == 0) {
Elf_Phdr phdr;
/* XXX assume the first segment is the one we want */
@@ -78,7 +84,9 @@ main(argc, argv)
err(1, "%s: read phdr failed", fname);
printf("%d\n", phdr.p_offset + (loadaddr - phdr.p_vaddr));
- } else
+ }
+#endif
+ else
errx(1, "%s: bad magic number", fname);
close(fd);
diff --git a/sys/arch/alpha/stand/loadfile.c b/sys/arch/alpha/stand/loadfile.c
index ffe364ffde1..2dcf316f252 100644
--- a/sys/arch/alpha/stand/loadfile.c
+++ b/sys/arch/alpha/stand/loadfile.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: loadfile.c,v 1.1 1996/10/30 22:40:33 niklas Exp $ */
+/* $OpenBSD: loadfile.c,v 1.2 1996/11/27 19:54:48 niklas Exp $ */
/* $NetBSD: loadfile.c,v 1.3 1996/09/23 04:32:44 cgd Exp $ */
/*
@@ -41,14 +41,15 @@
#define ELFSIZE 64
-#include <lib/libsa/stand.h>
#include <lib/libkern/libkern.h>
+#include <lib/libsa/stand.h>
#include <sys/param.h>
#include <sys/exec.h>
#include <sys/exec_ecoff.h>
#include <sys/exec_elf.h>
+#include <machine/rpb.h>
#include <machine/prom.h>
#define _KERNEL
@@ -148,7 +149,7 @@ coff_exec(fd, coff, entryp)
/* Zero out bss. */
if (coff->a.bsize != 0) {
(void)printf("+%lu", coff->a.bsize);
- bzero(coff->a.bss_start, coff->a.bsize);
+ bzero((void *)coff->a.bss_start, coff->a.bsize);
}
ffp_save = coff->a.text_start + coff->a.tsize;
diff --git a/sys/arch/alpha/stand/netboot/Makefile b/sys/arch/alpha/stand/netboot/Makefile
index f83b46d45ac..d05d684b225 100644
--- a/sys/arch/alpha/stand/netboot/Makefile
+++ b/sys/arch/alpha/stand/netboot/Makefile
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile,v 1.1 1996/10/30 22:40:51 niklas Exp $
+# $OpenBSD: Makefile,v 1.2 1996/11/27 19:54:54 niklas Exp $
# $NetBSD: Makefile,v 1.3 1996/10/18 06:02:24 thorpej Exp $
.PATH: ${.CURDIR}/.. ${.CURDIR}/../../../../lib/libsa
@@ -11,7 +11,7 @@ BOOT_SRCS+= printf.c bzero.c rpcc.S
BOOT_SRCS+= dev_net.c conf.c devopen.c
BOOT_SRCS+= nfs.c rpc.c alloc.c ntohl.c htonl.c ntohs.c htons.c net.c bootp.c
-BOOT_SRCS+= strlen.c bcopy.c dev.c bcmp.c strerror.c rarp.c read.c lseek.c
+BOOT_SRCS+= strlen.c dev.c bcmp.c strerror.c rarp.c read.c lseek.c
BOOT_SRCS+= in_cksum.c exit.c closeall.c arp.c strncpy.c globals.c open.c
BOOT_SRCS+= close.c ether.c netif.c
@@ -25,7 +25,7 @@ AFLAGS += -DASSEMBLER
CPPFLAGS += -I${.CURDIR}/../../../../ \
-I${.CURDIR}/../../../../lib/libsa \
-I${.CURDIR}/../.. -DPRIMARY_BOOTBLOCK \
- -DALPHA_BOOT_ECOFF -DALPHA_BOOT_ELF
+ -DALPHA_BOOT_ECOFF # -DALPHA_BOOT_ELF
CFLAGS = -Werror -mno-fp-regs -g
CLEANFILES+= vers.c vers.o
diff --git a/sys/arch/alpha/stand/netboot/getsecs.c b/sys/arch/alpha/stand/netboot/getsecs.c
index 07ca9e539d1..16b8ab95da2 100644
--- a/sys/arch/alpha/stand/netboot/getsecs.c
+++ b/sys/arch/alpha/stand/netboot/getsecs.c
@@ -1,8 +1,8 @@
-/* $OpenBSD: getsecs.c,v 1.1 1996/10/30 22:40:55 niklas Exp $ */
+/* $OpenBSD: getsecs.c,v 1.2 1996/11/27 19:54:55 niklas Exp $ */
#include <sys/param.h>
-#include "include/prom.h"
#include "include/rpb.h"
+#include "include/prom.h"
int
getsecs()
diff --git a/sys/arch/alpha/stand/netboot/if_prom.c b/sys/arch/alpha/stand/netboot/if_prom.c
index 97664bb66ff..b091d49ffff 100644
--- a/sys/arch/alpha/stand/netboot/if_prom.c
+++ b/sys/arch/alpha/stand/netboot/if_prom.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_prom.c,v 1.1 1996/10/30 22:40:56 niklas Exp $ */
+/* $OpenBSD: if_prom.c,v 1.2 1996/11/27 19:54:55 niklas Exp $ */
/* $NetBSD: if_prom.c,v 1.4 1996/10/02 21:18:49 cgd Exp $ */
/*
@@ -39,8 +39,10 @@
#include <netinet/in_systm.h>
#include "netif.h"
+#include "include/rpb.h"
#include "include/prom.h"
#include "lib/libkern/libkern.h"
+#include "lib/libsa/stand.h"
int prom_probe();
int prom_match();
diff --git a/sys/arch/alpha/stand/netboot/netboot.c b/sys/arch/alpha/stand/netboot/netboot.c
index eac243df8e5..9f240bda3ca 100644
--- a/sys/arch/alpha/stand/netboot/netboot.c
+++ b/sys/arch/alpha/stand/netboot/netboot.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: netboot.c,v 1.2 1996/11/27 12:07:55 mickey Exp $ */
+/* $OpenBSD: netboot.c,v 1.3 1996/11/27 19:54:56 niklas Exp $ */
/* $NetBSD: netboot.c,v 1.1 1996/09/18 20:03:12 cgd Exp $ */
/*
@@ -46,6 +46,7 @@
#include <sys/exec.h>
#include <sys/exec_ecoff.h>
+#include <machine/rpb.h>
#include <machine/prom.h>
#define _KERNEL
diff --git a/sys/arch/alpha/stand/prom.c b/sys/arch/alpha/stand/prom.c
index b8e524ee874..86c229945d3 100644
--- a/sys/arch/alpha/stand/prom.c
+++ b/sys/arch/alpha/stand/prom.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: prom.c,v 1.3 1996/10/30 22:40:33 niklas Exp $ */
+/* $OpenBSD: prom.c,v 1.4 1996/11/27 19:54:49 niklas Exp $ */
/* $NetBSD: prom.c,v 1.1 1995/11/23 02:39:07 cgd Exp $ */
/*
@@ -29,8 +29,8 @@
#include <sys/types.h>
-#include <machine/prom.h>
#include <machine/rpb.h>
+#include <machine/prom.h>
int console;