*** /old/src/sys/OTHERS/rs03.04/hs.c	Wed May  7 17:22:12 1986
--- /usr/src/sys/OTHERS/rs03.04/hs.c	Sun Sep 22 08:47:54 1991
***************
*** 36,42 ****
  struct	hsdevice *HSADDR = (struct hsdevice *)0172040;
  
  struct	buf	hstab;
- struct	buf	rhsbuf;
  
  hsroot()
  {
--- 36,41 ----
***************
*** 161,178 ****
  	hstab.b_actf = bp->av_forw;
  	iodone(bp);
  	hsstart();
- }
- 
- hsread(dev)
- dev_t	dev;
- {
- 	physio(hsstrategy, &rhsbuf, dev, B_READ, WORD);
- }
- 
- hswrite(dev)
- dev_t	dev;
- {
- 	physio(hsstrategy, &rhsbuf, dev, B_WRITE, WORD);
  }
  #endif NHS
  #endif AUTOCONFIG
--- 160,165 ----
*** /old/src/sys/OTHERS/rx01/rx.c	Thu May 28 16:45:13 1987
--- /usr/src/sys/OTHERS/rx01/rx.c	Sun Sep 22 09:16:16 1991
***************
*** 66,72 ****
   * Rx handler work areas
   */
  struct buf rxtab, rxutab[NRX];	/* rxdevice tables */
- struct buf rrxbuf;
  
  /*
   * Rx strategy
--- 66,71 ----
***************
*** 356,370 ****
  		return (0);
  	}
  	return (1);
- }
- 
- rxread (dev)
- {
- 	physio (rxstrategy, &rrxbuf, dev, B_READ);
- }
- 
- rxwrite (dev)
- {
- 	physio (rxstrategy, &rrxbuf, dev, B_WRITE);
  }
  #endif	NRX
--- 355,359 ----
*** /old/src/sys/OTHERS/rx02/#1/rx2.c	Wed May  7 17:38:09 1986
--- /usr/src/sys/OTHERS/rx02/#1/rx2.c	Sun Sep 22 08:51:04 1991
***************
*** 57,63 ****
  #define	seccnt(bp)	((int) ((bp)->b_seccnt))
  
  struct	buf	rx2tab;
- struct	buf	rrx2buf;
  #ifdef RX2_IOCTL
  struct	buf	crx2buf;	/* buffer header for control functions */
  #endif
--- 57,62 ----
***************
*** 296,316 ****
  	if (*addr < bp->b_un.b_addr)		/* overflow, bump xmem */
  		(*xmem)++;
  }
- 
- 
- rx2read(dev)
- dev_t	dev;
- {
- 	physio(rx2strategy, &rrx2buf, dev, B_READ, WORD);
- }
- 
- 
- rx2write(dev)
- dev_t	dev;
- {
- 	physio(rx2strategy, &rrx2buf, dev, B_WRITE, WORD);
- }
- 
  
  #ifdef RX2_IOCTL
  /*
--- 295,300 ----
*** /old/src/sys/OTHERS/rx02/#2/rx.c	Thu Sep  1 14:14:06 1988
--- /usr/src/sys/OTHERS/rx02/#2/rx.c	Sun Sep 22 08:50:38 1991
***************
*** 53,59 ****
  #define	seccnt(bp)	((int)((bp)->b_seccnt))
  
  struct	buf	rxtab;
- struct	buf	rrxbuf;
  struct	buf	crxbuf;		/* buffer header for control functions */
  
  /*
--- 53,58 ----
***************
*** 333,351 ****
  	*xmem = bp->b_xmem;
  	if (*addr < bp->b_un.b_addr)		/* overflow, bump xmem */
  		(*xmem)++;
- }
- 
- rxread(dev)
- 	dev_t dev;
- {
- 	return (physio(rxstrategy, &rrxbuf, dev, B_READ, WORD));
- }
- 
- 
- rxwrite(dev)
- 	dev_t dev;
- {
- 	return (physio(rxstrategy, &rrxbuf, dev, B_WRITE, WORD));
  }
  
  /*
--- 332,337 ----
*** /old/src/sys/OTHERS/scsi/scsi.c	Mon Feb 23 18:43:38 1987
--- /usr/src/sys/OTHERS/scsi/scsi.c	Sun Sep 22 08:56:20 1991
***************
*** 117,123 ****
  char	Initdata[8];
  
  struct	buf	imitab;
- struct	buf	rimibuf;
  
  unsigned	imixblks;	/* Number of blks transferred */
  static		int Didinit = 0;
--- 117,122 ----
***************
*** 331,349 ****
  	bp->b_resid = 0;
  	iodone(bp);
  	imistart(0);
- }
- 
- imiread(dev)
- dev_t dev;
- {
- 
- 	physio(imistrategy, &rimibuf, dev, B_READ, WORD);
- }
- 
- imiwrite(dev)
- dev_t dev;
- {
- 
- 	physio(imistrategy, &rimibuf, dev, B_WRITE, WORD);
  }
  #endif NIMI
--- 330,334 ----
*** /old/src/sys/OTHERS/scsi2/xe.c	Thu May 28 16:45:14 1987
--- /usr/src/sys/OTHERS/scsi2/xe.c	Sun Sep 22 09:16:39 1991
***************
*** 33,39 ****
  struct xedevice *XEADDR = (struct xedevice *) 0177460;
  
  struct buf	xetab;
- struct buf	rxebuf;
  struct xecommand xec;
  u_short	xecaddr[2];
  struct xeinit	xei[NXE];
--- 33,38 ----
***************
*** 474,490 ****
  		iodone (bp);
  	}
  	xestart ();
- }
- 
- xeread (dev)
- dev_t	dev;
- {
- 	physio (xestrategy, &rxebuf, dev, B_READ);
- }
- 
- xewrite (dev)
- dev_t	dev;
- {	
- 	physio (xestrategy, &rxebuf, dev, B_WRITE);
  }
  #endif NXE
--- 473,477 ----
*** /old/src/sys/OTHERS/tektronix/tektronix	Wed May 27 22:35:45 1987
--- /usr/src/sys/OTHERS/tektronix/tektronix	Sun Sep 22 09:15:48 1991
***************
*** 103,110 ****
  	(*cdevsw[major(fast_map[d])].d_read)(fast_map[d]);
  }
  
! fast_write(dev)
  dev_t	dev;
  {
  	register d;
  	register struct device *addr;
--- 103,111 ----
  	(*cdevsw[major(fast_map[d])].d_read)(fast_map[d]);
  }
  
! fast_write(dev, uio)
  dev_t	dev;
+ struct uio *uio;
  {
  	register d;
  	register struct device *addr;
***************
*** 130,136 ****
  			fast[d].bc = u.u_count;
  			if(u.u_count&1)
  				u.u_count++;
! 			physio(fast_start, &fast_buf, dev, B_WRITE);
  		}
  	}
  	else
--- 131,137 ----
  			fast[d].bc = u.u_count;
  			if(u.u_count&1)
  				u.u_count++;
! 			physio(fast_start, &fast_buf, dev, B_WRITE, uio);
  		}
  	}
  	else
*** /old/src/sys/OTHERS/tk/pdpuba/tk.c	Sat Aug 13 14:59:01 1988
--- /usr/src/sys/OTHERS/tk/pdpuba/tk.c	Sun Sep 22 09:22:10 1991
***************
*** 82,88 ****
  
  struct	buf tktab[];	/* controller queue */
  struct	buf tkwtab;	/* I/O wait queue */
- struct	buf rtkbuf[];	/* RAW I/O buffer header, one per drive */
  struct	buf ctkbuf[];	/* buffer for tkcmd */
  
  /*
--- 82,87 ----
***************
*** 1173,1196 ****
  		return(mp);
  	}
  	return(NULL);
- }
- 
- tkread(dev)
- 	dev_t dev;
- {
- 	register unit;
- 
- 	unit = minor(dev) & 7;
- 	physio(tkstrategy, &rtkbuf[unit], dev, B_READ);
- }
- 
- tkwrite(dev)
- 	dev_t dev;
- {
- 	register unit;
- 
- 	unit = minor(dev) & 7;
- 	physio(tkstrategy, &rtkbuf[unit], dev, B_WRITE);
  }
  
  tkfatal(unit, tkp, st, sa)
--- 1172,1177 ----
*** /old/src/sys/OTHERS/ts/ts.c_Q22	Thu Jun 19 14:50:26 1986
--- /usr/src/sys/OTHERS/ts/ts.c_Q22	Sun Sep 22 09:21:25 1991
***************
*** 46,59 ****
  
  struct	buf	tstab;
  struct	buf	ctsbuf;
- /*
-  * Raw tape operations use rtsbuf.  The driver
-  * notices when rtsbuf is being used and allows the user
-  * program to continue after errors and read records
-  * not of the standard length (BSIZE).
-  */
- struct	buf	rtsbuf;
- 
  struct	tsdevice *TSADDR;
  
  #define	INF		((daddr_t) ((u_short) 65535))
--- 46,51 ----
***************
*** 205,215 ****
--- 197,217 ----
  register struct buf *bp;
  {
  	register s;
+ 	register struct ts_softc *sc;
  
  #ifdef UNIBUS_MAP
  	if (bp != &ctsbuf)
  		mapalloc(bp);
  #endif
+ 
+ /*
+  * This is almost certainly wrong.  See /sys/pdpuba/ts.c for how it's
+  * really done.
+ */
+ 	sc = &ts_softc[TSUNIT(bp->b_dev)];
+ 	sc->sc_blkno = dbtofsb(u.u_offset >> 9);
+ 	sc->sc_nxrec = sc->sc_blkno + 1;
+ 
  	bp->av_forw = NULL;
  	s = spl5();
  	if (tstab.b_actf == NULL)
***************
*** 412,418 ****
  				 * was too long or too short, then we don't
  				 * consider this an error.
  				 */
! 				if (bp == &rtsbuf && (bp->b_flags & B_READ)
  				    && sc->sc_sts.s_xs0 & (TS_RLS | TS_RLL))
  					goto ignoreerr;
  					/*NOTREACHED*/
--- 414,420 ----
  				 * was too long or too short, then we don't
  				 * consider this an error.
  				 */
! 				if (bp->b_flags & B_PHYS && (bp->b_flags & B_READ)
  				    && sc->sc_sts.s_xs0 & (TS_RLS | TS_RLL))
  					goto ignoreerr;
  					/*NOTREACHED*/
***************
*** 433,439 ****
  					 * Non-i/o errors on non-raw tape
  					 * cause it to close.
  					 */
! 					if (sc->sc_openf > 0 && bp != &rtsbuf)
  						sc->sc_openf = -1;
  				}
  				break;
--- 435,441 ----
  					 * Non-i/o errors on non-raw tape
  					 * cause it to close.
  					 */
! 					if (sc->sc_openf > 0 && !(bp->b_flags & B_PHYS))
  						sc->sc_openf = -1;
  				}
  				break;
***************
*** 572,603 ****
  			return (1);
  	}
  	return(0);
- }
- 
- tsread(dev)
- register dev_t	dev;
- {
- 	tsphys(dev);
- 	bphysio(tsstrategy, &rtsbuf, dev, B_READ);
- }
- 
- tswrite(dev)
- register dev_t	dev;
- {
- 	tsphys(dev);
- 	bphysio(tsstrategy, &rtsbuf, dev, B_WRITE);
- }
- 
- tsphys(dev)
- dev_t	dev;
- {
- 	register struct ts_softc *sc;
- 	daddr_t	a;
- 
- 	sc = &ts_softc[TSUNIT(dev)];
- 	a = dbtofsb(u.u_offset >> 9);
- 	sc->sc_blkno = a;
- 	sc->sc_nxrec = a + 1;
  }
  
  #ifdef	TS_IOCTL
--- 574,579 ----
*** /old/src/sys/OTHERS/versatec/vp.c	Wed Apr 11 14:44:30 1990
--- /usr/src/sys/OTHERS/versatec/vp.c	Sun Sep 22 09:13:23 1991
***************
*** 137,143 ****
  		uio->uio_resid++;
  	if (vperror())
  		return;
! 	return (physio(vpstart, &vpbuf, dev, B_WRITE, WORD, uio));
  	/* note that newer 1200A's print @ 1000 lines/min = 2.2kbytes/sec */
  }
  
--- 137,143 ----
  		uio->uio_resid++;
  	if (vperror())
  		return;
! 	return (physio(vpstart, &vpbuf, dev, B_WRITE, uio));
  	/* note that newer 1200A's print @ 1000 lines/min = 2.2kbytes/sec */
  }
  
*** /old/src/sys/autoconfig/Makefile	Tue Aug 14 13:57:37 1990
--- /usr/src/sys/autoconfig/Makefile	Sun Dec 22 15:58:54 1991
***************
*** 2,24 ****
  # Makefile for the system autoconfiguration program
  #
  DESTDIR=
- N=	../pdpif
- M=	../machine
- D=	../pdpuba
  
  OBJS=	attach.o do_config.o main.o read_dtab.o read_nlist.o uprobe.o	\
  	brauto.o cnauto.o dhauto.o dhuauto.o drauto.o dzauto.o		\
  	hkauto.o htauto.o lpauto.o raauto.o rkauto.o rlauto.o siauto.o	\
! 	tmauto.o tsauto.o xpauto.o rxauto.o dnauto.o tmsauto.o
  SRCS=	attach.c do_config.c main.c read_dtab.c read_nlist.c uprobe.c	\
! 	${D}/brauto.c ${M}/cnauto.c ${D}/dhauto.c ${D}/dhuauto.c	\
! 	${D}/drauto.c ${D}/dzauto.c ${D}/hkauto.c ${D}/htauto.c		\
! 	${D}/lpauto.c ${D}/raauto.c ${D}/rkauto.c ${D}/rlauto.c		\
! 	${D}/siauto.c ${D}/tmauto.c ${D}/tsauto.c ${D}/xpauto.c		\
! 	${D}/rxauto.c ${D}/dnauto.c ${D}/tmsauto.c
  
! VPATH=	.:../pdpif:../machine:../pdpuba
! CFLAGS=	-O -I. -I../h
  LFLAG=	-i
  
  autoconfig: ${OBJS}
--- 2,20 ----
  # Makefile for the system autoconfiguration program
  #
  DESTDIR=
  
  OBJS=	attach.o do_config.o main.o read_dtab.o read_nlist.o uprobe.o	\
  	brauto.o cnauto.o dhauto.o dhuauto.o drauto.o dzauto.o		\
  	hkauto.o htauto.o lpauto.o raauto.o rkauto.o rlauto.o siauto.o	\
! 	tmauto.o tsauto.o xpauto.o rxauto.o dnauto.o tmsauto.o dhvauto.o
  SRCS=	attach.c do_config.c main.c read_dtab.c read_nlist.c uprobe.c	\
! 	brauto.c cnauto.c dhauto.c dhuauto.c	\
! 	drauto.c dzauto.c hkauto.c htauto.c		\
! 	lpauto.c raauto.c rkauto.c rlauto.c		\
! 	siauto.c tmauto.c tsauto.c xpauto.c		\
! 	rxauto.c dnauto.c tmsauto.c dhvauto.c
  
! CFLAGS=	-O -I. -I../h -I../pdpuba -I../pdp
  LFLAG=	-i
  
  autoconfig: ${OBJS}
*** /old/src/sys/autoconfig/rlauto.c	Fri Apr 29 20:05:41 1988
--- /usr/src/sys/autoconfig/rlauto.c	Wed Jan  8 20:40:41 1992
***************
*** 3,9 ****
   * All rights reserved.  The Berkeley software License Agreement
   * specifies the terms and conditions for redistribution.
   *
!  *	@(#)rlauto.c	1.1 (2.10BSD Berkeley) 12/1/86
   */
  
  #include "param.h"
--- 3,9 ----
   * All rights reserved.  The Berkeley software License Agreement
   * specifies the terms and conditions for redistribution.
   *
!  *	@(#)rlauto.c	2.0 (2.11BSD Berkeley) 1/8/92
   */
  
  #include "param.h"
***************
*** 15,21 ****
  rlprobe(addr)
  	struct rldevice *addr;
  {
! 	stuff(RL_NOP | RL_IE, (&(addr->rlcs)));
  	DELAY(10L);
  	stuff(RL_CRDY, (&(addr->rlcs)));
  	return(ACP_IFINTR);
--- 15,23 ----
  rlprobe(addr)
  	struct rldevice *addr;
  {
! 	stuff(RLDA_RESET | RLDA_GS, (&(addr->rlda)));
! 	DELAY(10L);
! 	stuff(RL_GETSTATUS | RL_IE , (&(addr->rlcs)));
  	DELAY(10L);
  	stuff(RL_CRDY, (&(addr->rlcs)));
  	return(ACP_IFINTR);
*** /old/src/sys/autoconfig/tsauto.c	Fri Sep 30 05:35:33 1988
--- /usr/src/sys/autoconfig/tsauto.c	Tue Dec 10 09:27:56 1991
***************
*** 3,9 ****
   * All rights reserved.  The Berkeley software License Agreement
   * specifies the terms and conditions for redistribution.
   *
!  *	@(#)tsauto.c	1.1 (2.10BSD Berkeley) 12/1/86
   */
  
  #include "param.h"
--- 3,9 ----
   * All rights reserved.  The Berkeley software License Agreement
   * specifies the terms and conditions for redistribution.
   *
!  *	@(#)tsauto.c	2.0 (2.11BSD) 12/9/91
   */
  
  #include "param.h"
***************
*** 10,31 ****
  #include "../machine/autoconfig.h"
  #include "../machine/machparam.h"
  
! #include "tmreg.h"
  
  tsprobe(addr)
! 	struct tsdevice *addr;
  {
  	extern int errno;
  
  	/*
  	 * Unfortunately the TS and TM CSRs overlap.  So simply testing for
! 	 * presence of a TS register isn't good enough.  So we try to do a
! 	 * TM select of drive 2.  If we get a bus fault or if the select
! 	 * works, we don't have a TS.
  	 */
  	errno = 0;
! 	stuff(01000, &(((struct tmdevice *)addr)->tmcs));
! 	if (errno || (grab(&(((struct tmdevice *)addr)->tmcs)) & 01000))
  		return(ACP_NXDEV);
! 	return(ACP_EXISTS);
  }
--- 10,35 ----
  #include "../machine/autoconfig.h"
  #include "../machine/machparam.h"
  
! #include "tsreg.h"
  
  tsprobe(addr)
! 	register struct tsdevice *addr;
  {
  	extern int errno;
  
  	/*
  	 * Unfortunately the TS and TM CSRs overlap.  So simply testing for
! 	 * presence of a TS register isn't good enough.  We borrow from
! 	 * the "universal" tape boot block by poking the controller and
! 	 * looking for the "need buffer address" bit from a TS.  If that
! 	 * bit fails to come on the device is not a TS.
  	 */
  	errno = 0;
! 	stuff(0, &addr->tssr);		/* poke the controller */
! 	if (errno)			/* paranoia */
  		return(ACP_NXDEV);
! 	DELAY(100L);			/* give TS time for diagnostics */
! 	if (grab(&addr->tssr) & TS_NBA)	/* need buffer address bit on? */
! 		return(ACP_EXISTS);	/* yes = return existence */
! 	return(ACP_NXDEV);		/* not a TS */
  }
*** /old/src/sys/autoconfig/uprobe.c	Tue Aug 14 13:56:39 1990
--- /usr/src/sys/autoconfig/uprobe.c	Sun Dec 22 16:00:36 1991
***************
*** 3,9 ****
   * All rights reserved.  The Berkeley software License Agreement
   * specifies the terms and conditions for redistribution.
   *
!  *	@(#)uprobe.c	1.1 (2.10BSD Berkeley) 12/1/86
   */
  
  /*
--- 3,9 ----
   * All rights reserved.  The Berkeley software License Agreement
   * specifies the terms and conditions for redistribution.
   *
!  *	@(#)uprobe.c	1.2 (2.11BSD Berkeley) 12/22/91
   */
  
  /*
***************
*** 25,31 ****
  int	xpprobe(), hkprobe(), rlprobe(), rkprobe(), htprobe(), siprobe(),
  	tmprobe(), tsprobe(), cnprobe(), dzprobe(), dhprobe(), dmprobe(),
  	drprobe(), lpprobe(), dhuprobe(), raprobe(), rxprobe(), brprobe(),
! 	dnprobe(), tmsprobe();
  
  UPROBE uprobe[] = {
  	"hk",	hkprobe,	/* hk -- rk611, rk06/07 */
--- 25,31 ----
  int	xpprobe(), hkprobe(), rlprobe(), rkprobe(), htprobe(), siprobe(),
  	tmprobe(), tsprobe(), cnprobe(), dzprobe(), dhprobe(), dmprobe(),
  	drprobe(), lpprobe(), dhuprobe(), raprobe(), rxprobe(), brprobe(),
! 	dnprobe(), tmsprobe(), dhvprobe();
  
  UPROBE uprobe[] = {
  	"hk",	hkprobe,	/* hk -- rk611, rk06/07 */
***************
*** 41,47 ****
  	"dh",	dhprobe,	/* dh -- DH11 */
  	"dm",	dmprobe,	/* dm -- DM11 */
  	"dr",	drprobe,	/* dr -- DR11W */
! 	"du",	dhuprobe,	/* du -- dhu, dhv */
  	"dz",	dzprobe,	/* dz -- dz11 */
  	"cn",	cnprobe,	/* cn -- kl11, dl11 */
  	"lp",	lpprobe,	/* lp -- line printer */
--- 41,48 ----
  	"dh",	dhprobe,	/* dh -- DH11 */
  	"dm",	dmprobe,	/* dm -- DM11 */
  	"dr",	drprobe,	/* dr -- DR11W */
! 	"du",	dhuprobe,	/* du -- DHU11 */
! 	"dhv",	dhvprobe,	/* dhv -- DHV11 */
  	"dz",	dzprobe,	/* dz -- dz11 */
  	"cn",	cnprobe,	/* cn -- kl11, dl11 */
  	"lp",	lpprobe,	/* lp -- line printer */
*** /old/src/sys/conf/GENERIC	Wed Dec 19 10:13:42 1990
--- /usr/src/sys/conf/GENERIC	Sun Dec 22 16:09:46 1991
***************
*** 208,215 ****
  # buffers for a 1K file system, NBUF would be 128.  A possible exception would
  # be to reduce the buffers to save on data space, as they were 24 bytes per
  # header, last time I looked.
! # should be 20 for GENERIC, so room for kernel + large program to run.
! NBUF		20			# buffer cache, *must* be <= 240
  
  # MAXMEM is the maximum core per process is allowed.  First number
  # is Kb.
--- 208,215 ----
  # buffers for a 1K file system, NBUF would be 128.  A possible exception would
  # be to reduce the buffers to save on data space, as they were 24 bytes per
  # header, last time I looked.
! # should be 'small' for GENERIC, so room for kernel + large program to run.
! NBUF		32			# buffer cache, *must* be <= 240
  
  # MAXMEM is the maximum core per process is allowed.  First number
  # is Kb.
***************
*** 336,342 ****
  NKL		1		# KL11, DL11
  NDH		0		# DH11; NDH is in units of boards (16 each)
  NDM		0		# DM11; NDM is in units of boards (16 each)
! NDHU		0		# DHU11, DHV11
  NDZ		0		# DZ11; NDZ is in units of boards (8 each)
  
  #########################################
--- 336,343 ----
  NKL		1		# KL11, DL11
  NDH		0		# DH11; NDH is in units of boards (16 each)
  NDM		0		# DM11; NDM is in units of boards (16 each)
! NDHU		0		# DHU11
! NDHV		0		# DHV11
  NDZ		0		# DZ11; NDZ is in units of boards (8 each)
  
  #########################################
*** /old/src/sys/conf/KAZOO	Wed Dec 19 10:12:43 1990
--- /usr/src/sys/conf/KAZOO	Sun Dec 22 16:11:27 1991
***************
*** 337,343 ****
  NKL		1		# KL11, DL11
  NDH		0		# DH11; NDH is in units of boards (16 each)
  NDM		0		# DM11; NDM is in units of boards (16 each)
! NDHU		0		# DHU11, DHV11
  NDZ		1		# DZ11; NDZ is in units of boards (8 each)
  
  #########################################
--- 337,344 ----
  NKL		1		# KL11, DL11
  NDH		0		# DH11; NDH is in units of boards (16 each)
  NDM		0		# DM11; NDM is in units of boards (16 each)
! NDHU		0		# DHU11
! NDHV		0		# DHV11
  NDZ		1		# DZ11; NDZ is in units of boards (8 each)
  
  #########################################
*** /old/src/sys/conf/LONEX	Wed Dec 19 10:14:24 1990
--- /usr/src/sys/conf/LONEX	Sat Jun  6 00:21:28 1992
***************
*** 86,93 ****
  # 44, 45, 50, 53, 55, 60, 70, 73, 83, 84.  GENERIC should only be used to
  # build a distribution kernel.
  #PDP11		GENERIC			# distribution kernel
! #PDP11		44			# PDP-11/44
! PDP11		70			# PDP-11/70
  #PDP11		73			# PDP-11/73
  
  #########################################
--- 86,93 ----
  # 44, 45, 50, 53, 55, 60, 70, 73, 83, 84.  GENERIC should only be used to
  # build a distribution kernel.
  #PDP11		GENERIC			# distribution kernel
! PDP11		44			# PDP-11/44
! #PDP11		70			# PDP-11/70
  #PDP11		73			# PDP-11/73
  
  #########################################
***************
*** 112,121 ****
  #BOOTDEV	si			# si 9500 boot device
  
  # Timezone, in minutes west of GMT
! TIMEZONE	300			# EST
  #TIMEZONE	360			# CST
  #TIMEZONE	420			# WST
! #TIMEZONE	480			# PST
  DST		1			# Daylight Savings Time (1 or 0)
  
  # Filesystem configuration
--- 112,121 ----
  #BOOTDEV	si			# si 9500 boot device
  
  # Timezone, in minutes west of GMT
! #TIMEZONE	300			# EST
  #TIMEZONE	360			# CST
  #TIMEZONE	420			# WST
! TIMEZONE	480			# PST
  DST		1			# Daylight Savings Time (1 or 0)
  
  # Filesystem configuration
***************
*** 210,216 ****
  # be to reduce the buffers to save on data space, as they were 24 bytes per
  # header, last time I looked.
  # should be 20 for GENERIC, so room for kernel + large program to run.
! NBUF		64			# buffer cache, *must* be <= 240
  
  # MAXMEM is the maximum core per process is allowed.  First number
  # is Kb.
--- 210,216 ----
  # be to reduce the buffers to save on data space, as they were 24 bytes per
  # header, last time I looked.
  # should be 20 for GENERIC, so room for kernel + large program to run.
! NBUF		96			# buffer cache, *must* be <= 240
  
  # MAXMEM is the maximum core per process is allowed.  First number
  # is Kb.
***************
*** 325,331 ****
  
  NTMSCP		0		# TMSCP controllers
  NTMS		0		# TMSCP drives
! TMSCP_DEBUG	YES		# debugging code in TMSCP drive (EXPENSIVE)
  TMSCP_VEC	0260		# base of TMSCP interrupt vectors (OCTAL!!!)
  
  #########################################
--- 325,331 ----
  
  NTMSCP		0		# TMSCP controllers
  NTMS		0		# TMSCP drives
! TMSCP_DEBUG	NO		# debugging code in TMSCP drive (EXPENSIVE)
  TMSCP_VEC	0260		# base of TMSCP interrupt vectors (OCTAL!!!)
  
  #########################################
***************
*** 334,343 ****
  
  # NKL includes both KL11's and DL11's.
  # It should always be at least 1, for the console.
! NKL		2		# KL11, DL11
  NDH		3		# DH11; NDH is in units of boards (16 each)
  NDM		3		# DM11; NDM is in units of boards (16 each)
! NDHU		0		# DHU11, DHV11
  NDZ		0		# DZ11; NDZ is in units of boards (8 each)
  
  #########################################
--- 334,344 ----
  
  # NKL includes both KL11's and DL11's.
  # It should always be at least 1, for the console.
! NKL		1		# KL11, DL11
  NDH		3		# DH11; NDH is in units of boards (16 each)
  NDM		3		# DM11; NDM is in units of boards (16 each)
! NDHU		0		# DHU11
! NDHV		0		# DHV11
  NDZ		0		# DZ11; NDZ is in units of boards (8 each)
  
  #########################################
*** /old/src/sys/conf/Make.nsunix	Sun Nov 11 14:49:16 1990
--- /usr/src/sys/conf/Make.nsunix	Sat Jul 11 23:13:10 1992
***************
*** 58,64 ****
  	libc_remque.o libc_strlen.o libc_udiv.o net_copy.o net_csv.o \
  	net_mbuf.o net_scb.o net_SKcall.o net_trap.o net_xxx.o
  
! BASE=	br.o cons.o dh.o dhu.o dr.o dz.o hk.o ht.o init_sysent.o \
  	kern_clock.o kern_descrip.o kern_mman.o kern_proc.o kern_prot.o \
  	kern_subr.o kern_synch.o kern_xxx.o lp.o machdep.o ra.o ram.o \
  	rk.o rl.o rx.o si.o subr_rmap.o sys_inode.o sys_kern.o \
--- 58,64 ----
  	libc_remque.o libc_strlen.o libc_udiv.o net_copy.o net_csv.o \
  	net_mbuf.o net_scb.o net_SKcall.o net_trap.o net_xxx.o
  
! BASE=	br.o cons.o dh.o dhu.o dhv.o dr.o dz.o hk.o ht.o init_sysent.o \
  	kern_clock.o kern_descrip.o kern_mman.o kern_proc.o kern_prot.o \
  	kern_subr.o kern_synch.o kern_xxx.o lp.o machdep.o ra.o ram.o \
  	rk.o rl.o rx.o si.o subr_rmap.o sys_inode.o sys_kern.o \
***************
*** 74,80 ****
  	sys_pipe.o
  # OV6 gets the (hopefully) never used routines
  OV6=	clock.o dn.o init_main.o kern_pdp.o machdep2.o subr_prf.o syscalls.o \
! 	subr_log.o
  OV7=	tmscp.o
  
  KERNOBJ=${CONF} ${BASE} ${OV1} ${OV2} ${OV3} ${OV4} ${OV5} \
--- 74,80 ----
  	sys_pipe.o
  # OV6 gets the (hopefully) never used routines
  OV6=	clock.o dn.o init_main.o kern_pdp.o machdep2.o subr_prf.o syscalls.o \
! 	subr_log.o toy.o
  OV7=	tmscp.o
  
  KERNOBJ=${CONF} ${BASE} ${OV1} ${OV2} ${OV3} ${OV4} ${OV5} \
*** /old/src/sys/conf/Make.pdp	Fri Sep  2 20:20:58 1988
--- /usr/src/sys/conf/Make.pdp	Sat Jul 11 23:07:00 1992
***************
*** 32,43 ****
  	${M}/mch_click.s ${M}/mch_copy.s ${M}/mch_csv.s ${M}/mch_dump.s \
  	${M}/mch_dzpdma.s ${M}/mch_fpsim.s ${M}/mch_KScall.s \
  	${M}/mch_profile.s ${M}/mch_start.s ${M}/mch_trap.s \
! 	${M}/mch_vars.s ${M}/mch_xxx.s ${M}/scb.s
  SOBJS=	libc_bcmp.o libc_bcopy.o libc_bzero.o libc_ffs.o libc_insque.o \
  	libc_ldiv.o libc_lmul.o libc_lrem.o libc_remque.o libc_strlen.o \
  	libc_udiv.o mch_backup.o mch_click.o mch_copy.o mch_csv.o \
  	mch_dump.o mch_dzpdma.o mch_fpsim.o mch_KScall.o mch_profile.o \
! 	mch_start.o mch_trap.o mch_vars.o mch_xxx.o scb.o
  
  .c.o:
  	${CC} ${CFLAGS} -S $*.c
--- 32,43 ----
  	${M}/mch_click.s ${M}/mch_copy.s ${M}/mch_csv.s ${M}/mch_dump.s \
  	${M}/mch_dzpdma.s ${M}/mch_fpsim.s ${M}/mch_KScall.s \
  	${M}/mch_profile.s ${M}/mch_start.s ${M}/mch_trap.s \
! 	${M}/mch_vars.s ${M}/mch_xxx.s ${M}/scb.s ${M}/toy.s
  SOBJS=	libc_bcmp.o libc_bcopy.o libc_bzero.o libc_ffs.o libc_insque.o \
  	libc_ldiv.o libc_lmul.o libc_lrem.o libc_remque.o libc_strlen.o \
  	libc_udiv.o mch_backup.o mch_click.o mch_copy.o mch_csv.o \
  	mch_dump.o mch_dzpdma.o mch_fpsim.o mch_KScall.o mch_profile.o \
! 	mch_start.o mch_trap.o mch_vars.o mch_xxx.o scb.o toy.o
  
  .c.o:
  	${CC} ${CFLAGS} -S $*.c
*** /old/src/sys/conf/Make.pdpuba	Sun Jul  1 00:10:07 1990
--- /usr/src/sys/conf/Make.pdpuba	Sun Dec 22 16:16:21 1991
***************
*** 14,23 ****
  U=	../pdpuba
  VPATH=	../pdpuba
  
! CFILES=	${U}/br.c ${U}/dh.c ${U}/dn.c ${U}/dhu.c ${U}/dkbad.c ${U}/dr.c \
! 	${U}/dz.c ${U}/hk.c ${U}/ht.c ${U}/lp.c ${U}/ra.c ${U}/rk.c \
  	${U}/rl.c ${U}/rx.c ${U}/si.c ${U}/tm.c ${U}/tmscp.c ${U}/ts.c ${U}/xp.c
! OBJS=	br.o dh.o dhu.o dkbad.o dn.o dr.o dz.o hk.o ht.o lp.o ra.o rk.o \
  	rl.o rx.o si.o tm.o tmscp.o ts.o xp.o dn.o
  
  .c.o:
--- 14,23 ----
  U=	../pdpuba
  VPATH=	../pdpuba
  
! CFILES=	${U}/br.c ${U}/dh.c ${U}/dn.c ${U}/dhu.c ${U}/dhv.c ${U}/dkbad.c \
! 	${U}/dr.c ${U}/dz.c ${U}/hk.c ${U}/ht.c ${U}/lp.c ${U}/ra.c ${U}/rk.c \
  	${U}/rl.c ${U}/rx.c ${U}/si.c ${U}/tm.c ${U}/tmscp.c ${U}/ts.c ${U}/xp.c
! OBJS=	br.o dh.o dhu.o dhv.o dkbad.o dn.o dr.o dz.o hk.o ht.o lp.o ra.o rk.o \
  	rl.o rx.o si.o tm.o tmscp.o ts.o xp.o dn.o
  
  .c.o:
*** /old/src/sys/conf/Make.sunix	Sun Nov 11 14:49:30 1990
--- /usr/src/sys/conf/Make.sunix	Sat Jul 11 23:13:33 1992
***************
*** 45,63 ****
  	mch_dump.o mch_dzpdma.o mch_fpsim.o mch_profile.o mch_start.o \
  	mch_trap.o mch_vars.o mch_xxx.o conf.o ioconf.o boot.o
  
! BASE=	br.o dh.o dhu.o dkbad.o dr.o dz.o hk.o init_sysent.o kern_clock.o \
  	kern_descrip.o kern_mman.o kern_proc.o kern_sig.o kern_subr.o \
  	kern_synch.o lp.o machdep.o ra.o ram.o rk.o rl.o rx.o si.o \
  	subr_rmap.o subr_xxx.o sys_inode.o sys_pipe.o trap.o tty.o \
  	tty_conf.o tty_subr.o tty_tb.o tty_tty.o ufs_alloc.o ufs_bio.o \
  	ufs_bmap.o ufs_dsort.o ufs_fio.o ufs_inode.o ufs_namei.o \
! 	ufs_subr.o vm_proc.o vm_sched.o vm_swap.o vm_swp.o vm_text.o xp.o
! OV1=	kern_prot.o sys_generic.o ufs_syscalls.o mem.o
  OV2=	kern_acct.o kern_exec.o kern_exit.o kern_fork.o kern_resource.o
! OV3=	clock.o cons.o init_main.o kern_pdp.o kern_rtp.o kern_time.o \
  	kern_xxx.o machdep2.o quota_sys.o subr_prf.o sys_process.o \
  	syscalls.o ufs_mount.o
! OV4=	tty_pty.o quota_kern.o quota_subr.o quota_ufs.o subr_log.o
  OV5=	ht.o tm.o ts.o
  OV6=	tmscp.o
  
--- 45,64 ----
  	mch_dump.o mch_dzpdma.o mch_fpsim.o mch_profile.o mch_start.o \
  	mch_trap.o mch_vars.o mch_xxx.o conf.o ioconf.o boot.o
  
! BASE=	br.o dh.o dhu.o dhv.o dkbad.o dr.o dz.o init_sysent.o kern_clock.o \
  	kern_descrip.o kern_mman.o kern_proc.o kern_sig.o kern_subr.o \
  	kern_synch.o lp.o machdep.o ra.o ram.o rk.o rl.o rx.o si.o \
  	subr_rmap.o subr_xxx.o sys_inode.o sys_pipe.o trap.o tty.o \
  	tty_conf.o tty_subr.o tty_tb.o tty_tty.o ufs_alloc.o ufs_bio.o \
  	ufs_bmap.o ufs_dsort.o ufs_fio.o ufs_inode.o ufs_namei.o \
! 	ufs_subr.o vm_sched.o vm_swp.o vm_text.o xp.o
! OV1=	sys_generic.o ufs_syscalls.o mem.o
  OV2=	kern_acct.o kern_exec.o kern_exit.o kern_fork.o kern_resource.o
! OV3=	clock.o cons.o kern_pdp.o kern_rtp.o kern_time.o \
  	kern_xxx.o machdep2.o quota_sys.o subr_prf.o sys_process.o \
  	syscalls.o ufs_mount.o
! OV4=	hk.o init_main.o kern_prot.o tty_pty.o quota_kern.o quota_subr.o \
! 	quota_ufs.o subr_log.o vm_swap.o vm_proc.o toy.o
  OV5=	ht.o tm.o ts.o
  OV6=	tmscp.o
  
*** /old/src/sys/conf/Make.unix	Sun Nov 11 14:49:43 1990
--- /usr/src/sys/conf/Make.unix	Sat Jul 11 23:14:10 1992
***************
*** 48,54 ****
  # This overlay setup is far too configuration dependent, with both text
  # and data trying to share one address space.  You're on you're own here ...
  #
! BASE=	br.o clock.o cons.o dh.o dhu.o dkbad.o dn.o dr.o dz.o hk.o ht.o  \
  	init_main.o init_sysent.o kern_acct.o kern_clock.o kern_descrip.o \
  	kern_exec.o kern_exit.o kern_fork.o kern_mman.o kern_pdp.o \
  	kern_proc.o kern_prot.o kern_resource.o kern_rtp.o kern_sig.o \
--- 48,54 ----
  # This overlay setup is far too configuration dependent, with both text
  # and data trying to share one address space.  You're on you're own here ...
  #
! BASE=	br.o clock.o cons.o dh.o dhu.o dhv.o dkbad.o dn.o dr.o dz.o hk.o ht.o  \
  	init_main.o init_sysent.o kern_acct.o kern_clock.o kern_descrip.o \
  	kern_exec.o kern_exit.o kern_fork.o kern_mman.o kern_pdp.o \
  	kern_proc.o kern_prot.o kern_resource.o kern_rtp.o kern_sig.o \
***************
*** 55,65 ****
  	kern_subr.o kern_synch.o kern_time.o kern_xxx.o lp.o machdep.o \
  	machdep2.o mem.o quota_kern.o quota_subr.o quota_sys.o \
  	quota_ufs.o ra.o ram.o rk.o rl.o rx.o si.o subr_prf.o subr_rmap.o \
! 	subr_xxx.o sys_generic.o sys_inode.o sys_kern.o 		\
  	sys_pipe.o sys_process.o syscalls.o tm.o trap.o tmscp.o ts.o tty.o \
  	tty_conf.o tty_pty.o tty_subr.o tty_tb.o tty_tty.o ufs_alloc.o \
  	ufs_bio.o ufs_bmap.o ufs_dsort.o ufs_fio.o ufs_inode.o \
! 	ufs_mount.o ufs_namei.o ufs_subr.o ufs_syscalls.o uipc_syscalls.o \
  	vm_proc.o vm_sched.o vm_swap.o vm_swp.o vm_text.o xp.o subr_log.o
  OV1=	
  OV2=	
--- 55,65 ----
  	kern_subr.o kern_synch.o kern_time.o kern_xxx.o lp.o machdep.o \
  	machdep2.o mem.o quota_kern.o quota_subr.o quota_sys.o \
  	quota_ufs.o ra.o ram.o rk.o rl.o rx.o si.o subr_prf.o subr_rmap.o \
! 	subr_xxx.o sys_generic.o sys_inode.o sys_kern.o toy.o \
  	sys_pipe.o sys_process.o syscalls.o tm.o trap.o tmscp.o ts.o tty.o \
  	tty_conf.o tty_pty.o tty_subr.o tty_tb.o tty_tty.o ufs_alloc.o \
  	ufs_bio.o ufs_bmap.o ufs_dsort.o ufs_fio.o ufs_inode.o \
! 	ufs_mount.o ufs_namei.o ufs_subr.o ufs_syscalls.o \
  	vm_proc.o vm_sched.o vm_swap.o vm_swp.o vm_text.o xp.o subr_log.o
  OV1=	
  OV2=	
*** /old/src/sys/conf/README	Mon May  2 08:17:34 1988
--- /usr/src/sys/conf/README	Sat Nov 30 08:33:16 1991
***************
*** 6,14 ****
--- 6,37 ----
  run the script "./config", giving it the file name as an argument.  Config
  will create a directory ../machinename and will copy or create the necessary
  files in it.
+ 	When creating a GENERIC system remember to copy /sys/pdpdist/dtab
+ to /etc/dtab before creating the dump(8) of the root filesystem.  This is
+ so 'autoconfig' will find the tape and disc devices when the GENERIC kernel
+ is booted.
  	You will probably need to change the overlay definitions in the
  Makefile, if you are going to run an overlaid kernel, but most of the work
  of configuring a system will be done.
+ 	OVERLAY notes: Almost none of the CONF modules can be placed in 
+ overlays.  In general assembly language modules (source files ending in .s) 
+ may not be placed in overlays because they do not observe the overlay calling 
+ sequence used by the .c modules.  Other than that restriction modules may 
+ be placed in overlays in any order subject to the size constraints mentioned
+ below.  It is a good idea to attempt to group modules which call each other
+ in the same overlay when possible, this saves overlay switching overhead.
+ It is a very good idea to keep the frequently/constantly called modules
+ (such as ufs_namei.o or tty.o) in the BASE segment.  If the system has
+ a large amount of memory and swapping does not occur often then the swap
+ (vm_swap.o, etc) modules are good candidates for being placed in overlays.
+ Maximum size of the BASE is 56kb, maximum size of each overlay segment
+ is 8kb - the 'checksys' program will warn of segments (root/base, overlays 
+ and data) which are too large.  There is a limit of 15 overlays at present, 
+ however there is a lower limit on the size of a kernel which may be loaded.  
+ /boot can not deal with kernels larger than about 192kb (sum of text and data)
+ because that is where /boot relocates himself to while loading /unix.  See
+ the comments in /sys/pdpstand/M.s for more information and a workaround
+ (which will not work with the 3Com ethernet board installed in the system).
  	There is one possible problem that you need to be aware of.  Running
  the shell script config generates the file localopts.h in the system include
  files directory, "../h".  If you change your configuration, config will
*** /old/src/sys/conf/SMS	Wed Dec 19 10:16:21 1990
--- /usr/src/sys/conf/SMS	Sat Jun 13 19:22:12 1992
***************
*** 112,121 ****
  #BOOTDEV	si			# si 9500 boot device
  
  # Timezone, in minutes west of GMT
! TIMEZONE	300			# EST
  #TIMEZONE	360			# CST
  #TIMEZONE	420			# WST
! #TIMEZONE	480			# PST
  DST		1			# Daylight Savings Time (1 or 0)
  
  # Filesystem configuration
--- 112,121 ----
  #BOOTDEV	si			# si 9500 boot device
  
  # Timezone, in minutes west of GMT
! #TIMEZONE	300			# EST
  #TIMEZONE	360			# CST
  #TIMEZONE	420			# WST
! TIMEZONE	480			# PST
  DST		1			# Daylight Savings Time (1 or 0)
  
  # Filesystem configuration
***************
*** 285,291 ****
  
  NHK		0		# RK611, RK06/07
  
! NRAC		1		# NRAD controllers
  NRAD		4		# RX50, RC25, RD51/52/53, RA60/80/81
  
  NRK		0		# RK05
--- 285,291 ----
  
  NHK		0		# RK611, RK06/07
  
! NRAC		2		# NRAD controllers
  NRAD		4		# RX50, RC25, RD51/52/53, RA60/80/81
  
  NRK		0		# RK05
***************
*** 323,331 ****
  
  NTS		0		# TS11
  
! NTMSCP		1		# TMSCP controllers
! NTMS		1		# TMSCP drives
! TMSCP_DEBUG	YES		# debugging code in TMSCP drive (EXPENSIVE)
  TMSCP_VEC	0260		# base of TMSCP interrupt vectors (OCTAL!!!)
  
  #########################################
--- 323,331 ----
  
  NTS		0		# TS11
  
! NTMSCP		2		# TMSCP controllers
! NTMS		2		# TMSCP drives
! TMSCP_DEBUG	NO		# debugging code in TMSCP drive (EXPENSIVE)
  TMSCP_VEC	0260		# base of TMSCP interrupt vectors (OCTAL!!!)
  
  #########################################
***************
*** 337,343 ****
  NKL		2		# KL11, DL11
  NDH		0		# DH11; NDH is in units of boards (16 each)
  NDM		0		# DM11; NDM is in units of boards (16 each)
! NDHU		1		# DHU11, DHV11
  NDZ		0		# DZ11; NDZ is in units of boards (8 each)
  
  #########################################
--- 337,344 ----
  NKL		2		# KL11, DL11
  NDH		0		# DH11; NDH is in units of boards (16 each)
  NDM		0		# DM11; NDM is in units of boards (16 each)
! NDHU		0		# DHU11
! NDHV		1
  NDZ		0		# DZ11; NDZ is in units of boards (8 each)
  
  #########################################
***************
*** 375,381 ****
  NEC		0		# 3Com Ethernet
  NDE		0		# DEUNA
  NIL		0		# Interlan Ethernet
! NSL		0		# Serial Line IP
  NQE		1		# DEQNA
  NACC		0		# ACC LH/DH ARPAnet IMP interface
  PLI		NO		# LH/DH is connected to a PLI
--- 376,382 ----
  NEC		0		# 3Com Ethernet
  NDE		0		# DEUNA
  NIL		0		# Interlan Ethernet
! NSL		1		# Serial Line IP
  NQE		1		# DEQNA
  NACC		0		# ACC LH/DH ARPAnet IMP interface
  PLI		NO		# LH/DH is connected to a PLI
*** /old/src/sys/conf/TECHPUB	Wed Dec 19 10:15:04 1990
--- /usr/src/sys/conf/TECHPUB	Fri Dec 27 16:54:24 1991
***************
*** 337,343 ****
  NKL		2		# KL11, DL11
  NDH		2		# DH11; NDH is in units of boards (16 each)
  NDM		2		# DM11; NDM is in units of boards (16 each)
! NDHU		0		# DHU11, DHV11
  NDZ		0		# DZ11; NDZ is in units of boards (8 each)
  
  #########################################
--- 337,344 ----
  NKL		2		# KL11, DL11
  NDH		2		# DH11; NDH is in units of boards (16 each)
  NDM		2		# DM11; NDM is in units of boards (16 each)
! NDHU		0		# DHU11
! NDHV		0		# DHV11
  NDZ		0		# DZ11; NDZ is in units of boards (8 each)
  
  #########################################
*** /old/src/sys/conf/VAX	Sat Aug 12 21:58:07 1989
--- /usr/src/sys/conf/VAX	Sun Dec 22 16:12:46 1991
***************
*** 332,338 ****
  NKL		2		# KL11, DL11
  NDH		2		# DH11; NDH is in units of boards (16 each)
  NDM		2		# DM11; NDM is in units of boards (16 each)
! NDHU		2		# DHU11, DHV11
  NDZ		2		# DZ11; NDZ is in units of boards (8 each)
  
  #########################################
--- 332,339 ----
  NKL		2		# KL11, DL11
  NDH		2		# DH11; NDH is in units of boards (16 each)
  NDM		2		# DM11; NDM is in units of boards (16 each)
! NDHU		2		# DHU11
! HDHV		2		# DHV11
  NDZ		2		# DZ11; NDZ is in units of boards (8 each)
  
  #########################################
*** /old/src/sys/conf/boot/brboot.s	Fri Aug 26 14:31:45 1988
--- /usr/src/sys/conf/boot/brboot.s	Tue Apr 23 11:26:38 1991
***************
*** 1,5 ****
  /*
!  *	SCCS id	@(#)brboot.s	1.2 (Berkeley)	2/19/87
   */
  #include "localopts.h"
  
--- 1,5 ----
  /*
!  *	SCCS id	@(#)brboot.s	2.0 (2.11BSD)	4/13/91
   */
  #include "localopts.h"
  
***************
*** 8,19 ****
  ENDCORE=	160000		/ end of core, mem. management off
  SZFLAGS=	6		/ size of boot flags
  BOOTOPTS=	2		/ location of options, bytes below ENDCORE
! BOOTDEV=	4
  CHECKWORD=	6
  
! reset= 	5
! 
! .globl	_doboot, hardboot
  .text
  _doboot:
  	mov	4(sp),r4	/ boot options
--- 8,17 ----
  ENDCORE=	160000		/ end of core, mem. management off
  SZFLAGS=	6		/ size of boot flags
  BOOTOPTS=	2		/ location of options, bytes below ENDCORE
! BOOTDEV=	4		/ boot unit
  CHECKWORD=	6
  
! .globl	_doboot, hardboot, _bootcsr
  .text
  _doboot:
  	mov	4(sp),r4	/ boot options
***************
*** 35,44 ****
  #endif
  
  /  On power fail, hardboot is the entry point (map is already off)
! /  and the args are in r4, r3.
  
  hardboot:
  	mov	r4, ENDCORE-BOOTOPTS
  	mov	r3, ENDCORE-BOOTDEV
  	com	r4		/ if CHECKWORD == ~bootopts, flags are believed
  	mov	r4, ENDCORE-CHECKWORD
--- 33,44 ----
  #endif
  
  /  On power fail, hardboot is the entry point (map is already off)
! /  and the args are in r4 (RB_POWRFAIL), r3 (rootdev)
  
  hardboot:
  	mov	r4, ENDCORE-BOOTOPTS
+ 	ash	$-3,r3		/ shift out the partition number
+ 	bic	$!7,r3		/ save only the drive number
  	mov	r3, ENDCORE-BOOTDEV
  	com	r4		/ if CHECKWORD == ~bootopts, flags are believed
  	mov	r4, ENDCORE-CHECKWORD
***************
*** 52,66 ****
  
  / BR bootstrap
  
! brda =	176724
  
! 	mov	$brda,r0
! 	clr	(r0)		/ disk address
! 	clr	-(r0)		/ cylinder address
! 	clr	-(r0)		/ bus address
! 	mov	$-256.,-(r0)	/ wc
! 	mov	$5,-(r0)	/ cs: read+go
! 1:	tstb	(r0)		/ wait for ready
  	bge	1b
  
! 	jmp	*$0		/ transfer to zero
--- 52,72 ----
  
  / BR bootstrap
  
! brda =	10
  
! 	mov	_bootcsr, r1	/ csr of boot device
! 	add	$brda,r1
! 	clr	(r1)		/ disk address
! 	clr	-(r1)		/ cylinder address
! 	clr	-(r1)		/ bus address
! 	mov	$-256.,-(r1)	/ wc
! 	mov	ENDCORE-BOOTDEV,r0
! 	swab	r0		/ unit number to high byte
! 	bis	$5,r0		/ read+go
! 	mov	r0,-(r1)	/ cs: read+go
! 1:	tstb	(r1)		/ wait for ready
  	bge	1b
  
! 	mov	_bootcsr,r1	/ put csr and
! 	mov	ENDCORE-BOOTDEV,r0	/  unit where bootblock expects them
! 	clr	pc		/ transfer to zero
*** /old/src/sys/conf/boot/dvhpboot.s	Thu Feb 19 22:24:03 1987
--- /usr/src/sys/conf/boot/dvhpboot.s	Fri Apr 19 21:03:06 1991
***************
*** 1,5 ****
  /*
!  *	SCCS id	@(#)dvhpboot.s	1.2 (Berkeley)	2/19/87
   */
  #include "localopts.h"
  
--- 1,5 ----
  /*
!  *	SCCS id	@(#)dvhpboot.s	2.0 (2.11BSD)	4/13/91
   */
  #include "localopts.h"
  
***************
*** 8,19 ****
  ENDCORE=	160000		/ end of core, mem. management off
  SZFLAGS=	6		/ size of boot flags
  BOOTOPTS=	2		/ location of options, bytes below ENDCORE
! BOOTDEV=	4
  CHECKWORD=	6
  
! reset= 	5
! 
! .globl	_doboot, hardboot
  .text
  _doboot:
  	mov	4(sp),r4	/ boot options
--- 8,17 ----
  ENDCORE=	160000		/ end of core, mem. management off
  SZFLAGS=	6		/ size of boot flags
  BOOTOPTS=	2		/ location of options, bytes below ENDCORE
! BOOTDEV=	4		/ boot unit
  CHECKWORD=	6
  
! .globl	_doboot, hardboot, _bootcsr
  .text
  _doboot:
  	mov	4(sp),r4	/ boot options
***************
*** 35,44 ****
  #endif
  
  /  On power fail, hardboot is the entry point (map is already off)
! /  and the args are in r4, r3.
  
  hardboot:
  	mov	r4, ENDCORE-BOOTOPTS
  	mov	r3, ENDCORE-BOOTDEV
  	com	r4		/ if CHECKWORD == ~bootopts, flags are believed
  	mov	r4, ENDCORE-CHECKWORD
--- 33,44 ----
  #endif
  
  /  On power fail, hardboot is the entry point (map is already off)
! /  and the args are in r4 (RB_POWRFAIL), r3 (rootdev)
  
  hardboot:
  	mov	r4, ENDCORE-BOOTOPTS
+ 	ash	$-3,r3		/ shift out the partition number
+ 	bic	$!7,r3		/ save only the drive number
  	mov	r3, ENDCORE-BOOTDEV
  	com	r4		/ if CHECKWORD == ~bootopts, flags are believed
  	mov	r4, ENDCORE-CHECKWORD
***************
*** 53,83 ****
  /
  / Bootstrap for DIVA Comp/V controller without boot opcode
  /
! HPCSR=	176700		/ Drive #0
! HPDC=	176734		/ Desired cylinder
! HPBAE=	176750		/ Bus extension address (RH70)
! HPCS2=	176710		/ Control/status register 2
  READIT=	71
- CSW=	177570		/ Console switch display register
  
  1:
! 	bitb	$200,*$HPCSR	/ wait for ready
! 	beq	1b
  
! 	mov	$0710,*$CSW	/ For debugging
! 	mov	$0,*$HPDC	/ Cylinder 0
! 	mov	$0,*$HPBAE	/ Bus extension address = 0
! 	mov	$HPCS2,r0
! 	mov	$0,-(r0)	/ HPCSR->hpda = 0 (desired address 0)
! 	mov	$0,-(r0)	/ HPCSR->hpba = 0 (buf address 0)
! 	mov	$177400,-(r0)	/ HPCSR->hpwc = -256 (one block)
! 	mov	$READIT,-(r0)	/ HPCSR->hpcs1 = HP_RCOM|HP_GO
! 	mov	$0711,*$CSW	/ For debugging
  
  1:
! 	bitb	$200,*$HPCSR	/ wait for done
! 	beq	1b
! 	mov	$0712,*$CSW	/ For debugging
! 	jmp	*$0
! 
! / no return
--- 53,80 ----
  /
  / Bootstrap for DIVA Comp/V controller without boot opcode
  /
! HPCSR=	0		/ offset from base csr
! HPCS2=	10		/ Control/status register 2
! HPDC=	34		/ Desired cylinder
! HPBAE=	50		/ Bus extension address (RH70)
  READIT=	71
  
+ 	mov	_bootcsr,r1	/ boot device csr
  1:
! 	tstb	(r1)		/ wait for ready (HPCSR is offset 0)
! 	bpl	1b
  
! 	clr	HPDC(r1)	/ Cylinder 0
! 	clr	HPBAE		/ Bus extension address = 0
! 	add	$HPCS2,r1
! 	mov	ENDCORE-BOOTDEV,(r1)	/ unit number
! 	clr	-(r1)		/ hpda = 0 (desired address 0)
! 	clr	-(r1)		/ hpba = 0 (buf address 0)
! 	mov	$-256.,-(r1)	/ hpwc = -256 (one block)
! 	mov	$READIT,-(r1)	/ hpcs1 = HP_RCOM|HP_GO
  
  1:
! 	tstb	(r1)		/ wait for done
! 	bpl	1b
! 	mov	ENDCORE-BOOTDEV,r0
! 	clr	pc
*** /old/src/sys/conf/boot/hk6boot.s	Thu Feb 19 22:24:03 1987
--- /usr/src/sys/conf/boot/hk6boot.s	Fri Apr 19 21:03:14 1991
***************
*** 1,5 ****
  /*
!  *	SCCS id	@(#)hk6boot.s	1.2 (Berkeley)	2/19/87
   */
  #include "localopts.h"
  
--- 1,5 ----
  /*
!  *	SCCS id	@(#)hk6boot.s	2.0 (2.11BSD)	4/13/91
   */
  #include "localopts.h"
  
***************
*** 8,19 ****
  ENDCORE=	160000		/ end of core, mem. management off
  SZFLAGS=	6		/ size of boot flags
  BOOTOPTS=	2		/ location of options, bytes below ENDCORE
! BOOTDEV=	4
  CHECKWORD=	6
  
! reset= 	5
! 
! .globl	_doboot, hardboot
  .text
  _doboot:
  	mov	4(sp),r4	/ boot options
--- 8,17 ----
  ENDCORE=	160000		/ end of core, mem. management off
  SZFLAGS=	6		/ size of boot flags
  BOOTOPTS=	2		/ location of options, bytes below ENDCORE
! BOOTDEV=	4		/ boot unit
  CHECKWORD=	6
  
! .globl	_doboot, hardboot, _bootcsr
  .text
  _doboot:
  	mov	4(sp),r4	/ boot options
***************
*** 35,44 ****
  #endif
  
  /  On power fail, hardboot is the entry point (map is already off)
! /  and the args are in r4, r3.
  
  hardboot:
  	mov	r4, ENDCORE-BOOTOPTS
  	mov	r3, ENDCORE-BOOTDEV
  	com	r4		/ if CHECKWORD == ~bootopts, flags are believed
  	mov	r4, ENDCORE-CHECKWORD
--- 33,44 ----
  #endif
  
  /  On power fail, hardboot is the entry point (map is already off)
! /  and the args are in r4 (RB_POWRFAIL), r3 (rootdev)
  
  hardboot:
  	mov	r4, ENDCORE-BOOTOPTS
+ 	ash	$-3,r3		/ shift out the partition number
+ 	bic	$!7,r3		/ save only the drive number
  	mov	r3, ENDCORE-BOOTDEV
  	com	r4		/ if CHECKWORD == ~bootopts, flags are believed
  	mov	r4, ENDCORE-CHECKWORD
***************
*** 54,63 ****
  
  WC = -256.
  
! hkcs1 = 177440	/ control & status 1
! hkda  = 177446	/ desired track/sector address
! hkcs2 = 177450	/ control & status 2
! hkca  = 177460	/ desired cylinder
  
  / RK06 constants.
  ack = 03	/ pack acknowledge
--- 54,63 ----
  
  WC = -256.
  
! hkcs1 = 0	/ offsets from base csr, control & status 1
! hkda  = 6	/ desired track/sector address
! hkcs2 = 10	/ control & status 2
! hkca  = 20	/ desired cylinder
  
  / RK06 constants.
  ack = 03	/ pack acknowledge
***************
*** 65,79 ****
  iocom = 021	/ read + go
  
  / initialize hk
! 	mov	$clear,hkcs2
! 	mov	$ack,hkcs1
  0:
! 	tstb	hkcs1
  	bpl	0b		/ wait for acknowledge to complete
  
! 	clr	hkca
! 	mov	$hkda,r1
! 	clr	(r1)		/ sector and track
  	clr	-(r1)		/ bus address
  	mov	$WC,-(r1)	/ word count
  	mov	$iocom,-(r1)
--- 65,81 ----
  iocom = 021	/ read + go
  
  / initialize hk
! 	mov	_bootcsr,r1
! 	mov	$clear,hkcs2(r1)
! 	mov	$ack,hkcs1(r1)
  0:
! 	tstb	hkcs1(r1)
  	bpl	0b		/ wait for acknowledge to complete
  
! 	clr	hkca(r1)
! 	add	$hkcs2,r1
! 	mov	ENDCORE-BOOTDEV,(r1)
! 	clr	-(r1)		/ sector and track (hkda)
  	clr	-(r1)		/ bus address
  	mov	$WC,-(r1)	/ word count
  	mov	$iocom,-(r1)
***************
*** 80,83 ****
  1:
  	tstb	(r1)
  	bge	1b		/ wait for iocom to complete
! 	jmp	*$0
--- 82,86 ----
  1:
  	tstb	(r1)
  	bge	1b		/ wait for iocom to complete
! 	mov	ENDCORE-BOOTDEV,r0
! 	clr	pc
*** /old/src/sys/conf/boot/hk7boot.s	Thu Feb 19 22:24:03 1987
--- /usr/src/sys/conf/boot/hk7boot.s	Fri Apr 19 21:03:21 1991
***************
*** 1,5 ****
  /*
!  *	SCCS id	@(#)hk7boot.s	1.2 (Berkeley)	2/19/87
   */
  #include "localopts.h"
  
--- 1,5 ----
  /*
!  *	SCCS id	@(#)hk7boot.s	2.0 (2.11BSD)	4/13/91
   */
  #include "localopts.h"
  
***************
*** 8,19 ****
  ENDCORE=	160000		/ end of core, mem. management off
  SZFLAGS=	6		/ size of boot flags
  BOOTOPTS=	2		/ location of options, bytes below ENDCORE
! BOOTDEV=	4
  CHECKWORD=	6
  
! reset= 	5
! 
! .globl	_doboot, hardboot
  .text
  _doboot:
  	mov	4(sp),r4	/ boot options
--- 8,17 ----
  ENDCORE=	160000		/ end of core, mem. management off
  SZFLAGS=	6		/ size of boot flags
  BOOTOPTS=	2		/ location of options, bytes below ENDCORE
! BOOTDEV=	4		/ boot unit
  CHECKWORD=	6
  
! .globl	_doboot, hardboot, _bootcsr
  .text
  _doboot:
  	mov	4(sp),r4	/ boot options
***************
*** 35,44 ****
  #endif
  
  /  On power fail, hardboot is the entry point (map is already off)
! /  and the args are in r4, r3.
  
  hardboot:
  	mov	r4, ENDCORE-BOOTOPTS
  	mov	r3, ENDCORE-BOOTDEV
  	com	r4		/ if CHECKWORD == ~bootopts, flags are believed
  	mov	r4, ENDCORE-CHECKWORD
--- 33,44 ----
  #endif
  
  /  On power fail, hardboot is the entry point (map is already off)
! /  and the args are in r4 (RB_POWRFAIL), r3 (rootdev)
  
  hardboot:
  	mov	r4, ENDCORE-BOOTOPTS
+ 	ash	$-3,r3		/ shift out the partition number
+ 	bic	$!7,r3		/ save only the drive number
  	mov	r3, ENDCORE-BOOTDEV
  	com	r4		/ if CHECKWORD == ~bootopts, flags are believed
  	mov	r4, ENDCORE-CHECKWORD
***************
*** 54,63 ****
  
  WC = -256.
  
! hkcs1 = 177440	/ control & status 1
! hkda  = 177446	/ desired track/sector address
! hkcs2 = 177450	/ control & status 2
! hkca  = 177460	/ desired cylinder
  
  / RK07 constants
  ack = 02003	/ pack acknowledge
--- 54,63 ----
  
  WC = -256.
  
! hkcs1 = 0	/ offsets from base csr, control & status 1
! hkda  = 6	/ desired track/sector address
! hkcs2 = 10	/ control & status 2
! hkca  = 20	/ desired cylinder
  
  / RK07 constants
  ack = 02003	/ pack acknowledge
***************
*** 65,79 ****
  iocom = 2021	/ read + go
  
  / initialize hk
! 	mov	$clear,hkcs2
! 	mov	$ack,hkcs1
  0:
! 	tstb	hkcs1
  	bpl	0b		/ wait for acknowledge to complete
  
! 	clr	hkca
! 	mov	$hkda,r1
! 	clr	(r1)		/ sector and track
  	clr	-(r1)		/ bus address
  	mov	$WC,-(r1)	/ word count
  	mov	$iocom,-(r1)
--- 65,81 ----
  iocom = 2021	/ read + go
  
  / initialize hk
! 	mov	_bootcsr,r1
! 	mov	$clear,hkcs2(r1)
! 	mov	$ack,hkcs1(r1)
  0:
! 	tstb	hkcs1(r1)
  	bpl	0b		/ wait for acknowledge to complete
  
! 	clr	hkca(r1)
! 	add	$hkcs2,r1
! 	mov	ENDCORE-BOOTDEV,(r1)
! 	clr	-(r1)		/ sector and track (hkda)
  	clr	-(r1)		/ bus address
  	mov	$WC,-(r1)	/ word count
  	mov	$iocom,-(r1)
***************
*** 80,83 ****
  1:
  	tstb	(r1)
  	bge	1b		/ wait for iocom to complete
! 	jmp	*$0
--- 82,86 ----
  1:
  	tstb	(r1)
  	bge	1b		/ wait for iocom to complete
! 	mov	ENDCORE-BOOTDEV,r0
! 	clr	pc
*** /old/src/sys/conf/boot/raboot.s	Thu Feb 19 22:24:03 1987
--- /usr/src/sys/conf/boot/raboot.s	Fri Apr 19 21:03:29 1991
***************
*** 1,5 ****
  /*
!  *	SCCS id	@(#)raboot.s	1.2 (Berkeley)	2/19/87
   */
  #include "localopts.h"
  
--- 1,5 ----
  /*
!  *	SCCS id	@(#)raboot.s	2.0 (2.11BSD)	4/13/91
   */
  #include "localopts.h"
  
***************
*** 8,19 ****
  ENDCORE=	160000		/ end of core, mem. management off
  SZFLAGS=	6		/ size of boot flags
  BOOTOPTS=	2		/ location of options, bytes below ENDCORE
! BOOTDEV=	4
  CHECKWORD=	6
  
! reset= 	5
! 
! .globl	_doboot, hardboot
  .text
  _doboot:
  	mov	4(sp),r4	/ boot options
--- 8,17 ----
  ENDCORE=	160000		/ end of core, mem. management off
  SZFLAGS=	6		/ size of boot flags
  BOOTOPTS=	2		/ location of options, bytes below ENDCORE
! BOOTDEV=	4		/ boot unit
  CHECKWORD=	6
  
! .globl	_doboot, hardboot, _bootcsr
  .text
  _doboot:
  	mov	4(sp),r4	/ boot options
***************
*** 35,44 ****
  #endif
  
  /  On power fail, hardboot is the entry point (map is already off)
! /  and the args are in r4, r3.
  
  hardboot:
  	mov	r4, ENDCORE-BOOTOPTS
  	mov	r3, ENDCORE-BOOTDEV
  	com	r4		/ if CHECKWORD == ~bootopts, flags are believed
  	mov	r4, ENDCORE-CHECKWORD
--- 33,44 ----
  #endif
  
  /  On power fail, hardboot is the entry point (map is already off)
! /  and the args are in r4 (RB_POWRFAIL), r3 (rootdev)
  
  hardboot:
  	mov	r4, ENDCORE-BOOTOPTS
+ 	ash	$-3,r3		/ shift out the partition number
+ 	bic	$!7,r3		/ save only the drive number
  	mov	r3, ENDCORE-BOOTDEV
  	com	r4		/ if CHECKWORD == ~bootopts, flags are believed
  	mov	r4, ENDCORE-CHECKWORD
***************
*** 89,102 ****
  RALBNL =	112.	/ Logical block number low
  RALBNH = 	114.	/ Logical block number high
  
- raip	= 172150	/ initialization and polling register
- rasa	= 172152	/ address and status register
- 
  BSIZE	=	512.	/ Size of boot block
- /
- / options:
- /
- unit	= 0		/ # of unit to load boot from
  
  /
  / Clear RA MSCP command area!
--- 89,95 ----
***************
*** 112,118 ****
  / RA initialize controller 
  /
  	mov	$RASTEP1,r0
! 	mov	$raip,r1
  	clr	(r1)+			/ go through controller init seq.
  	mov	$icons,r2
  1:
--- 105,111 ----
  / RA initialize controller 
  /
  	mov	$RASTEP1,r0
! 	mov	_bootcsr,r1		/ get csr of boot controller
  	clr	(r1)+			/ go through controller init seq.
  	mov	$icons,r2
  1:
***************
*** 125,131 ****
  	mov	$ra+RACMDREF,*$ra+RACMDL
  	mov	$RASTCON,r0
  	jsr	pc,racmd
! 	mov	$unit,*$ra+RAUNIT	/ bring boot unit online
  	mov	$RAONLIN,r0
  	jsr	pc,racmd
  
--- 118,124 ----
  	mov	$ra+RACMDREF,*$ra+RACMDL
  	mov	$RASTCON,r0
  	jsr	pc,racmd
! 	mov	ENDCORE-BOOTDEV,*$ra+RAUNIT	/ bring boot unit online
  	mov	$RAONLIN,r0
  	jsr	pc,racmd
  
***************
*** 142,166 ****
  / 
  / Tim Tucker, Gould Electronics, August 23rd 1985
  /
! 	clr	r0
! 	mov	r0,*$ra+RALBNL		/ Put in logical block number
  	mov	$BSIZE,*$ra+RABYTECT	/ Put in byte to transfer
! 	mov	r0,*$ra+RABUFL		/ Put in disk buffer location
  	mov	$RAREAD,r0
  	jsr	pc,racmd
! 	jmp	*$0			/ and away we go
  /
  / perform MSCP command -> response poll version
  /
  racmd:
  	movb	r0,*$ra+RAOPCODE	/ fill in command type
! 	mov	$MSCPSIZE,r0
! 	mov	r0,*$ra+RARSPS		/ give controller struct sizes
! 	mov	r0,*$ra+RACMDS
! 	mov	$RASEMAP,r0
! 	mov	r0,*$ra+RARSPH		/ set mscp semaphores
! 	mov	r0,*$ra+RACMDH
! 	mov	raip,r0			/ tap controllers shoulder
  	mov	$ra+RACMDI,r0
  1:
  	tst	(r0)
--- 135,158 ----
  / 
  / Tim Tucker, Gould Electronics, August 23rd 1985
  /
! 	clr	*$ra+RALBNL		/ Put in logical block number
  	mov	$BSIZE,*$ra+RABYTECT	/ Put in byte to transfer
! 	clr	*$ra+RABUFL		/ Put in disk buffer location
  	mov	$RAREAD,r0
  	jsr	pc,racmd
! 	mov	ENDCORE-BOOTDEV,r0	/ put unit and
! 	mov	_bootcsr,r1		/   csr where bootblock expects them
! 	clr	pc			/ and away we go
  /
  / perform MSCP command -> response poll version
  /
  racmd:
  	movb	r0,*$ra+RAOPCODE	/ fill in command type
! 	mov	$MSCPSIZE,*$ra+RARSPS	/ give controller struct sizes
! 	mov	$MSCPSIZE,*$ra+RACMDS
! 	mov	$RASEMAP,*$ra+RARSPH	/ set mscp semaphores
! 	mov	$RASEMAP,*$ra+RACMDH
! 	mov	*_bootcsr,r0		/ tap controllers shoulder
  	mov	$ra+RACMDI,r0
  1:
  	tst	(r0)
*** /old/src/sys/conf/boot/rlboot.s	Thu Feb 19 22:24:03 1987
--- /usr/src/sys/conf/boot/rlboot.s	Fri Apr 19 21:03:34 1991
***************
*** 1,5 ****
  /*
!  *	SCCS id	@(#)rlboot.s	1.2 (Berkeley)	2/19/87
   */
  #include "localopts.h"
  
--- 1,5 ----
  /*
!  *	SCCS id	@(#)rlboot.s	2.0 (2.11BSD)	4/13/91
   */
  #include "localopts.h"
  
***************
*** 8,19 ****
  ENDCORE=	160000		/ end of core, mem. management off
  SZFLAGS=	6		/ size of boot flags
  BOOTOPTS=	2		/ location of options, bytes below ENDCORE
! BOOTDEV=	4
  CHECKWORD=	6
  
! reset= 	5
! 
! .globl	_doboot, hardboot
  .text
  _doboot:
  	mov	4(sp),r4	/ boot options
--- 8,17 ----
  ENDCORE=	160000		/ end of core, mem. management off
  SZFLAGS=	6		/ size of boot flags
  BOOTOPTS=	2		/ location of options, bytes below ENDCORE
! BOOTDEV=	4		/ boot unit
  CHECKWORD=	6
  
! .globl	_doboot, hardboot, _bootcsr
  .text
  _doboot:
  	mov	4(sp),r4	/ boot options
***************
*** 35,44 ****
  #endif
  
  /  On power fail, hardboot is the entry point (map is already off)
! /  and the args are in r4, r3.
  
  hardboot:
  	mov	r4, ENDCORE-BOOTOPTS
  	mov	r3, ENDCORE-BOOTDEV
  	com	r4		/ if CHECKWORD == ~bootopts, flags are believed
  	mov	r4, ENDCORE-CHECKWORD
--- 33,44 ----
  #endif
  
  /  On power fail, hardboot is the entry point (map is already off)
! /  and the args are in r4 (RB_POWRFAIL), r3 (rootdev)
  
  hardboot:
  	mov	r4, ENDCORE-BOOTOPTS
+ 	ash	$-3,r3		/ shift out the partition number
+ 	bic	$!7,r3		/ save only the drive number
  	mov	r3, ENDCORE-BOOTDEV
  	com	r4		/ if CHECKWORD == ~bootopts, flags are believed
  	mov	r4, ENDCORE-CHECKWORD
***************
*** 57,87 ****
  SEEK	= 3\<1
  RDHDR	= 4\<1
  
! rlcs	= 174400
! rlda	= 174404
! rlba	= 174402
! rlmp	= 174406
  
! 	mov	$RDHDR,*$rlcs	/find out where we are (cyl)
  1:
! 	tstb	*$rlcs
  	bpl	1b
! 	mov	*$rlmp,r0
  	bic	$!77600,r0
  	bis	$1,r0
! 	mov	r0,*$rlda
! 	mov	$SEEK,*$rlcs	/ move it
  1:
! 	tstb	*$rlcs
  	bpl	1b
  /
! 	mov	$rlmp,r0
! 	mov	$WC,(r0)	/wc into rlmp
! 	clr	-(r0)		/da into rlda
! 	clr	-(r0)		/ba
! 	mov	$READ,-(r0)	/cmd into rlcs
  1:
! 	tstb	*$rlcs
  	bpl	1b
  /
! 	jmp	*$0		/ and away we go
--- 57,95 ----
  SEEK	= 3\<1
  RDHDR	= 4\<1
  
! rlcs	= 0
! rlba	= 2
! rlda	= 4
! rlmp	= 6
  
! 	mov	_bootcsr,r1
! 	mov	ENDCORE-BOOTDEV,r2
! 	bis	$RDHDR,r2
! 	mov	r2,rlcs(r1)	/find out where we are (cyl)
  1:
! 	tstb	rlcs(r1)
  	bpl	1b
! 	mov	rlmp(r1),r0
  	bic	$!77600,r0
  	bis	$1,r0
! 	mov	r0,rlda(r1)
! 	mov	ENDCORE-BOOTDEV,r2
! 	bis	$SEEK,r2
! 	mov	r2,rlcs(r1)	/ move it
  1:
! 	tstb	rlcs(r1)
  	bpl	1b
  /
! 	add	$rlmp,r1
! 	mov	$WC,(r1)	/wc into rlmp
! 	clr	-(r1)		/da into rlda
! 	clr	-(r1)		/ba
! 	mov	ENDCORE-BOOTDEV,r2
! 	bis	$READ,r2
! 	mov	r2,-(r0)	/cmd into rlcs
  1:
! 	tstb	rlcs(r1)
  	bpl	1b
  /
! 	mov	ENDCORE-BOOTDEV,r0
! 	clr	pc		/ and away we go
