-/* $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 $ */
/*
#include <sys/types.h>
-#include <machine/prom.h>
#include <machine/rpb.h>
+#include <machine/prom.h>
void
OSFpal()
-# $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
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}/../../../..
-/* $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 $ */
/*
#include <sys/exec.h>
#include <sys/exec_ecoff.h>
+#include <machine/rpb.h>
#include <machine/prom.h>
#define _KERNEL
-/* $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 $ */
/*
#include <sys/param.h>
#include <sys/disklabel.h>
+#include <machine/rpb.h>
#include <machine/prom.h>
#include "disk.h"
-/* $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 $ */
/*
*/
#include <sys/param.h>
+#include <machine/rpb.h>
#include <machine/prom.h>
#include "bbinfo.h"
-/* $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 $ */
/*
{
char buf[HDR_BUFSIZE], *fname;
struct ecoff_exechdr *ecoffp;
+#ifdef ALPHA_BOOT_ELF
Elf_Ehdr *elfp;
+#endif
int fd;
unsigned long loadaddr;
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 */
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);
-/* $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 $ */
/*
#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
/* 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;
-# $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
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
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
-/* $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()
-/* $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 $ */
/*
#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();
-/* $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 $ */
/*
#include <sys/exec.h>
#include <sys/exec_ecoff.h>
+#include <machine/rpb.h>
#include <machine/prom.h>
#define _KERNEL
-/* $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 $ */
/*
#include <sys/types.h>
-#include <machine/prom.h>
#include <machine/rpb.h>
+#include <machine/prom.h>
int console;