Adapt to current libsa.

This commit is contained in:
pk 1994-07-01 10:46:55 +00:00
parent d34a60b7fd
commit 7d2e12f330
4 changed files with 57 additions and 6 deletions

View File

@ -1,5 +1,5 @@
# from: @(#)Makefile 8.1 (Berkeley) 6/10/93
# $Id: Makefile,v 1.1 1994/02/26 10:57:09 pk Exp $
# $Id: Makefile,v 1.2 1994/07/01 10:46:55 pk Exp $
DESTDIR=
@ -12,7 +12,7 @@ RELOC= ${RELOC_SUN4C}
DEFS= -DSTANDALONE -DCOMPAT_NOLABEL # -DROMPRF
CFLAGS= -O2 ${INCPATH} ${DEFS}
SRCS= boot.c promdev.c version.c
SRCS= boot.c filesystem.c promdev.c version.c
#SRCS+= io.c strerror.c
S= ${.CURDIR}/../../..

View File

@ -32,7 +32,7 @@
*
* from: @(#)boot.c 8.1 (Berkeley) 6/10/93
*
* $Id: boot.c,v 1.2 1994/03/20 09:13:37 pk Exp $
* $Id: boot.c,v 1.3 1994/07/01 10:46:56 pk Exp $
*/
#include <sys/param.h>
@ -41,6 +41,9 @@
#include <machine/bsd_openprom.h>
#include "stand.h"
int debug;
int netif_debug;
/*
* Boot device is derived from ROM provided information.
*/
@ -75,7 +78,7 @@ struct promvec *pp;
printf("Booting %s @ 0x%x\n", file, LOADADDR);
copyunix(io, LOADADDR);
promvec->pv_halt();
_rtt();
}
/*ARGSUSED*/
@ -191,3 +194,7 @@ twiddle()
tw_pos %= (sizeof(tw_chars) - 1);
}
_rtt()
{
promvec->pv_halt();
}

View File

@ -0,0 +1,44 @@
/*
* Copyright (c) 1993 Philip A. Nelson.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 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 by Philip A. Nelson.
* 4. The name of Philip A. Nelson may not be used to endorse or promote
* products derived from this software without specific prior written
* permission.
*
* THIS SOFTWARE IS PROVIDED BY PHILIP NELSON ``AS IS'' AND ANY EXPRESS OR
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
* IN NO EVENT SHALL PHILIP NELSON BE LIABLE FOR ANY DIRECT, INDIRECT,
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
* NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* filesystem.c
*
* $Id: filesystem.c,v 1.1 1994/07/01 10:46:58 pk Exp $
*/
#include <stand.h>
#include <ufs.h>
struct fs_ops file_system[] = {
{ ufs_open, ufs_close, ufs_read, ufs_write, ufs_seek, ufs_stat },
};
int nfsys = sizeof(file_system)/sizeof(struct fs_ops);

View File

@ -27,7 +27,7 @@
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* $Id: promdev.c,v 1.1 1994/02/26 10:57:18 pk Exp $
* $Id: promdev.c,v 1.2 1994/07/01 10:46:59 pk Exp $
*/
#include <sys/param.h>
@ -165,7 +165,7 @@ promstrategy(devdata, func, dblk, size, buf, rsize)
u_int *rsize;
{
register struct prom_softc *pp = (struct prom_softc *)devdata;
u_int (*pf)();
register u_int (*pf)();
int v2 = promvec->pv_romvec_vers == 2;
daddr_t blk = dblk + pp->poff;
int error = 0;