CVS commit: src/sys/arch/vax/boot/xxboot
Module Name:src Committed By: snj Date: Mon Apr 6 01:43:26 UTC 2020 Modified Files: src/sys/arch/vax/boot/xxboot: start.S Log Message: fix comment in typo To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 src/sys/arch/vax/boot/xxboot/start.S Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/xxboot/start.S diff -u src/sys/arch/vax/boot/xxboot/start.S:1.6 src/sys/arch/vax/boot/xxboot/start.S:1.7 --- src/sys/arch/vax/boot/xxboot/start.S:1.6 Mon May 22 17:00:55 2017 +++ src/sys/arch/vax/boot/xxboot/start.S Mon Apr 6 01:43:26 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: start.S,v 1.6 2017/05/22 17:00:55 ragge Exp $ */ +/* $NetBSD: start.S,v 1.7 2020/04/06 01:43:26 snj Exp $ */ /* * Copyright (c) 1995 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -52,7 +52,7 @@ _C_LABEL(start): # At offset 0x02 we have a dual used area: VMB.EXE starts execution here, # and uVAX-ROM looks for a pointer to a parameter block. We arrange for -# the parameter block offset to disassmble as a CASEL instructions which +# the parameter block offset to disassemble as a CASEL instructions which # falls through to 0x08. .org 0x02 # information used by uVAX-ROM .byte 0xcf # offset in words to identification area
CVS commit: src/sys/arch/vax/boot
Module Name:src Committed By: ragge Date: Tue May 1 07:03:48 UTC 2018 Modified Files: src/sys/arch/vax/boot/boot: conf.c src/sys/arch/vax/boot/xxboot: bootxx.c Log Message: Enable ffsv2 in boot. To generate a diff of this commit: cvs rdiff -u -r1.17 -r1.18 src/sys/arch/vax/boot/boot/conf.c cvs rdiff -u -r1.37 -r1.38 src/sys/arch/vax/boot/xxboot/bootxx.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/conf.c diff -u src/sys/arch/vax/boot/boot/conf.c:1.17 src/sys/arch/vax/boot/boot/conf.c:1.18 --- src/sys/arch/vax/boot/boot/conf.c:1.17 Mon May 22 16:59:32 2017 +++ src/sys/arch/vax/boot/boot/conf.c Tue May 1 07:03:47 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: conf.c,v 1.17 2017/05/22 16:59:32 ragge Exp $ */ +/* $NetBSD: conf.c,v 1.18 2018/05/01 07:03:47 ragge Exp $ */ /* * Copyright (c) 1994 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -84,7 +84,7 @@ int ndevs = (sizeof(devsw)/sizeof(de struct fs_ops file_system[] = { FS_OPS(ffsv1), - //FS_OPS(ffsv2), + FS_OPS(ffsv2), FS_OPS(nfs), FS_OPS(cd9660), FS_OPS(ustarfs), Index: src/sys/arch/vax/boot/xxboot/bootxx.c diff -u src/sys/arch/vax/boot/xxboot/bootxx.c:1.37 src/sys/arch/vax/boot/xxboot/bootxx.c:1.38 --- src/sys/arch/vax/boot/xxboot/bootxx.c:1.37 Fri Jun 28 01:13:40 2013 +++ src/sys/arch/vax/boot/xxboot/bootxx.c Tue May 1 07:03:47 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: bootxx.c,v 1.37 2013/06/28 01:13:40 matt Exp $ */ +/* $NetBSD: bootxx.c,v 1.38 2018/05/01 07:03:47 ragge Exp $ */ /*- * Copyright (c) 1982, 1986 The Regents of the University of California. @@ -187,7 +187,7 @@ die: struct fs_ops file_system[] = { #ifdef NEED_UFS { ffsv1_open, 0, ffsv1_read, 0, 0, ffsv1_stat }, - //{ ffsv2_open, 0, ffsv2_read, 0, 0, ffsv2_stat }, + { ffsv2_open, 0, ffsv2_read, 0, 0, ffsv2_stat }, #endif #ifdef NEED_CD9660 { cd9660_open, 0, cd9660_read, 0, 0, cd9660_stat },
CVS commit: src/sys/arch/vax/boot
Module Name:src Committed By: ragge Date: Thu Mar 22 08:58:56 UTC 2018 Modified Files: src/sys/arch/vax/boot: Makefile.inc Log Message: Let boot relocate to just below 8MB. This solves the problem with booting a kernel larger than below 4MB. To generate a diff of this commit: cvs rdiff -u -r1.17 -r1.18 src/sys/arch/vax/boot/Makefile.inc Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/Makefile.inc diff -u src/sys/arch/vax/boot/Makefile.inc:1.17 src/sys/arch/vax/boot/Makefile.inc:1.18 --- src/sys/arch/vax/boot/Makefile.inc:1.17 Sun Mar 13 17:48:53 2016 +++ src/sys/arch/vax/boot/Makefile.inc Thu Mar 22 08:58:56 2018 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.inc,v 1.17 2016/03/13 17:48:53 christos Exp $ +# $NetBSD: Makefile.inc,v 1.18 2018/03/22 08:58:56 ragge Exp $ NOSSP= NOFORTIFY= @@ -7,7 +7,7 @@ NODEBUG= .include -RELOC=0x3f +RELOC=0x7f .PATH: ${.CURDIR}/../../vax ${.CURDIR}/../common CPPFLAGS+=-I.
CVS commit: src/sys/arch/vax/boot/boot
Module Name:src Committed By: ragge Date: Wed Mar 21 18:27:27 UTC 2018 Modified Files: src/sys/arch/vax/boot/boot: devopen.c ra.c Log Message: Fix bug causing autoboot on 750/780 not to work. Cleanup. To generate a diff of this commit: cvs rdiff -u -r1.19 -r1.20 src/sys/arch/vax/boot/boot/devopen.c cvs rdiff -u -r1.21 -r1.22 src/sys/arch/vax/boot/boot/ra.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/devopen.c diff -u src/sys/arch/vax/boot/boot/devopen.c:1.19 src/sys/arch/vax/boot/boot/devopen.c:1.20 --- src/sys/arch/vax/boot/boot/devopen.c:1.19 Mon Mar 19 15:43:45 2018 +++ src/sys/arch/vax/boot/boot/devopen.c Wed Mar 21 18:27:27 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: devopen.c,v 1.19 2018/03/19 15:43:45 ragge Exp $ */ +/* $NetBSD: devopen.c,v 1.20 2018/03/21 18:27:27 ragge Exp $ */ /* * Copyright (c) 1997 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -49,7 +49,6 @@ int devopen(struct open_file *f, const char *fname, char **file) { int dev, unit, ctlr, part, adapt, i, a[4], x; - int *mapregs; struct devsw *dp; extern int cnvtab[]; char *s, *c; @@ -130,19 +129,19 @@ devopen(struct open_file *f, const char switch (vax_boardtype) { case VAX_BTYP_750: csrbase = (nexaddr == 0xf3 ? 0xffe000 : 0xfbe000); + mapaddr = (int *)nexaddr + VAX_NBPG; if (adapt < 0) break; nexaddr = (NEX750 + NEXSIZE * adapt); - mapaddr = (int *)nexaddr + VAX_NBPG; csrbase = (adapt == 8 ? 0xffe000 : 0xfbe000); break; case VAX_BTYP_780: case VAX_BTYP_790: csrbase = 0x2007e000 + 0x4 * ((nexaddr & 0x1e000) >> 13); + mapaddr = (int *)nexaddr + VAX_NBPG; if (adapt < 0) break; nexaddr = ((int)NEX780 + NEXSIZE * adapt); - mapaddr = (int *)nexaddr + VAX_NBPG; csrbase = 0x2007e000 + 0x4 * adapt; break; case VAX_BTYP_9CC: /* 6000/200 */ @@ -180,13 +179,9 @@ devopen(struct open_file *f, const char default: nexaddr = 0; /* No map regs */ csrbase = 0x2000; - /* Always map in the lowest 4M on qbus-based machines */ - mapregs = (void *)0x20088000; if (bootrpb.adpphy == 0x20087800) { nexaddr = bootrpb.adpphy; mapaddr = (int *)nexaddr + VAX_NBPG; - for (i = 0; i < 8192; i++) -mapregs[i] = PG_V | i; } break; } Index: src/sys/arch/vax/boot/boot/ra.c diff -u src/sys/arch/vax/boot/boot/ra.c:1.21 src/sys/arch/vax/boot/boot/ra.c:1.22 --- src/sys/arch/vax/boot/boot/ra.c:1.21 Mon Mar 19 15:43:45 2018 +++ src/sys/arch/vax/boot/boot/ra.c Wed Mar 21 18:27:27 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: ra.c,v 1.21 2018/03/19 15:43:45 ragge Exp $ */ +/* $NetBSD: ra.c,v 1.22 2018/03/21 18:27:27 ragge Exp $ */ /* * Copyright (c) 1995 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -65,7 +65,7 @@ static volatile struct uda { static struct disklabel ralabel; static char io_buf[DEV_BSIZE]; -static int dpart, dunit, remap, is_tmscp, curblock; +static int dpart, dunit, is_tmscp, curblock; static volatile u_short *ra_ip, *ra_sa, *ra_sw; int @@ -90,7 +90,6 @@ raopen(struct open_file *f, int adapt, i dpart = part; if (ctlr < 0) ctlr = 0; - remap = csrbase && nexaddr; curblock = 0; if (csrbase) { /* On a uda-alike adapter */ if (askname == 0) { @@ -254,8 +253,8 @@ rastrategy(void *f, int func, daddr_t db { #ifdef DEV_DEBUG - printf("rastrategy: buf %p remap %d is_tmscp %d\n", - buf, remap, is_tmscp); + printf("rastrategy: buf %p is_tmscp %d\n", + buf, is_tmscp); #endif uda.uda_cmd.mscp_seq.seq_buffer = ubmap(0, (int)buf, size);
CVS commit: src/sys/arch/vax/boot/boot
Module Name:src Committed By: ragge Date: Tue Mar 20 13:30:40 UTC 2018 Modified Files: src/sys/arch/vax/boot/boot: if_qe.c Log Message: Change the driver to map the data structures onto the qbus. To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/sys/arch/vax/boot/boot/if_qe.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/if_qe.c diff -u src/sys/arch/vax/boot/boot/if_qe.c:1.9 src/sys/arch/vax/boot/boot/if_qe.c:1.10 --- src/sys/arch/vax/boot/boot/if_qe.c:1.9 Mon Oct 26 19:16:58 2009 +++ src/sys/arch/vax/boot/boot/if_qe.c Tue Mar 20 13:30:40 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: if_qe.c,v 1.9 2009/10/26 19:16:58 cegger Exp $ */ +/* $NetBSD: if_qe.c,v 1.10 2018/03/20 13:30:40 ragge Exp $ */ /* * Copyright (c) 1998 Roar Thronæs. All rights reserved. @@ -69,8 +69,8 @@ static struct qe_softc { char qein[2048], qeout[2048];/* Packet buffers */ } qe_softc; -static struct qe_softc *sc = _softc; -static int addr; +static struct qe_softc *sc = _softc, *psc; +static int addr, ubaddr; #define QE_WCSR(csr, val) \ (*((volatile u_short *)(addr + (csr))) = (val)) @@ -111,6 +111,9 @@ qe_init(u_char *eaddr) QE_WCSR(QE_CSR_CSR, QE_RESET); QE_WCSR(QE_CSR_CSR, QE_RCSR(QE_CSR_CSR) & ~QE_RESET); + ubaddr = ubmap(0, (int)sc, sizeof(struct qe_softc)); + psc = (struct qe_softc *)ubaddr; + for (i = 0; i < 6; i++) { sc->setup_pkt[i][1] = QE_RCSR(i * 2); sc->setup_pkt[i+8][1] = QE_RCSR(i * 2); @@ -125,13 +128,13 @@ qe_init(u_char *eaddr) memset((void *)sc->rring, 0, sizeof(struct qe_ring)); sc->rring->qe_buf_len = -64; - sc->rring->qe_addr_lo = (short)((int)sc->setup_pkt); - sc->rring->qe_addr_hi = (short)((int)sc->setup_pkt >> 16); + sc->rring->qe_addr_lo = LOWORD(psc->setup_pkt); + sc->rring->qe_addr_hi = HIWORD(psc->setup_pkt); memset((void *)sc->tring, 0, sizeof(struct qe_ring)); sc->tring->qe_buf_len = -64; - sc->tring->qe_addr_lo = (short)((int)sc->setup_pkt); - sc->tring->qe_addr_hi = (short)((int)sc->setup_pkt >> 16); + sc->tring->qe_addr_lo = LOWORD(psc->setup_pkt); + sc->tring->qe_addr_hi = HIWORD(psc->setup_pkt); sc->rring[0].qe_flag = sc->rring[0].qe_status1 = QE_NOTYET; sc->rring->qe_addr_hi |= QE_VALID; @@ -141,10 +144,10 @@ qe_init(u_char *eaddr) QE_WCSR(QE_CSR_CSR, QE_XMIT_INT | QE_RCV_INT); - QE_WCSR(QE_CSR_RCLL, LOWORD(sc->rring)); - QE_WCSR(QE_CSR_RCLH, HIWORD(sc->rring)); - QE_WCSR(QE_CSR_XMTL, LOWORD(sc->tring)); - QE_WCSR(QE_CSR_XMTH, HIWORD(sc->tring)); + QE_WCSR(QE_CSR_RCLL, LOWORD(psc->rring)); + QE_WCSR(QE_CSR_RCLH, HIWORD(psc->rring)); + QE_WCSR(QE_CSR_XMTL, LOWORD(psc->tring)); + QE_WCSR(QE_CSR_XMTH, HIWORD(psc->tring)); while ((QE_RCSR(QE_CSR_CSR) & QE_INTS) != QE_INTS) ; @@ -152,31 +155,31 @@ qe_init(u_char *eaddr) QE_WCSR(QE_CSR_CSR, QE_RCSR(QE_CSR_CSR) & ~(QE_INT_ENABLE|QE_ELOOP)); QE_WCSR(QE_CSR_CSR, QE_RCSR(QE_CSR_CSR) | QE_ILOOP); - sc->rring[0].qe_addr_lo = (short)((int)sc->qein & 0x); - sc->rring[0].qe_addr_hi = (short)((int)sc->qein >> 16); - sc->rring[0].qe_buf_len=-MAXPACKETSIZE/2; + sc->rring[0].qe_addr_lo = LOWORD(psc->qein); + sc->rring[0].qe_addr_hi = HIWORD(psc->qein); + sc->rring[0].qe_buf_len = -MAXPACKETSIZE/2; sc->rring[0].qe_addr_hi |= QE_VALID; - sc->rring[0].qe_flag=sc->rring[0].qe_status1=QE_NOTYET; - sc->rring[0].qe_status2=1; + sc->rring[0].qe_flag = sc->rring[0].qe_status1 = QE_NOTYET; + sc->rring[0].qe_status2 = 1; sc->rring[1].qe_addr_lo = 0; sc->rring[1].qe_addr_hi = 0; sc->rring[1].qe_flag=sc->rring[1].qe_status1=QE_NOTYET; sc->rring[1].qe_status2=1; - sc->tring[0].qe_addr_lo = (short)((int)sc->qeout & 0x); - sc->tring[0].qe_addr_hi = (short)((int)sc->qeout >> 16); - sc->tring[0].qe_buf_len=0; - sc->tring[0].qe_flag=sc->tring[0].qe_status1=QE_NOTYET; + sc->tring[0].qe_addr_lo = LOWORD(psc->qeout); + sc->tring[0].qe_addr_hi = HIWORD(psc->qeout); + sc->tring[0].qe_buf_len = 0; + sc->tring[0].qe_flag = sc->tring[0].qe_status1 = QE_NOTYET; sc->tring[0].qe_addr_hi |= QE_EOMSG|QE_VALID; - sc->tring[1].qe_flag=sc->tring[1].qe_status1=QE_NOTYET; + sc->tring[1].qe_flag = sc->tring[1].qe_status1 = QE_NOTYET; sc->tring[1].qe_addr_lo = 0; sc->tring[1].qe_addr_hi = 0; QE_WCSR(QE_CSR_CSR, QE_RCSR(QE_CSR_CSR) | QE_RCV_ENABLE); - QE_WCSR(QE_CSR_RCLL, LOWORD(sc->rring)); - QE_WCSR(QE_CSR_RCLH, HIWORD(sc->rring)); + QE_WCSR(QE_CSR_RCLL, LOWORD(psc->rring)); + QE_WCSR(QE_CSR_RCLH, HIWORD(psc->rring)); } int @@ -206,12 +209,12 @@ retry: end: sc->rring[0].qe_status2 = sc->rring[1].qe_status2 = 1; - sc->rring[0].qe_flag=sc->rring[0].qe_status1=QE_NOTYET; - sc->rring[1].qe_flag=sc->rring[1].qe_status1=QE_NOTYET; + sc->rring[0].qe_flag = sc->rring[0].qe_status1 = QE_NOTYET; + sc->rring[1].qe_flag = sc->rring[1].qe_status1 = QE_NOTYET; QE_WCSR(QE_CSR_CSR, QE_RCSR(QE_CSR_CSR) | QE_RCV_ENABLE); - QE_WCSR(QE_CSR_RCLL,
CVS commit: src/sys/arch/vax/boot/boot
Module Name:src Committed By: ragge Date: Mon Mar 19 17:29:09 UTC 2018 Modified Files: src/sys/arch/vax/boot/boot: Makefile Log Message: gcc 5.5 has no problem with -O2 on boot. To generate a diff of this commit: cvs rdiff -u -r1.45 -r1.46 src/sys/arch/vax/boot/boot/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/Makefile diff -u src/sys/arch/vax/boot/boot/Makefile:1.45 src/sys/arch/vax/boot/boot/Makefile:1.46 --- src/sys/arch/vax/boot/boot/Makefile:1.45 Sat Apr 8 19:53:23 2017 +++ src/sys/arch/vax/boot/boot/Makefile Mon Mar 19 17:29:08 2018 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.45 2017/04/08 19:53:23 christos Exp $ +# $NetBSD: Makefile,v 1.46 2018/03/19 17:29:08 ragge Exp $ S= ${.CURDIR}/../../../.. @@ -17,8 +17,6 @@ LIBCRTBEGIN= LIBCRTEND= CLEANFILES+=${PROG} ${PROG}.sym -# XXX - hack, doesn't work with -O2 and gcc 4.8 -CFLAGS+=-O1 CPPFLAGS+=-DSUPPORT_BOOTPARAMS -DSUPPORT_BOOTP -DSUPPORT_DHCP -D_STANDALONE \ -DNO_MID_CHECK CPPFLAGS+=-DLIBSA_CREAD_NOCRC
CVS commit: src/sys/arch/vax/boot/boot
Module Name:src Committed By: ragge Date: Mon Mar 19 15:43:45 UTC 2018 Modified Files: src/sys/arch/vax/boot/boot: devopen.c hp.c if_de.c ra.c vaxstand.h Log Message: Use a common routine ubmap() that setup the map registers as needed, not expecting everything to be below 4M. This solves the problem that large kernels cannot be loaded reported on port-vax. To generate a diff of this commit: cvs rdiff -u -r1.18 -r1.19 src/sys/arch/vax/boot/boot/devopen.c cvs rdiff -u -r1.10 -r1.11 src/sys/arch/vax/boot/boot/hp.c cvs rdiff -u -r1.9 -r1.10 src/sys/arch/vax/boot/boot/if_de.c \ src/sys/arch/vax/boot/boot/vaxstand.h cvs rdiff -u -r1.20 -r1.21 src/sys/arch/vax/boot/boot/ra.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/devopen.c diff -u src/sys/arch/vax/boot/boot/devopen.c:1.18 src/sys/arch/vax/boot/boot/devopen.c:1.19 --- src/sys/arch/vax/boot/boot/devopen.c:1.18 Mon May 22 16:59:32 2017 +++ src/sys/arch/vax/boot/boot/devopen.c Mon Mar 19 15:43:45 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: devopen.c,v 1.18 2017/05/22 16:59:32 ragge Exp $ */ +/* $NetBSD: devopen.c,v 1.19 2018/03/19 15:43:45 ragge Exp $ */ /* * Copyright (c) 1997 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -27,6 +27,7 @@ #include #include +#include #include #include #include @@ -38,7 +39,12 @@ #include "vaxstand.h" int nexaddr, csrbase; +static int *mapaddr; +/* + * Boot device syntax: + * device(adapter, controller, unit, partition)file + */ int devopen(struct open_file *f, const char *fname, char **file) { @@ -127,6 +133,7 @@ devopen(struct open_file *f, const char if (adapt < 0) break; nexaddr = (NEX750 + NEXSIZE * adapt); + mapaddr = (int *)nexaddr + VAX_NBPG; csrbase = (adapt == 8 ? 0xffe000 : 0xfbe000); break; case VAX_BTYP_780: @@ -135,6 +142,7 @@ devopen(struct open_file *f, const char if (adapt < 0) break; nexaddr = ((int)NEX780 + NEXSIZE * adapt); + mapaddr = (int *)nexaddr + VAX_NBPG; csrbase = 0x2007e000 + 0x4 * adapt; break; case VAX_BTYP_9CC: /* 6000/200 */ @@ -176,6 +184,7 @@ devopen(struct open_file *f, const char mapregs = (void *)0x20088000; if (bootrpb.adpphy == 0x20087800) { nexaddr = bootrpb.adpphy; + mapaddr = (int *)nexaddr + VAX_NBPG; for (i = 0; i < 8192; i++) mapregs[i] = PG_V | i; } @@ -195,3 +204,24 @@ usage: printf("usage: dev(adapter,controller,unit,partition)file -asd\n"); return -1; } + +/* + * Map in virtual address vaddr of size vsize starting with map mapno. + * Returns the unibus address of the mapped area. + */ +int +ubmap(int mapno, int vaddr, int size) +{ + int voff = (vaddr & VAX_PGOFSET); + int rv = (mapno << VAX_PGSHIFT) + voff; + int vpag, npag; + + if (mapaddr == 0) + return vaddr; /* no map, phys == virt */ + + npag = (voff + size) / VAX_NBPG; + vpag = vaddr >> VAX_PGSHIFT; + while (npag-- >= 0) + mapaddr[mapno++] = vpag++ | PG_V; + return rv; +} Index: src/sys/arch/vax/boot/boot/hp.c diff -u src/sys/arch/vax/boot/boot/hp.c:1.10 src/sys/arch/vax/boot/boot/hp.c:1.11 --- src/sys/arch/vax/boot/boot/hp.c:1.10 Mon May 22 16:59:32 2017 +++ src/sys/arch/vax/boot/boot/hp.c Mon Mar 19 15:43:45 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: hp.c,v 1.10 2017/05/22 16:59:32 ragge Exp $ */ +/* $NetBSD: hp.c,v 1.11 2018/03/19 15:43:45 ragge Exp $ */ /* * Copyright (c) 1994 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -108,13 +108,9 @@ int hpstrategy(void *f, int func, daddr_t dblk, size_t size, void *buf, size_t *rsize) { - unsigned int pfnum, mapnr, nsize, bn, cn, sn, tn; + unsigned int bn, cn, sn, tn; - pfnum = (u_int)buf >> VAX_PGSHIFT; - - for(mapnr = 0, nsize = size; (nsize + VAX_NBPG) > 0; - nsize -= VAX_NBPG, mapnr++, pfnum++) - MBA_WCSR(MAPREG(mapnr), PG_V | pfnum); + (void)ubmap(0, (int)buf, size); MBA_WCSR(MBA_VAR, ((u_int)buf & VAX_PGOFSET)); MBA_WCSR(MBA_BC, (~size) + 1); Index: src/sys/arch/vax/boot/boot/if_de.c diff -u src/sys/arch/vax/boot/boot/if_de.c:1.9 src/sys/arch/vax/boot/boot/if_de.c:1.10 --- src/sys/arch/vax/boot/boot/if_de.c:1.9 Mon May 22 16:59:32 2017 +++ src/sys/arch/vax/boot/boot/if_de.c Mon Mar 19 15:43:45 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: if_de.c,v 1.9 2017/05/22 16:59:32 ragge Exp $ */ +/* $NetBSD: if_de.c,v 1.10 2018/03/19 15:43:45 ragge Exp $ */ /* * Copyright (c) 2000 Ludd, University of Lule}, Sweden. All rights reserved. @@ -86,7 +86,7 @@ static int crx, ctx; int deopen(struct open_file *f, int adapt, int ctlr, int unit, int part) { - int i, cdata, *map, npgs; + int i; u_char eaddr[6]; /* point to the device in memory */ @@ -108,14 +108,8 @@ deopen(struct open_file *f, int adapt, i /* Map in the control structures and buffers */ dc = alloc(sizeof(struct de_cdata)); - pdc = (struct de_cdata *)((int)dc & VAX_PGOFSET); - map = (int *)nexaddr + 512; - npgs = (sizeof(struct
CVS commit: src/sys/arch/vax/boot/common
Module Name:src Committed By: ragge Date: Mon Mar 19 15:37:56 UTC 2018 Modified Files: src/sys/arch/vax/boot/common: srt0.S Log Message: Do not use movc3 to copy boot program, it may be larger than 64k. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/arch/vax/boot/common/srt0.S Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/common/srt0.S diff -u src/sys/arch/vax/boot/common/srt0.S:1.5 src/sys/arch/vax/boot/common/srt0.S:1.6 --- src/sys/arch/vax/boot/common/srt0.S:1.5 Mon May 22 17:00:19 2017 +++ src/sys/arch/vax/boot/common/srt0.S Mon Mar 19 15:37:56 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: srt0.S,v 1.5 2017/05/22 17:00:19 ragge Exp $ */ +/* $NetBSD: srt0.S,v 1.6 2018/03/19 15:37:56 ragge Exp $ */ /* * Copyright (c) 1994 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -49,7 +49,9 @@ ALTENTRY(start) movl $_C_LABEL(start), %r3 # get where we want to be cmpl %r1,%r3 # are we where we want to be? beql relocated # already relocated, skip copy - movc3 %r0,(%r1),(%r3) # copy +1: movb (%r1)+,(%r3)+ # copy + sobgtr %r0,1b + subl3 $_C_LABEL(edata), $_C_LABEL(end), %r2 movc5 $0,(%r3),$0,%r2,(%r3) # Zero bss
CVS commit: src/sys/arch/vax/boot/xxboot
Module Name:src Committed By: ragge Date: Mon May 22 17:00:55 UTC 2017 Modified Files: src/sys/arch/vax/boot/xxboot: start.S Log Message: Update copyright notice for Ludd (remove clause 3 & 4). To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/arch/vax/boot/xxboot/start.S Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/xxboot/start.S diff -u src/sys/arch/vax/boot/xxboot/start.S:1.5 src/sys/arch/vax/boot/xxboot/start.S:1.6 --- src/sys/arch/vax/boot/xxboot/start.S:1.5 Thu Apr 4 12:48:07 2013 +++ src/sys/arch/vax/boot/xxboot/start.S Mon May 22 17:00:55 2017 @@ -1,4 +1,4 @@ -/* $NetBSD: start.S,v 1.5 2013/04/04 12:48:07 martin Exp $ */ +/* $NetBSD: start.S,v 1.6 2017/05/22 17:00:55 ragge Exp $ */ /* * Copyright (c) 1995 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -14,12 +14,6 @@ * 2. Redistributions in binary form must reproduce the above copyright *notice, this list of conditions and the following disclaimer in the *documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - *must display the following acknowledgement: - * This product includes software developed at Ludd, University of - * Lule}, Sweden and its contributors. - * 4. The name of the author may not be used to endorse or promote products - *derived from this software without specific prior written permission * * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
CVS commit: src/sys/arch/vax/boot/common
Module Name:src Committed By: ragge Date: Mon May 22 17:00:19 UTC 2017 Modified Files: src/sys/arch/vax/boot/common: romread.S srt0.S str.S Log Message: Update copyright notice for Ludd (remove clause 3 & 4). To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/sys/arch/vax/boot/common/romread.S cvs rdiff -u -r1.4 -r1.5 src/sys/arch/vax/boot/common/srt0.S cvs rdiff -u -r1.5 -r1.6 src/sys/arch/vax/boot/common/str.S Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/common/romread.S diff -u src/sys/arch/vax/boot/common/romread.S:1.1 src/sys/arch/vax/boot/common/romread.S:1.2 --- src/sys/arch/vax/boot/common/romread.S:1.1 Sun Feb 24 01:04:25 2002 +++ src/sys/arch/vax/boot/common/romread.S Mon May 22 17:00:19 2017 @@ -1,4 +1,4 @@ -/* $NetBSD: romread.S,v 1.1 2002/02/24 01:04:25 matt Exp $ */ +/* $NetBSD: romread.S,v 1.2 2017/05/22 17:00:19 ragge Exp $ */ /* * Copyright (c) 1995 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -14,12 +14,6 @@ * 2. Redistributions in binary form must reproduce the above copyright *notice, this list of conditions and the following disclaimer in the *documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - *must display the following acknowledgement: - * This product includes software developed at Ludd, University of - * Lule}, Sweden and its contributors. - * 4. The name of the author may not be used to endorse or promote products - *derived from this software without specific prior written permission * * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES Index: src/sys/arch/vax/boot/common/srt0.S diff -u src/sys/arch/vax/boot/common/srt0.S:1.4 src/sys/arch/vax/boot/common/srt0.S:1.5 --- src/sys/arch/vax/boot/common/srt0.S:1.4 Mon Dec 2 20:23:32 2002 +++ src/sys/arch/vax/boot/common/srt0.S Mon May 22 17:00:19 2017 @@ -1,4 +1,4 @@ -/* $NetBSD: srt0.S,v 1.4 2002/12/02 20:23:32 ragge Exp $ */ +/* $NetBSD: srt0.S,v 1.5 2017/05/22 17:00:19 ragge Exp $ */ /* * Copyright (c) 1994 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -11,11 +11,6 @@ * 2. Redistributions in binary form must reproduce the above copyright *notice, this list of conditions and the following disclaimer in the *documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - *must display the following acknowledgement: - * This product includes software developed at Ludd, University of Lule}. - * 4. The name of the author may not be used to endorse or promote products - *derived from this software without specific prior written permission * * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES Index: src/sys/arch/vax/boot/common/str.S diff -u src/sys/arch/vax/boot/common/str.S:1.5 src/sys/arch/vax/boot/common/str.S:1.6 --- src/sys/arch/vax/boot/common/str.S:1.5 Sun Dec 11 12:19:34 2005 +++ src/sys/arch/vax/boot/common/str.S Mon May 22 17:00:19 2017 @@ -1,4 +1,4 @@ -/* $NetBSD: str.S,v 1.5 2005/12/11 12:19:34 christos Exp $ */ +/* $NetBSD: str.S,v 1.6 2017/05/22 17:00:19 ragge Exp $ */ /* * Copyright (c) 1996 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -11,12 +11,6 @@ * 2. Redistributions in binary form must reproduce the above copyright *notice, this list of conditions and the following disclaimer in the *documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - *must display the following acknowledgement: - * This product includes software developed at Ludd, University of - * Lule}, Sweden and its contributors. - * 4. The name of the author may not be used to endorse or promote products - *derived from this software without specific prior written permission * * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
CVS commit: src/sys/arch/vax/boot/boot
Module Name:src Committed By: ragge Date: Mon May 22 16:59:32 UTC 2017 Modified Files: src/sys/arch/vax/boot/boot: autoconf.c conf.c consio.c consio2.S ctu.c data.h devopen.c hp.c if_de.c if_le.c if_ni.c mfm.c ra.c rom.c tmscp.c vaxstand.h Log Message: Update copyright notice for Ludd (remove clause 3 & 4). To generate a diff of this commit: cvs rdiff -u -r1.28 -r1.29 src/sys/arch/vax/boot/boot/autoconf.c cvs rdiff -u -r1.16 -r1.17 src/sys/arch/vax/boot/boot/conf.c \ src/sys/arch/vax/boot/boot/consio.c cvs rdiff -u -r1.1 -r1.2 src/sys/arch/vax/boot/boot/consio2.S cvs rdiff -u -r1.8 -r1.9 src/sys/arch/vax/boot/boot/ctu.c \ src/sys/arch/vax/boot/boot/if_de.c src/sys/arch/vax/boot/boot/tmscp.c \ src/sys/arch/vax/boot/boot/vaxstand.h cvs rdiff -u -r1.4 -r1.5 src/sys/arch/vax/boot/boot/data.h cvs rdiff -u -r1.17 -r1.18 src/sys/arch/vax/boot/boot/devopen.c cvs rdiff -u -r1.9 -r1.10 src/sys/arch/vax/boot/boot/hp.c \ src/sys/arch/vax/boot/boot/rom.c cvs rdiff -u -r1.12 -r1.13 src/sys/arch/vax/boot/boot/if_le.c cvs rdiff -u -r1.10 -r1.11 src/sys/arch/vax/boot/boot/if_ni.c cvs rdiff -u -r1.14 -r1.15 src/sys/arch/vax/boot/boot/mfm.c cvs rdiff -u -r1.19 -r1.20 src/sys/arch/vax/boot/boot/ra.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/autoconf.c diff -u src/sys/arch/vax/boot/boot/autoconf.c:1.28 src/sys/arch/vax/boot/boot/autoconf.c:1.29 --- src/sys/arch/vax/boot/boot/autoconf.c:1.28 Wed Mar 18 10:22:37 2009 +++ src/sys/arch/vax/boot/boot/autoconf.c Mon May 22 16:59:32 2017 @@ -1,4 +1,4 @@ -/* $NetBSD: autoconf.c,v 1.28 2009/03/18 10:22:37 cegger Exp $ */ +/* $NetBSD: autoconf.c,v 1.29 2017/05/22 16:59:32 ragge Exp $ */ /* * Copyright (c) 1994, 1998 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -11,11 +11,6 @@ * 2. Redistributions in binary form must reproduce the above copyright *notice, this list of conditions and the following disclaimer in the *documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - *must display the following acknowledgement: - * This product includes software developed at Ludd, University of Lule}. - * 4. The name of the author may not be used to endorse or promote products - *derived from this software without specific prior written permission * * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES Index: src/sys/arch/vax/boot/boot/conf.c diff -u src/sys/arch/vax/boot/boot/conf.c:1.16 src/sys/arch/vax/boot/boot/conf.c:1.17 --- src/sys/arch/vax/boot/boot/conf.c:1.16 Fri Jun 28 01:13:40 2013 +++ src/sys/arch/vax/boot/boot/conf.c Mon May 22 16:59:32 2017 @@ -1,4 +1,4 @@ -/* $NetBSD: conf.c,v 1.16 2013/06/28 01:13:40 matt Exp $ */ +/* $NetBSD: conf.c,v 1.17 2017/05/22 16:59:32 ragge Exp $ */ /* * Copyright (c) 1994 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -11,11 +11,6 @@ * 2. Redistributions in binary form must reproduce the above copyright *notice, this list of conditions and the following disclaimer in the *documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - *must display the following acknowledgement: - * This product includes software developed at Ludd, University of Lule}. - * 4. The name of the author may not be used to endorse or promote products - *derived from this software without specific prior written permission * * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES Index: src/sys/arch/vax/boot/boot/consio.c diff -u src/sys/arch/vax/boot/boot/consio.c:1.16 src/sys/arch/vax/boot/boot/consio.c:1.17 --- src/sys/arch/vax/boot/boot/consio.c:1.16 Thu Jul 7 06:55:39 2016 +++ src/sys/arch/vax/boot/boot/consio.c Mon May 22 16:59:32 2017 @@ -1,4 +1,4 @@ -/* $NetBSD: consio.c,v 1.16 2016/07/07 06:55:39 msaitoh Exp $ */ +/* $NetBSD: consio.c,v 1.17 2017/05/22 16:59:32 ragge Exp $ */ /* * Copyright (c) 1994, 1998 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -11,11 +11,6 @@ * 2. Redistributions in binary form must reproduce the above copyright *notice, this list of conditions and the following disclaimer in the *documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - *must display the following acknowledgement: - * This product includes software developed at Ludd, University of Lule}. - * 4. The name of the author may not be used to endorse or promote products - *derived from this software without
CVS commit: src/sys/arch/vax/boot/boot
Module Name:src Committed By: dholland Date: Sat Jun 11 06:42:27 UTC 2016 Modified Files: src/sys/arch/vax/boot/boot: boot.c Log Message: PR 51200 gets in libsa considered harmful: use kgets To generate a diff of this commit: cvs rdiff -u -r1.33 -r1.34 src/sys/arch/vax/boot/boot/boot.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/boot.c diff -u src/sys/arch/vax/boot/boot/boot.c:1.33 src/sys/arch/vax/boot/boot/boot.c:1.34 --- src/sys/arch/vax/boot/boot/boot.c:1.33 Fri Jun 5 16:01:55 2015 +++ src/sys/arch/vax/boot/boot/boot.c Sat Jun 11 06:42:27 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: boot.c,v 1.33 2015/06/05 16:01:55 martin Exp $ */ +/* $NetBSD: boot.c,v 1.34 2016/06/11 06:42:27 dholland Exp $ */ /*- * Copyright (c) 1982, 1986 The Regents of the University of California. * All rights reserved. @@ -163,7 +163,7 @@ Xmain(void) char *c, *d; printf("> "); - gets(line); + kgets(line, sizeof(line)); c = line; while (*c == ' ')
CVS commit: src/sys/arch/vax/boot
Module Name:src Committed By: christos Date: Sun Mar 13 17:48:53 UTC 2016 Modified Files: src/sys/arch/vax/boot: Makefile.inc Log Message: Add NO variables for the things that boot block does not support (SSP/PIE/DEBUG/FORTIFY) To generate a diff of this commit: cvs rdiff -u -r1.16 -r1.17 src/sys/arch/vax/boot/Makefile.inc Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/Makefile.inc diff -u src/sys/arch/vax/boot/Makefile.inc:1.16 src/sys/arch/vax/boot/Makefile.inc:1.17 --- src/sys/arch/vax/boot/Makefile.inc:1.16 Wed Aug 21 02:15:41 2013 +++ src/sys/arch/vax/boot/Makefile.inc Sun Mar 13 13:48:53 2016 @@ -1,4 +1,9 @@ -# $NetBSD: Makefile.inc,v 1.16 2013/08/21 06:15:41 matt Exp $ +# $NetBSD: Makefile.inc,v 1.17 2016/03/13 17:48:53 christos Exp $ + +NOSSP= +NOFORTIFY= +NOPIE= +NODEBUG= .include
CVS commit: src/sys/arch/vax/boot/boot
Module Name:src Committed By: tsutsui Date: Sun Jan 17 03:08:39 UTC 2016 Modified Files: src/sys/arch/vax/boot/boot: Makefile Log Message: Make this build without installed DESTDIR files. To generate a diff of this commit: cvs rdiff -u -r1.42 -r1.43 src/sys/arch/vax/boot/boot/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/Makefile diff -u src/sys/arch/vax/boot/boot/Makefile:1.42 src/sys/arch/vax/boot/boot/Makefile:1.43 --- src/sys/arch/vax/boot/boot/Makefile:1.42 Sat May 24 07:38:42 2014 +++ src/sys/arch/vax/boot/boot/Makefile Sun Jan 17 03:08:39 2016 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.42 2014/05/24 07:38:42 martin Exp $ +# $NetBSD: Makefile,v 1.43 2016/01/17 03:08:39 tsutsui Exp $ S= ${.CURDIR}/../../../.. @@ -8,7 +8,13 @@ PROG= boot DEVS= hp.c ctu.c ra.c mfm.c if_qe.c if_le.c if_ze.c if_de.c if_ni.c SRCS= srt0.S boot.c devopen.c conf.c autoconf.c netio.c rom.c romread.S \ consio.c consio2.S str.S ${DEVS} findcpu.c vers.c + +# XXX SHOULD NOT NEED TO DEFINE THESE! LIBC= +LIBCRT0= +LIBCRTI= +LIBCRTBEGIN= +LIBCRTEND= CLEANFILES+=${PROG} ${PROG}.sym vers.c # XXX - hack, doesn't work with -O2 and gcc 4.8
CVS commit: src/sys/arch/vax/boot/boot
Module Name:src Committed By: tsutsui Date: Sun Jan 17 04:53:16 UTC 2016 Modified Files: src/sys/arch/vax/boot/boot: Makefile version Log Message: Enable LIBSA_CREAD_NOCRC. PR/50638 Bump version to denote user visible change. Tested on simh 4.0-Beta1 emulationg MicroVAX 3900. To generate a diff of this commit: cvs rdiff -u -r1.43 -r1.44 src/sys/arch/vax/boot/boot/Makefile cvs rdiff -u -r1.7 -r1.8 src/sys/arch/vax/boot/boot/version Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/Makefile diff -u src/sys/arch/vax/boot/boot/Makefile:1.43 src/sys/arch/vax/boot/boot/Makefile:1.44 --- src/sys/arch/vax/boot/boot/Makefile:1.43 Sun Jan 17 03:08:39 2016 +++ src/sys/arch/vax/boot/boot/Makefile Sun Jan 17 04:53:16 2016 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.43 2016/01/17 03:08:39 tsutsui Exp $ +# $NetBSD: Makefile,v 1.44 2016/01/17 04:53:16 tsutsui Exp $ S= ${.CURDIR}/../../../.. @@ -21,6 +21,7 @@ CLEANFILES+=${PROG} ${PROG}.sym vers.c CFLAGS+=-O1 CPPFLAGS+=-DSUPPORT_BOOTPARAMS -DSUPPORT_BOOTP -DSUPPORT_DHCP -D_STANDALONE \ -DNO_MID_CHECK +CPPFLAGS+=-DLIBSA_CREAD_NOCRC #CPPFLAGS+=-DBOOTP_DEBUG -DNETIF_DEBUG -DETHER_DEBUG -DNFS_DEBUG -DDEV_DEBUG \ # -DRPC_DEBUG -DRARP_DEBUG -DPARANOID BINDIR= Index: src/sys/arch/vax/boot/boot/version diff -u src/sys/arch/vax/boot/boot/version:1.7 src/sys/arch/vax/boot/boot/version:1.8 --- src/sys/arch/vax/boot/boot/version:1.7 Sat Oct 18 08:33:27 2014 +++ src/sys/arch/vax/boot/boot/version Sun Jan 17 04:53:16 2016 @@ -1,4 +1,4 @@ -$NetBSD: version,v 1.7 2014/10/18 08:33:27 snj Exp $ +$NetBSD: version,v 1.8 2016/01/17 04:53:16 tsutsui Exp $ NOTE ANY CHANGES YOU MAKE TO THE BOOTBLOCKS HERE. The format of this file is important - make sure the entries are appended on end, last item @@ -28,3 +28,4 @@ is taken as the current. 1.9: Support verbose/quiet boot. 1.10: loadfile() update: ELF symbols no longer need backward seeks. 1.11: loadfile() update to avoid backwards seeks for ELF Program Headers. +1.12: Disable slow gunzip CRC32 calculation.
CVS commit: src/sys/arch/vax/boot/boot
Module Name:src Committed By: martin Date: Fri Jun 5 16:01:55 UTC 2015 Modified Files: src/sys/arch/vax/boot/boot: boot.c Log Message: Close the file descriptor used for loading before jumping to the kernel. Pointed out by Felix Deichmann on port-vax. To generate a diff of this commit: cvs rdiff -u -r1.32 -r1.33 src/sys/arch/vax/boot/boot/boot.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/boot.c diff -u src/sys/arch/vax/boot/boot/boot.c:1.32 src/sys/arch/vax/boot/boot/boot.c:1.33 --- src/sys/arch/vax/boot/boot/boot.c:1.32 Sat Nov 9 18:31:53 2013 +++ src/sys/arch/vax/boot/boot/boot.c Fri Jun 5 16:01:55 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: boot.c,v 1.32 2013/11/09 18:31:53 christos Exp $ */ +/* $NetBSD: boot.c,v 1.33 2015/06/05 16:01:55 martin Exp $ */ /*- * Copyright (c) 1982, 1986 The Regents of the University of California. * All rights reserved. @@ -93,7 +93,7 @@ struct rpb bootrpb; void Xmain(void) { - int j, nu; + int j, nu, fd; u_long marks[MARK_MAX]; extern const char bootprog_rev[]; @@ -133,14 +133,14 @@ Xmain(void) int fileindex; for (fileindex = 0; filelist[fileindex].name[0] != '\0'; fileindex++) { - int err; errno = 0; if (!filelist[fileindex].quiet) printf( boot %s\n, filelist[fileindex].name); marks[MARK_START] = 0; - err = loadfile(filelist[fileindex].name, marks, + fd = loadfile(filelist[fileindex].name, marks, LOAD_KERNEL|COUNT_KERNEL); - if (err == 0) { + if (fd = 0) { +close(fd); machdep_start((char *)marks[MARK_ENTRY], marks[MARK_NSYM], (void *)marks[MARK_START], @@ -197,7 +197,7 @@ void boot(char *arg) { char *fn = netbsd; - int howto, fl, err; + int howto, fl, fd; u_long marks[MARK_MAX]; if (arg) { @@ -230,8 +230,9 @@ fail: printf(usage: boot [filename] [ } load: marks[MARK_START] = 0; - err = loadfile(fn, marks, LOAD_KERNEL|COUNT_KERNEL); - if (err == 0) { + fd = loadfile(fn, marks, LOAD_KERNEL|COUNT_KERNEL); + if (fd = 0) { + close(fd); machdep_start((char *)marks[MARK_ENTRY], marks[MARK_NSYM], (void *)marks[MARK_START],
CVS commit: src/sys/arch/vax/boot/boot
Module Name:src Committed By: martin Date: Sun Aug 10 16:53:22 UTC 2014 Modified Files: src/sys/arch/vax/boot/boot: devopen.c Log Message: Remove atoi() prototype To generate a diff of this commit: cvs rdiff -u -r1.16 -r1.17 src/sys/arch/vax/boot/boot/devopen.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/devopen.c diff -u src/sys/arch/vax/boot/boot/devopen.c:1.16 src/sys/arch/vax/boot/boot/devopen.c:1.17 --- src/sys/arch/vax/boot/boot/devopen.c:1.16 Sat Mar 14 21:04:16 2009 +++ src/sys/arch/vax/boot/boot/devopen.c Sun Aug 10 16:53:22 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: devopen.c,v 1.16 2009/03/14 21:04:16 dsl Exp $ */ +/* $NetBSD: devopen.c,v 1.17 2014/08/10 16:53:22 martin Exp $ */ /* * Copyright (c) 1997 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -43,7 +43,6 @@ #include vaxstand.h -int atoi(char *); int nexaddr, csrbase; int
CVS commit: src/sys/arch/vax/boot/boot
Module Name:src Committed By: martin Date: Sat May 24 07:38:42 UTC 2014 Modified Files: src/sys/arch/vax/boot/boot: Makefile Log Message: Force -O1 when compiling this, it doesn't work with -O2 (need to investigate later) To generate a diff of this commit: cvs rdiff -u -r1.41 -r1.42 src/sys/arch/vax/boot/boot/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/Makefile diff -u src/sys/arch/vax/boot/boot/Makefile:1.41 src/sys/arch/vax/boot/boot/Makefile:1.42 --- src/sys/arch/vax/boot/boot/Makefile:1.41 Wed Aug 21 06:15:41 2013 +++ src/sys/arch/vax/boot/boot/Makefile Sat May 24 07:38:42 2014 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.41 2013/08/21 06:15:41 matt Exp $ +# $NetBSD: Makefile,v 1.42 2014/05/24 07:38:42 martin Exp $ S= ${.CURDIR}/../../../.. @@ -11,6 +11,8 @@ SRCS= srt0.S boot.c devopen.c conf.c aut LIBC= CLEANFILES+=${PROG} ${PROG}.sym vers.c +# XXX - hack, doesn't work with -O2 and gcc 4.8 +CFLAGS+=-O1 CPPFLAGS+=-DSUPPORT_BOOTPARAMS -DSUPPORT_BOOTP -DSUPPORT_DHCP -D_STANDALONE \ -DNO_MID_CHECK #CPPFLAGS+=-DBOOTP_DEBUG -DNETIF_DEBUG -DETHER_DEBUG -DNFS_DEBUG -DDEV_DEBUG \
CVS commit: src/sys/arch/vax/boot/boot
Module Name:src Committed By: christos Date: Sat Nov 9 18:31:53 UTC 2013 Modified Files: src/sys/arch/vax/boot/boot: boot.c Log Message: remove unused To generate a diff of this commit: cvs rdiff -u -r1.31 -r1.32 src/sys/arch/vax/boot/boot/boot.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/boot.c diff -u src/sys/arch/vax/boot/boot/boot.c:1.31 src/sys/arch/vax/boot/boot/boot.c:1.32 --- src/sys/arch/vax/boot/boot/boot.c:1.31 Sat Jan 22 14:19:24 2011 +++ src/sys/arch/vax/boot/boot/boot.c Sat Nov 9 13:31:53 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: boot.c,v 1.31 2011/01/22 19:19:24 joerg Exp $ */ +/* $NetBSD: boot.c,v 1.32 2013/11/09 18:31:53 christos Exp $ */ /*- * Copyright (c) 1982, 1986 The Regents of the University of California. * All rights reserved. @@ -93,12 +93,10 @@ struct rpb bootrpb; void Xmain(void) { - int io; int j, nu; u_long marks[MARK_MAX]; extern const char bootprog_rev[]; - io = 0; skip = 1; autoconf();
CVS commit: src/sys/arch/vax/boot
Module Name:src Committed By: matt Date: Wed Aug 21 06:15:41 UTC 2013 Modified Files: src/sys/arch/vax/boot: Makefile.inc src/sys/arch/vax/boot/boot: Makefile Log Message: Use bsd.klinks.mk To generate a diff of this commit: cvs rdiff -u -r1.15 -r1.16 src/sys/arch/vax/boot/Makefile.inc cvs rdiff -u -r1.40 -r1.41 src/sys/arch/vax/boot/boot/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/Makefile.inc diff -u src/sys/arch/vax/boot/Makefile.inc:1.15 src/sys/arch/vax/boot/Makefile.inc:1.16 --- src/sys/arch/vax/boot/Makefile.inc:1.15 Thu Jul 18 12:15:16 2013 +++ src/sys/arch/vax/boot/Makefile.inc Wed Aug 21 06:15:41 2013 @@ -1,4 +1,6 @@ -# $NetBSD: Makefile.inc,v 1.15 2013/07/18 12:15:16 joerg Exp $ +# $NetBSD: Makefile.inc,v 1.16 2013/08/21 06:15:41 matt Exp $ + +.include bsd.klinks.mk RELOC=0x3f .PATH: ${.CURDIR}/../../vax ${.CURDIR}/../common @@ -9,6 +11,7 @@ CPPFLAGS+=-I${.CURDIR}/../../ CPPFLAGS+=-I${.CURDIR}/../common CPPFLAGS+=-I${.CURDIR}/../../include CPPFLAGS+=-DRELOC=${RELOC} +CPPFLAGS+=-D_STANDALONE WARNS?= 1 CFLAGS+=-ffreestanding -fno-pic -fno-unwind-tables @@ -18,13 +21,3 @@ MKMAN=no LIBCRTBEGIN= LIBCRTEND= - -.if ${MACHINE} == vax -.PHONY: machine-links -beforedepend: machine-links -machine-links: - @rm -f machine ln -s ${S}/arch/${MACHINE}/include machine - @rm -f ${MACHINE_ARCH} ln -s ${S}/arch/${MACHINE_ARCH}/include ${MACHINE_ARCH} -.NOPATH: machine ${MACHINE_ARCH} -CLEANFILES+= machine ${MACHINE_ARCH} -.endif Index: src/sys/arch/vax/boot/boot/Makefile diff -u src/sys/arch/vax/boot/boot/Makefile:1.40 src/sys/arch/vax/boot/boot/Makefile:1.41 --- src/sys/arch/vax/boot/boot/Makefile:1.40 Mon May 14 10:05:50 2012 +++ src/sys/arch/vax/boot/boot/Makefile Wed Aug 21 06:15:41 2013 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.40 2012/05/14 10:05:50 abs Exp $ +# $NetBSD: Makefile,v 1.41 2013/08/21 06:15:41 matt Exp $ S= ${.CURDIR}/../../../.. @@ -36,7 +36,7 @@ vers.c: ${.CURDIR}/version ${HOST_SH} ${S}/conf/newvers_stand.sh -N ${${MKREPRO} == yes :?:-D} \ ${.CURDIR}/version ${MACHINE} -${PROG}: machine-links ${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN} +${PROG}: ${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN} ${_MKTARGET_LINK} ${LD} -N -Ttext ${RELOC} -e nisse -o ${PROG}.sym ${OBJS} \ ${LIBSA} ${LIBZ} ${LIBSA} ${LIBKERN}
CVS commit: src/sys/arch/vax/boot
Module Name:src Committed By: matt Date: Fri Jun 28 01:13:40 UTC 2013 Modified Files: src/sys/arch/vax/boot/boot: conf.c src/sys/arch/vax/boot/xxboot: bootxx.c Log Message: ufs - ffsv1 (ffsv2 is commentout due to size limitations) To generate a diff of this commit: cvs rdiff -u -r1.15 -r1.16 src/sys/arch/vax/boot/boot/conf.c cvs rdiff -u -r1.36 -r1.37 src/sys/arch/vax/boot/xxboot/bootxx.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/conf.c diff -u src/sys/arch/vax/boot/boot/conf.c:1.15 src/sys/arch/vax/boot/boot/conf.c:1.16 --- src/sys/arch/vax/boot/boot/conf.c:1.15 Wed Mar 18 16:00:15 2009 +++ src/sys/arch/vax/boot/boot/conf.c Fri Jun 28 01:13:40 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: conf.c,v 1.15 2009/03/18 16:00:15 cegger Exp $ */ +/* $NetBSD: conf.c,v 1.16 2013/06/28 01:13:40 matt Exp $ */ /* * Copyright (c) 1994 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -88,13 +88,14 @@ int cnvtab[] = { int ndevs = (sizeof(devsw)/sizeof(devsw[0])); struct fs_ops file_system[] = { - FS_OPS(ufs), + FS_OPS(ffsv1), + //FS_OPS(ffsv2), FS_OPS(nfs), FS_OPS(cd9660), FS_OPS(ustarfs), }; -int nfsys = (sizeof(file_system) / sizeof(struct fs_ops)); +int nfsys = __arraycount(file_system); int nostrategy(void *f, int func, daddr_t dblk, Index: src/sys/arch/vax/boot/xxboot/bootxx.c diff -u src/sys/arch/vax/boot/xxboot/bootxx.c:1.36 src/sys/arch/vax/boot/xxboot/bootxx.c:1.37 --- src/sys/arch/vax/boot/xxboot/bootxx.c:1.36 Fri Sep 18 21:40:09 2009 +++ src/sys/arch/vax/boot/xxboot/bootxx.c Fri Jun 28 01:13:40 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: bootxx.c,v 1.36 2009/09/18 21:40:09 mhitch Exp $ */ +/* $NetBSD: bootxx.c,v 1.37 2013/06/28 01:13:40 matt Exp $ */ /*- * Copyright (c) 1982, 1986 The Regents of the University of California. @@ -186,7 +186,8 @@ die: */ struct fs_ops file_system[] = { #ifdef NEED_UFS - { ufs_open, 0, ufs_read, 0, 0, ufs_stat }, + { ffsv1_open, 0, ffsv1_read, 0, 0, ffsv1_stat }, + //{ ffsv2_open, 0, ffsv2_read, 0, 0, ffsv2_stat }, #endif #ifdef NEED_CD9660 { cd9660_open, 0, cd9660_read, 0, 0, cd9660_stat }, @@ -196,7 +197,7 @@ struct fs_ops file_system[] = { #endif }; -int nfsys = (sizeof(file_system) / sizeof(struct fs_ops)); +int nfsys = __arraycount(file_system); #if 0 int tar_open(char *path, struct open_file *f);
CVS commit: src/sys/arch/vax/boot/xxboot
Module Name:src Committed By: martin Date: Thu Apr 4 12:48:08 UTC 2013 Modified Files: src/sys/arch/vax/boot/xxboot: start.S Log Message: Rearrange primary bootstrap slightly to free up all space between the disk label and the uVAX rom boot parameter block. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/sys/arch/vax/boot/xxboot/start.S Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/xxboot/start.S diff -u src/sys/arch/vax/boot/xxboot/start.S:1.4 src/sys/arch/vax/boot/xxboot/start.S:1.5 --- src/sys/arch/vax/boot/xxboot/start.S:1.4 Sun Dec 11 12:19:34 2005 +++ src/sys/arch/vax/boot/xxboot/start.S Thu Apr 4 12:48:07 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: start.S,v 1.4 2005/12/11 12:19:34 christos Exp $ */ +/* $NetBSD: start.S,v 1.5 2013/04/04 12:48:07 martin Exp $ */ /* * Copyright (c) 1995 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -38,6 +38,7 @@ #define _LOCORE +#define __HAVE_OLD_DISKLABEL /* not automatically added due to _LOCORE */ #define OMIT_DKTYPENUMS #define OMIT_FSTYPENUMS #include sys/disklabel.h @@ -55,8 +56,12 @@ _C_LABEL(start): .org 0x00 # uVAX booted from TK50 starts here brb from_0x00 # continue behind dispatch-block +# At offset 0x02 we have a dual used area: VMB.EXE starts execution here, +# and uVAX-ROM looks for a pointer to a parameter block. We arrange for +# the parameter block offset to disassmble as a CASEL instructions which +# falls through to 0x08. .org 0x02 # information used by uVAX-ROM - .byte 0xcf # offset in words to identification area + .byte 0xcf # offset in words to identification area .byte 1 # this byte must be 1 .word 0 # logical block number (word swapped) .word 0 # of the secondary image @@ -74,20 +79,6 @@ from_0x00: # uVAX from TK50 from_0x08: # Any machine from VMB movzbl $4,_C_LABEL(from) # Booted from full VMB - brw start_vmb - -# the complete area reserved for label -# must be empty (i.e. filled with zeroes). -# disklabel(8) checks that before installing -# the bootblocks over existing label. - -.org LABELOFFSET - .globl _C_LABEL(romlabel) -_C_LABEL(romlabel): - .long 0 - -.org LABELOFFSET + d_end_ -start_vmb: /* * Read in block 1-15. */ @@ -102,6 +93,20 @@ start_vmb: calls $6, (%r6) # call the qio-routine brw start_uvax +# the complete area reserved for label +# must be empty (i.e. filled with zeroes). +# disklabel(8) checks that before installing +# the bootblocks over existing label. + +.org LABELOFFSET + .globl _C_LABEL(romlabel) +_C_LABEL(romlabel): + .long 0 + +.org LABELOFFSET + d_end_ +# Make sure the parameter block is past the disklabel. +# If not, the next .org would try to move backwards. + /* * Parameter block for uVAX boot. */ @@ -110,7 +115,7 @@ start_vmb: #define SILOAD 0 /* load offset (usually 0) from the default */ #define SIOFF 0x200 /* byte offset into secondary image */ -.org 0x19e +.org 0x19e # do not move, see comment earlier about CASEL .byte 0x18 # must be 0x18 .byte 0x00 # must be 0x00 (MBZ) .byte 0x00 # any value
CVS commit: src/sys/arch/vax/boot/boot
Module Name:src Committed By: abs Date: Mon May 14 10:05:51 UTC 2012 Modified Files: src/sys/arch/vax/boot/boot: Makefile Log Message: Revert hax to fix boot blocks for gcc 4.5, accudently committed in last To generate a diff of this commit: cvs rdiff -u -r1.39 -r1.40 src/sys/arch/vax/boot/boot/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/Makefile diff -u src/sys/arch/vax/boot/boot/Makefile:1.39 src/sys/arch/vax/boot/boot/Makefile:1.40 --- src/sys/arch/vax/boot/boot/Makefile:1.39 Mon May 14 08:44:13 2012 +++ src/sys/arch/vax/boot/boot/Makefile Mon May 14 10:05:50 2012 @@ -1,12 +1,9 @@ -# $NetBSD: Makefile,v 1.39 2012/05/14 08:44:13 abs Exp $ +# $NetBSD: Makefile,v 1.40 2012/05/14 10:05:50 abs Exp $ S= ${.CURDIR}/../../../.. .include bsd.own.mk -COPTS.boot.c = -O2 -fno-reorder-blocks -COPTS.devopen.c = -O2 -fno-reorder-blocks - PROG= boot DEVS= hp.c ctu.c ra.c mfm.c if_qe.c if_le.c if_ze.c if_de.c if_ni.c SRCS= srt0.S boot.c devopen.c conf.c autoconf.c netio.c rom.c romread.S \
CVS commit: src/sys/arch/vax/boot/boot
Module Name:src Committed By: mrg Date: Sun Jul 3 08:56:25 UTC 2011 Modified Files: src/sys/arch/vax/boot/boot: if_ni.c Log Message: avoid some multi-level pointer cast issues. To generate a diff of this commit: cvs rdiff -u -r1.8 -r1.9 src/sys/arch/vax/boot/boot/if_ni.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/boot/if_ni.c diff -u src/sys/arch/vax/boot/boot/if_ni.c:1.8 src/sys/arch/vax/boot/boot/if_ni.c:1.9 --- src/sys/arch/vax/boot/boot/if_ni.c:1.8 Mon Oct 26 19:16:58 2009 +++ src/sys/arch/vax/boot/boot/if_ni.c Sun Jul 3 08:56:25 2011 @@ -1,4 +1,4 @@ -/* $NetBSD: if_ni.c,v 1.8 2009/10/26 19:16:58 cegger Exp $ */ +/* $NetBSD: if_ni.c,v 1.9 2011/07/03 08:56:25 mrg Exp $ */ /* * Copyright (c) 2000 Ludd, University of Lule}, Sweden. * All rights reserved. @@ -194,6 +194,7 @@ struct ni_msg *msg; struct ni_ptdb *ptdb; int i, va, res; + struct ni_param *nip; if (beenhere++ askname == 0) return 0; @@ -368,7 +369,8 @@ msg-nm_status = 0; msg-nm_len = sizeof(struct ni_param) + 6; msg-nm_opcode2 = NI_WPARAM; - ((struct ni_param *)msg-nm_text[0])-np_flags = NP_PAD; + nip = (struct ni_param *)msg-nm_text[0]; + nip-np_flags = NP_PAD; puton(msg, gvp-nc_forw0, PCR_CMDQNE|PCR_CMDQ0|PCR_OWN); @@ -383,8 +385,7 @@ insput(data, fqb-nf_mforw, PCR_FREEQNE|PCR_MFREEQ|PCR_OWN); } #endif - bcopy(((struct ni_param *)msg-nm_text[0])-np_dpa, - enaddr, ETHER_ADDR_LEN); + bcopy(nip-np_dpa, enaddr, ETHER_ADDR_LEN); insput(data, fqb-nf_mforw, PCR_FREEQNE|PCR_MFREEQ|PCR_OWN); #ifdef NIDEBUG
CVS commit: src/sys/arch/vax/boot/xxboot
Module Name:src Committed By: mhitch Date: Fri Sep 18 21:40:09 UTC 2009 Modified Files: src/sys/arch/vax/boot/xxboot: bootxx.c Log Message: Explicitly include sys/exec_aout.h. To generate a diff of this commit: cvs rdiff -u -r1.35 -r1.36 src/sys/arch/vax/boot/xxboot/bootxx.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/vax/boot/xxboot/bootxx.c diff -u src/sys/arch/vax/boot/xxboot/bootxx.c:1.35 src/sys/arch/vax/boot/xxboot/bootxx.c:1.36 --- src/sys/arch/vax/boot/xxboot/bootxx.c:1.35 Mon Mar 23 13:52:32 2009 +++ src/sys/arch/vax/boot/xxboot/bootxx.c Fri Sep 18 21:40:09 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: bootxx.c,v 1.35 2009/03/23 13:52:32 tsutsui Exp $ */ +/* $NetBSD: bootxx.c,v 1.36 2009/09/18 21:40:09 mhitch Exp $ */ /*- * Copyright (c) 1982, 1986 The Regents of the University of California. @@ -36,6 +36,7 @@ #include sys/disklabel.h #include sys/exec.h #include sys/exec_elf.h +#include sys/exec_aout.h #include lib/libsa/stand.h #include lib/libsa/ufs.h