Rename NetBSD/arm26 to NetBSD/acorn26, so that the two Acorn/ARM ports have

matching names.  This commit might include some private hacks that have been
lurking in my tree a while.  They're all harmless, and this reduces the number
of gratuitous diffs I have to deal with.
This commit is contained in:
bjh21 2002-03-24 15:45:29 +00:00
parent ebfcb75fe5
commit 1de4f40a8a
185 changed files with 1086 additions and 501 deletions

33
sys/arch/acorn26/Makefile Normal file
View File

@ -0,0 +1,33 @@
# $NetBSD: Makefile,v 1.1 2002/03/24 15:46:41 bjh21 Exp $
# Makefile for acorn26 tags file and boot blocks
TACORN26= ../acorn26/tags
SACORN26= ../acorn26/acorn26/*.[ch] ../acorn26/include/*.h \
../acorn26/iobus/*.[ch] ../acorn26/ioc/*.[ch] ../arm32/mainbus/*.[ch] \
../acorn26/vidc/*.[ch]
AACORN26= ../acorn26/acorn26/*.S ../acorn26/iobus/*.S
# Directories in which to place tags links
DACORN26= acorn26 include iobus ioc mainbus vidc
.include "../../kern/Make.tags.inc"
tags: TAGS
-ctags -wdtf ${TACORN26} ${SACORN26} ${COMM}
egrep "^ENTRY(.*)|^ALTENTRY(.*)" ${AACORN26} | \
sed "s;\([^:]*\):\([^(]*\)(\([^, )]*\)\(.*\);\3 \1 /^\2(\3\4$$/;" \
>> ${TACORN26}
sort -o ${TACORN26} ${TACORN26}
TAGS:
etags ${SACORN26} ${COMM} ${AACORN26}
links:
-for i in ${DACORN26}; do \
cd $$i && rm -f tags; ln -s ../tags tags; done
SUBDIR= stand include
.include <bsd.subdir.mk>

View File

@ -1,4 +1,4 @@
/* $NetBSD: Locore.c,v 1.7 2001/02/13 13:16:37 bjh21 Exp $ */
/* $NetBSD: Locore.c,v 1.1 2002/03/24 15:46:42 bjh21 Exp $ */
/*
* Copyright (c) 2000 Ben Harris.
@ -41,7 +41,7 @@
#include <sys/param.h>
__RCSID("$NetBSD: Locore.c,v 1.7 2001/02/13 13:16:37 bjh21 Exp $");
__RCSID("$NetBSD: Locore.c,v 1.1 2002/03/24 15:46:42 bjh21 Exp $");
#include <sys/proc.h>
#include <sys/sched.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: autoconf.c,v 1.3 2001/08/25 17:55:24 bjh21 Exp $ */
/* $NetBSD: autoconf.c,v 1.1 2002/03/24 15:46:42 bjh21 Exp $ */
/*-
* Copyright (c) 1998, 1999 Ben Harris
* All rights reserved.
@ -32,7 +32,7 @@
#include <sys/param.h>
__RCSID("$NetBSD: autoconf.c,v 1.3 2001/08/25 17:55:24 bjh21 Exp $");
__RCSID("$NetBSD: autoconf.c,v 1.1 2002/03/24 15:46:42 bjh21 Exp $");
#include <sys/conf.h>
#include <sys/device.h>
@ -42,6 +42,8 @@ __RCSID("$NetBSD: autoconf.c,v 1.3 2001/08/25 17:55:24 bjh21 Exp $");
#include <machine/irq.h>
#include <machine/machdep.h>
struct device *booted_device;
void
cpu_configure()
{

View File

@ -1,4 +1,4 @@
/* $NetBSD: bus.c,v 1.8 2001/06/12 20:16:22 bjh21 Exp $ */
/* $NetBSD: bus.c,v 1.1 2002/03/24 15:46:42 bjh21 Exp $ */
/*-
* Copyright (c) 1999, 2000 Ben Harris
* All rights reserved.
@ -32,7 +32,7 @@
#include <sys/param.h>
__RCSID("$NetBSD: bus.c,v 1.8 2001/06/12 20:16:22 bjh21 Exp $");
__RCSID("$NetBSD: bus.c,v 1.1 2002/03/24 15:46:42 bjh21 Exp $");
#include <machine/bus.h>
#include <machine/memcreg.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: conf.c,v 1.8 2002/01/12 12:36:31 manu Exp $ */
/* $NetBSD: conf.c,v 1.1 2002/03/24 15:46:43 bjh21 Exp $ */
/*-
* Copyright (c) 1998, 2000 Ben Harris
* All rights reserved.
@ -32,7 +32,7 @@
#include <sys/param.h>
__RCSID("$NetBSD: conf.c,v 1.8 2002/01/12 12:36:31 manu Exp $");
__RCSID("$NetBSD: conf.c,v 1.1 2002/03/24 15:46:43 bjh21 Exp $");
#include <sys/systm.h>
#include <sys/buf.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: cons_machdep.c,v 1.3 2001/03/11 16:31:05 bjh21 Exp $ */
/* $NetBSD: cons_machdep.c,v 1.1 2002/03/24 15:46:43 bjh21 Exp $ */
/*-
* Copyright (c) 1998 Ben Harris
* All rights reserved.
@ -32,7 +32,7 @@
#include <sys/param.h>
__RCSID("$NetBSD: cons_machdep.c,v 1.3 2001/03/11 16:31:05 bjh21 Exp $");
__RCSID("$NetBSD: cons_machdep.c,v 1.1 2002/03/24 15:46:43 bjh21 Exp $");
#include <sys/syslog.h>
#include <sys/systm.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: copyinout.S,v 1.6 2001/08/20 22:56:10 bjh21 Exp $ */
/* $NetBSD: copyinout.S,v 1.1 2002/03/24 15:46:43 bjh21 Exp $ */
/*-
* Copyright (c) 2000 Ben Harris
@ -33,7 +33,7 @@
#include <machine/asm.h>
RCSID("$NetBSD: copyinout.S,v 1.6 2001/08/20 22:56:10 bjh21 Exp $")
RCSID("$NetBSD: copyinout.S,v 1.1 2002/03/24 15:46:43 bjh21 Exp $")
#include <sys/errno.h>
#include "assym.h"

View File

@ -0,0 +1,232 @@
/* $NetBSD: copyinoutstr.S,v 1.1 2002/03/24 15:46:43 bjh21 Exp $ */
/*-
* Copyright (c) 2000 Ben Harris
* 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. 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
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
* IN NO EVENT SHALL THE AUTHOR 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.
*/
/* This file is part of NetBSD/arm26 -- a port of NetBSD to ARM2/3 machines. */
/*
* copyinout.S - copy data between user and kernel space
*/
#include <machine/asm.h>
RCSID("$NetBSD: copyinoutstr.S,v 1.1 2002/03/24 15:46:43 bjh21 Exp $")
#include <sys/errno.h>
#include "assym.h"
/*
* int copyin(const void *ua, void *ka, size_t len);
* int copyout(const void *ka, void *ua, size_t len);
* int kcopy(const void *src, void *dst, size_t len);
*/
/*
* memcpy isn't currently data-abort-safe (it uses R14). This is much
* slower, but safer.
*/
/* LINTSTUB: Func: int copyinstr(const void *uaddr, void *kaddr, size_t len, size_t *done) */
ENTRY(copyinstr)
mov ip, sp
stmfd sp!, {r4, r5, r6, fp, ip, lr, pc}
sub fp, ip, #4
adr r4, Lcopystrfault
ldr r5, Lcurproc
ldr r5, [r5]
ldr r5, [r5, #P_ADDR]
str r4, [r5, #(U_PCB + PCB_ONFAULT)]
mov r6, r1
Lcopyinstrloop:
ldrbt r4, [r0], #1
strb r4, [r1], #1
subs r2, r2, #1
teqne r4, #0
bne Lcopyinstrloop
teq r3, #0
subne r6, r1, r6
strne r6, [r3]
mov r0, #0
str r0, [r5, #(U_PCB + PCB_ONFAULT)]
teq r4, #0
movne r0, #ENAMETOOLONG
#ifdef __APCS_26__
ldmdb fp, {r4, r5, r6, fp, sp, pc}^
#else
ldmdb fp, {r4, r5, r6, fp, sp, pc}
#endif
/* LINTSTUB: Func: int copyoutstr(const void *kaddr, void *uaddr, size_t len, size_t *done) */
ENTRY(copyoutstr)
mov ip, sp
stmfd sp!, {r4, r5, r6, fp, ip, lr, pc}
sub fp, ip, #4
adr r4, Lcopystrfault
ldr r5, Lcurproc
ldr r5, [r5]
ldr r5, [r5, #P_ADDR]
str r4, [r5, #(U_PCB + PCB_ONFAULT)]
mov r6, r1
Lcopyoutstrloop:
ldrb r4, [r0], #1
strbt r4, [r1], #1
subs r2, r2, #1
teqne r4, #0
bne Lcopyoutstrloop
teq r3, #0
subne r6, r1, r6
strne r6, [r3]
mov r0, #0
str r0, [r5, #(U_PCB + PCB_ONFAULT)]
teq r4, #0
movne r0, #ENAMETOOLONG
#ifdef __APCS_26__
ldmdb fp, {r4, r5, r6, fp, sp, pc}^
#else
ldmdb fp, {r4, r5, r6, fp, sp, pc}
#endif
/* LINTSTUB: Func: int copystr(const void *kfaddr, void *kdaddr, size_t len, size_t *done) */
ENTRY(copystr)
mov ip, sp
stmfd sp!, {r4, r5, r6, fp, ip, lr, pc}
sub fp, ip, #4
adr r4, Lcopystrfault
ldr r5, Lcurproc
ldr r5, [r5]
ldr r5, [r5, #P_ADDR]
str r4, [r5, #(U_PCB + PCB_ONFAULT)]
mov r6, r1
Lcopystrloop:
ldrb r4, [r0], #1
strb r4, [r1], #1
subs r2, r2, #1
teqne r4, #0
bne Lcopystrloop
teq r3, #0
subne r6, r1, r6
strne r6, [r3]
mov r0, #0
str r0, [r5, #(U_PCB + PCB_ONFAULT)]
teq r4, #0
movne r0, #ENAMETOOLONG
ldmdb fp, {r4, r5, r6, fp, sp, pc}^
Lcopystrfault:
teq r3, #0
subne r6, r1, r6
strne r6, [r3]
mov r1, #0
str r1, [r5, #(U_PCB + PCB_ONFAULT)]
/* Return value is provided by fault handler. */
#ifdef __APCS_26__
ldmdb fp, {r4, r5, r6, fp, sp, pc}^
#else
ldmdb fp, {r4, r5, r6, fp, sp, pc}
#endif
/* LINTSTUB: Func: int fubyte(void *base) */
ENTRY(fubyte)
mov ip, lr /* data-abort safety */
adr r1, Lfusufault
ldr r2, Lcurproc
ldr r2, [r2]
ldr r2, [r2, #P_ADDR]
str r1, [r2, #(U_PCB + PCB_ONFAULT)]
/* XXX Warning: Rn and Rd must be different in LDRT */
ldrbt r0, [r0]
mov r1, #0
str r1, [r2, #(U_PCB + PCB_ONFAULT)]
#ifdef __APCS_26__
movs pc, ip
#else
mov pc, ip
#endif
/* LINTSTUB: Func: int fuword(void *base) */
ENTRY(fuword)
mov ip, lr
adr r1, Lfusufault
ldr r2, Lcurproc
ldr r2, [r2]
ldr r2, [r2, #P_ADDR]
str r1, [r2, #(U_PCB + PCB_ONFAULT)]
/* XXX Warning: Rn and Rd must be different in LDRT */
ldrt r0, [r0]
mov r1, #0
str r1, [r2, #(U_PCB + PCB_ONFAULT)]
#ifdef __APCS_26__
movs pc, ip
#else
mov pc, ip
#endif
/* LINTSTUB: Func: int subyte(void *base, int c) */
ENTRY(subyte)
mov ip, lr
adr r3, Lfusufault
ldr r2, Lcurproc
ldr r2, [r2]
ldr r2, [r2, #P_ADDR]
str r3, [r2, #(U_PCB + PCB_ONFAULT)]
strbt r1, [r0]
mov r0, #0
str r0, [r2, #(U_PCB + PCB_ONFAULT)]
#ifdef __APCS_26__
movs pc, ip
#else
mov pc, ip
#endif
/* LINTSTUB: Func: int suword(void *base, long c) */
ENTRY(suword)
mov ip, lr
adr r3, Lfusufault
ldr r2, Lcurproc
ldr r2, [r2]
ldr r2, [r2, #P_ADDR]
str r3, [r2, #(U_PCB + PCB_ONFAULT)]
strt r1, [r0]
mov r0, #0
str r0, [r2, #(U_PCB + PCB_ONFAULT)]
#ifdef __APCS_26__
movs pc, ip
#else
mov pc, ip
#endif
Lfusufault:
mov r0, #0
str r0, [r2, #(U_PCB + PCB_ONFAULT)]
mvn r0, #0
#ifdef __APCS_26__
movs pc, ip
#else
mov pc, ip
#endif
Lcurproc:
.word _C_LABEL(curproc)

View File

@ -1,4 +1,4 @@
/* $NetBSD: cpu.c,v 1.11 2001/08/20 12:20:05 wiz Exp $ */
/* $NetBSD: cpu.c,v 1.1 2002/03/24 15:46:44 bjh21 Exp $ */
/*-
* Copyright (c) 2000, 2001 Ben Harris
@ -33,7 +33,7 @@
#include <sys/param.h>
__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.11 2001/08/20 12:20:05 wiz Exp $");
__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.1 2002/03/24 15:46:44 bjh21 Exp $");
#include <sys/device.h>
#include <sys/proc.h>
@ -46,7 +46,7 @@ __KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.11 2001/08/20 12:20:05 wiz Exp $");
#include <machine/machdep.h>
#include <machine/pcb.h>
#include <arch/arm26/arm26/cpuvar.h>
#include <arch/acorn26/acorn26/cpuvar.h>
#include "opt_cputypes.h"
@ -193,7 +193,7 @@ arm2_undef_handler(u_int addr, u_int insn, struct trapframe *frame,
/*
* In order for the following macro to work, any function using it
* must ensure that tf->r15 is copied into getreg(15). This is safe
* with the current trapframe layout on arm26, but be careful.
* with the current trapframe layout on acorn26, but be careful.
*/
#define getreg(r) (((register_t *)&tf->tf_r0)[r])

View File

@ -1,4 +1,4 @@
/* $NetBSD: cpuvar.h,v 1.1 2000/05/09 21:55:55 bjh21 Exp $ */
/* $NetBSD: cpuvar.h,v 1.1 2002/03/24 15:46:44 bjh21 Exp $ */
/*-
* Copyright (c) 2000 Ben Harris
* All rights reserved.

View File

@ -1,4 +1,4 @@
/* $NetBSD: db_interface.c,v 1.13 2001/11/23 21:18:31 thorpej Exp $ */
/* $NetBSD: db_interface.c,v 1.1 2002/03/24 15:46:44 bjh21 Exp $ */
/*
* Copyright (c) 1996 Scott K. Stevens
@ -280,7 +280,7 @@ static struct undefined_handler db_uh;
void
db_machine_init()
{
#ifndef arm26
#ifndef acorn26
struct exec *kernexec = (struct exec *)KERNEL_TEXT_BASE;
int len;

View File

@ -1,4 +1,4 @@
/* $NetBSD: db_machdep.c,v 1.6 2001/06/12 20:16:22 bjh21 Exp $ */
/* $NetBSD: db_machdep.c,v 1.1 2002/03/24 15:46:45 bjh21 Exp $ */
/*
* Copyright (c) 1996 Mark Brinicombe

View File

@ -1,4 +1,4 @@
/* $NetBSD: except.c,v 1.44 2002/02/14 11:54:16 bjh21 Exp $ */
/* $NetBSD: except.c,v 1.1 2002/03/24 15:46:45 bjh21 Exp $ */
/*-
* Copyright (c) 1998, 1999, 2000 Ben Harris
* All rights reserved.
@ -32,7 +32,7 @@
#include <sys/param.h>
__KERNEL_RCSID(0, "$NetBSD: except.c,v 1.44 2002/02/14 11:54:16 bjh21 Exp $");
__KERNEL_RCSID(0, "$NetBSD: except.c,v 1.1 2002/03/24 15:46:45 bjh21 Exp $");
#include "opt_cputypes.h"
#include "opt_ddb.h"

View File

@ -1,4 +1,4 @@
/* $NetBSD: fpu.c,v 1.4 2001/03/13 21:00:13 bjh21 Exp $ */
/* $NetBSD: fpu.c,v 1.1 2002/03/24 15:46:45 bjh21 Exp $ */
/*-
* Copyright (c) 2000, 2001 Ben Harris
@ -33,7 +33,7 @@
#include <sys/param.h>
__KERNEL_RCSID(0, "$NetBSD: fpu.c,v 1.4 2001/03/13 21:00:13 bjh21 Exp $");
__KERNEL_RCSID(0, "$NetBSD: fpu.c,v 1.1 2002/03/24 15:46:45 bjh21 Exp $");
#include <sys/device.h>
#include <sys/proc.h>
@ -44,7 +44,7 @@ __KERNEL_RCSID(0, "$NetBSD: fpu.c,v 1.4 2001/03/13 21:00:13 bjh21 Exp $");
#include <machine/pcb.h>
#include <arch/arm26/arm26/fpuvar.h>
#include <arch/acorn26/acorn26/fpuvar.h>
#include "opt_fputypes.h"

View File

@ -1,4 +1,4 @@
/* $NetBSD: fpu_asm.S,v 1.2 2001/01/18 17:47:59 tv Exp $ */
/* $NetBSD: fpu_asm.S,v 1.1 2002/03/24 15:46:45 bjh21 Exp $ */
/*-
* Copyright (c) 2001 Ben Harris
@ -33,7 +33,7 @@
#include <machine/asm.h>
RCSID("$NetBSD: fpu_asm.S,v 1.2 2001/01/18 17:47:59 tv Exp $")
RCSID("$NetBSD: fpu_asm.S,v 1.1 2002/03/24 15:46:45 bjh21 Exp $")
#include <machine/fpureg.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: fpuvar.h,v 1.1 2001/03/08 21:12:48 bjh21 Exp $ */
/* $NetBSD: fpuvar.h,v 1.1 2002/03/24 15:46:45 bjh21 Exp $ */
/*-
* Copyright (c) 2001 Ben Harris

View File

@ -1,4 +1,4 @@
# $NetBSD: genassym.cf,v 1.5 2001/09/20 21:54:11 bjh21 Exp $
# $NetBSD: genassym.cf,v 1.1 2002/03/24 15:46:46 bjh21 Exp $
#
# Copyright (c) 1999 Ben Harris
# All rights reserved.
@ -37,7 +37,7 @@ include <machine/pcb.h>
if NECA > 0
include <sys/mbuf.h>
include <arch/arm26/ioc/if_ecavar.h>
include <arch/acorn26/ioc/if_ecavar.h>
endif
define U_PCB offsetof(struct user, u_pcb)

View File

@ -1,4 +1,4 @@
/* $NetBSD: irq.c,v 1.25 2001/12/20 01:20:24 thorpej Exp $ */
/* $NetBSD: irq.c,v 1.1 2002/03/24 15:46:46 bjh21 Exp $ */
/*-
* Copyright (c) 2000, 2001 Ben Harris
@ -33,7 +33,7 @@
#include <sys/param.h>
__RCSID("$NetBSD: irq.c,v 1.25 2001/12/20 01:20:24 thorpej Exp $");
__RCSID("$NetBSD: irq.c,v 1.1 2002/03/24 15:46:46 bjh21 Exp $");
#include <sys/device.h>
#include <sys/kernel.h> /* for cold */
@ -50,8 +50,8 @@ __RCSID("$NetBSD: irq.c,v 1.25 2001/12/20 01:20:24 thorpej Exp $");
#include <machine/irq.h>
#include <machine/machdep.h>
#include <arch/arm26/iobus/iocreg.h>
#include <arch/arm26/iobus/iocvar.h>
#include <arch/acorn26/iobus/iocreg.h>
#include <arch/acorn26/iobus/iocvar.h>
#include "opt_ddb.h"
#include "opt_flashything.h"
@ -66,10 +66,10 @@ __RCSID("$NetBSD: irq.c,v 1.25 2001/12/20 01:20:24 thorpej Exp $");
#include <machine/fiq.h>
#endif
#if NIOEB > 0
#include <arch/arm26/ioc/ioebvar.h>
#include <arch/acorn26/ioc/ioebvar.h>
#endif
#if NUNIXBP > 0
#include <arch/arm26/podulebus/unixbpvar.h>
#include <arch/acorn26/podulebus/unixbpvar.h>
#endif
#define NIRQ 20
@ -315,7 +315,7 @@ void irq_genmasks()
#ifdef FLASHYTHING
#include <machine/memcreg.h>
#include <arch/arm26/vidc/vidcreg.h>
#include <arch/acorn26/vidc/vidcreg.h>
static const int iplcolours[] = {
VIDC_PALETTE_ENTRY( 0, 0, 0, 0), /* Black: IPL_NONE */

View File

@ -1,4 +1,4 @@
/* $NetBSD: locore.S,v 1.24 2001/12/21 22:56:18 bjh21 Exp $ */
/* $NetBSD: locore.S,v 1.1 2002/03/24 15:46:46 bjh21 Exp $ */
/*
* Copyright (c) 1998, 1999, 2000 Ben Harris
* Copyright (C) 1994-1997 Mark Brinicombe
@ -457,4 +457,4 @@ _C_LABEL(intrcnt):
.global _C_LABEL(eintrcnt)
_C_LABEL(eintrcnt):
RCSID("$NetBSD: locore.S,v 1.24 2001/12/21 22:56:18 bjh21 Exp $")
RCSID("$NetBSD: locore.S,v 1.1 2002/03/24 15:46:46 bjh21 Exp $")

View File

@ -1,4 +1,4 @@
/* $NetBSD: machdep.c,v 1.14 2002/03/18 21:14:34 bjh21 Exp $ */
/* $NetBSD: machdep.c,v 1.1 2002/03/24 15:46:46 bjh21 Exp $ */
/*-
* Copyright (c) 1998 Ben Harris
@ -33,7 +33,7 @@
#include <sys/param.h>
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.14 2002/03/18 21:14:34 bjh21 Exp $");
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.1 2002/03/24 15:46:46 bjh21 Exp $");
#include <sys/buf.h>
#include <sys/kernel.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: mem.c,v 1.5 2002/02/27 01:20:51 christos Exp $ */
/* $NetBSD: mem.c,v 1.1 2002/03/24 15:46:46 bjh21 Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@ -137,7 +137,7 @@ mmrw(dev, uio, flags)
error = uiomove((caddr_t)v, c, uio);
else
return (EFAULT);
continue;
break;
case DEV_NULL:
if (uio->uio_rw == UIO_WRITE)
@ -146,8 +146,8 @@ mmrw(dev, uio, flags)
case DEV_ZERO:
if (uio->uio_rw == UIO_WRITE) {
c = iov->iov_len;
break;
uio->uio_resid = 0;
return (0);
}
if (zeropage == NULL) {
zeropage = (caddr_t)
@ -156,17 +156,11 @@ mmrw(dev, uio, flags)
}
c = min(iov->iov_len, NBPG);
error = uiomove(zeropage, c, uio);
continue;
break;
default:
return (ENXIO);
}
if (error)
break;
(caddr_t)iov->iov_base += c;
iov->iov_len -= c;
uio->uio_offset += c;
uio->uio_resid -= c;
}
if (minor(dev) == DEV_MEM) {
/*unlock:*/

View File

@ -1,4 +1,4 @@
/* $NetBSD: pmap.c,v 1.37 2002/03/08 20:48:30 thorpej Exp $ */
/* $NetBSD: pmap.c,v 1.1 2002/03/24 15:46:47 bjh21 Exp $ */
/*-
* Copyright (c) 1997, 1998, 2000 Ben Harris
* All rights reserved.
@ -105,7 +105,7 @@
#include <sys/param.h>
__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.37 2002/03/08 20:48:30 thorpej Exp $");
__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.1 2002/03/24 15:46:47 bjh21 Exp $");
#include <sys/kernel.h> /* for cold */
#include <sys/malloc.h>
@ -119,7 +119,7 @@ __KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.37 2002/03/08 20:48:30 thorpej Exp $");
#include <machine/machdep.h>
#include <machine/memcreg.h>
#include <arch/arm26/arm26/cpuvar.h>
#include <arch/acorn26/acorn26/cpuvar.h>
#ifdef PMAP_DEBUG_MODIFIED
#include <sys/md4.h>
@ -1113,7 +1113,7 @@ pmap_md4_page(unsigned char digest[16], paddr_t pa)
/*
* This is meant to return the range of kernel vm that is available
* after loading the kernel. Since NetBSD/arm26 runs the kernel from
* after loading the kernel. Since NetBSD/acorn26 runs the kernel from
* physically-mapped space, we just return all of kernel vm. Oh,
* except for the single page at the end where we map
* otherwise-unmapped pages.

View File

@ -1,4 +1,4 @@
/* $NetBSD: rscons.c,v 1.1 2000/05/09 21:55:57 bjh21 Exp $ */
/* $NetBSD: rscons.c,v 1.1 2002/03/24 15:46:47 bjh21 Exp $ */
/*-
* Copyright (c) 1997, 1998 Ben Harris
* All rights reserved.

View File

@ -1,4 +1,4 @@
/* $NetBSD: softintr.c,v 1.10 2001/09/16 12:58:53 bjh21 Exp $ */
/* $NetBSD: softintr.c,v 1.1 2002/03/24 15:46:47 bjh21 Exp $ */
/*
* Copyright (c) 1999 Ben Harris.
@ -38,7 +38,7 @@
#include <sys/param.h>
__RCSID("$NetBSD: softintr.c,v 1.10 2001/09/16 12:58:53 bjh21 Exp $");
__RCSID("$NetBSD: softintr.c,v 1.1 2002/03/24 15:46:47 bjh21 Exp $");
#include <sys/malloc.h>
#include <sys/queue.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: start.c,v 1.12 2001/08/25 17:55:24 bjh21 Exp $ */
/* $NetBSD: start.c,v 1.1 2002/03/24 15:46:48 bjh21 Exp $ */
/*-
* Copyright (c) 1998, 2000 Ben Harris
* All rights reserved.
@ -32,7 +32,7 @@
#include <sys/param.h>
__KERNEL_RCSID(0, "$NetBSD: start.c,v 1.12 2001/08/25 17:55:24 bjh21 Exp $");
__KERNEL_RCSID(0, "$NetBSD: start.c,v 1.1 2002/03/24 15:46:48 bjh21 Exp $");
#include <sys/msgbuf.h>
#include <sys/user.h>
@ -53,7 +53,7 @@ __KERNEL_RCSID(0, "$NetBSD: start.c,v 1.12 2001/08/25 17:55:24 bjh21 Exp $");
#include "ioc.h"
#if NIOC > 0
#include <arch/arm26/iobus/iocreg.h>
#include <arch/acorn26/iobus/iocreg.h>
#endif
extern void main __P((void)); /* XXX Should be in a header file */

View File

@ -1,11 +1,11 @@
/* $NetBSD: stubs.c,v 1.10 2001/11/16 13:48:33 bjh21 Exp $ */
/* $NetBSD: stubs.c,v 1.1 2002/03/24 15:46:48 bjh21 Exp $ */
/*
* stubs.c -- functions I haven't written yet
*/
#include <sys/param.h>
__RCSID("$NetBSD: stubs.c,v 1.10 2001/11/16 13:48:33 bjh21 Exp $");
__RCSID("$NetBSD: stubs.c,v 1.1 2002/03/24 15:46:48 bjh21 Exp $");
#include <sys/kernel.h>
#include <sys/systm.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: sys_machdep.c,v 1.1 2001/07/28 19:12:50 bjh21 Exp $ */
/* $NetBSD: sys_machdep.c,v 1.1 2002/03/24 15:46:48 bjh21 Exp $ */
/*
* Copyright (c) 1995-1997 Mark Brinicombe.
@ -42,7 +42,7 @@
#include <sys/param.h>
__KERNEL_RCSID(0, "$NetBSD: sys_machdep.c,v 1.1 2001/07/28 19:12:50 bjh21 Exp $");
__KERNEL_RCSID(0, "$NetBSD: sys_machdep.c,v 1.1 2002/03/24 15:46:48 bjh21 Exp $");
#include <sys/systm.h>
#include <sys/mount.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: vm_machdep.c,v 1.20 2002/03/04 02:43:23 simonb Exp $ */
/* $NetBSD: vm_machdep.c,v 1.1 2002/03/24 15:46:49 bjh21 Exp $ */
/*-
* Copyright (c) 2000, 2001 Ben Harris
@ -66,7 +66,7 @@
#include <sys/param.h>
__RCSID("$NetBSD: vm_machdep.c,v 1.20 2002/03/04 02:43:23 simonb Exp $");
__RCSID("$NetBSD: vm_machdep.c,v 1.1 2002/03/24 15:46:49 bjh21 Exp $");
#include <sys/buf.h>
#include <sys/mount.h> /* XXX syscallargs.h uses fhandle_t and fsid_t */

View File

@ -1,4 +1,4 @@
# $NetBSD: FOURMEG,v 1.23 2002/03/10 19:56:39 lukem Exp $
# $NetBSD: FOURMEG,v 1.1 2002/03/24 15:46:50 bjh21 Exp $
# FOURMEG arm26 configuration -- something small

View File

@ -1,4 +1,4 @@
# $NetBSD: GENERIC,v 1.34 2002/03/10 19:56:39 lukem Exp $
# $NetBSD: GENERIC,v 1.1 2002/03/24 15:46:50 bjh21 Exp $
#
# GENERIC machine description file
#
@ -18,7 +18,7 @@
# of each device driver in this file see the section 4 man page for the
# device.
include "arch/arm26/conf/std.arm26"
include "arch/acorn26/conf/std.acorn26"
maxusers 8
@ -93,7 +93,7 @@ options INET6 # IPV6
#options COMPAT_43 # 4.3BSD compatibility.
# Binary compatibility with previous versions of NetBSD.
# None yet, since NetBSD/arm26 hasn't been released.
# None yet, since NetBSD/acorn26 hasn't been released.
# System V IPC
options SYSVMSG # System V-like message queues

View File

@ -1,15 +1,15 @@
# $NetBSD: Makefile.arm26,v 1.20 2002/03/07 23:15:23 bjh21 Exp $
# $NetBSD: Makefile.acorn26,v 1.1 2002/03/24 15:46:51 bjh21 Exp $
# Makefile for NetBSD
#
# This makefile is constructed from a machine description:
# config machineid
# Most changes should be made in the machine description
# /sys/arch/arm26/conf/``machineid''
# /sys/arch/acorn26/conf/``machineid''
# after which you should do
# config machineid
# Machine generic makefile changes should be made in
# /sys/arch/arm26/conf/Makefile.i386
# /sys/arch/acorn26/conf/Makefile.i386
# after which config should be rerun for all machines of that type.
#
# To specify debugging, add the config line: makeoptions DEBUG="-g"
@ -25,19 +25,19 @@ NEED_OWN_INSTALL_TARGET?=no
## (1) port identification
##
ARM= $S/arch/arm
ARM26= $S/arch/arm26
GENASSYM= ${ARM26}/arm26/genassym.cf
ACORN26= $S/arch/acorn26
GENASSYM= ${ACORN26}/acorn26/genassym.cf
##
## (2) compile settings
##
CPPFLAGS+= -Darm26
CPPFLAGS+= -Dacorn26
CWARNFLAGS+= -Wcomment
LOOSE_PROTOTYPES= yes
# We'd like GCC to leave R14 alone as much as possible (so page faults in the
# kernel are safer).
CFLAGS+= -ffixed-r14
# arm26 systems can safely do unaligned loads.
# acorn26 systems can safely do unaligned loads.
CFLAGS+= -mshort-load-words
AFLAGS+= -x assembler-with-cpp -traditional-cpp
@ -50,9 +50,9 @@ AFLAGS+= -x assembler-with-cpp -traditional-cpp
##
MD_OBJS= vectors.o locore.o
MD_CFILES=
MD_SFILES= ${ARM}/arm/vectors.S ${ARM26}/arm26/locore.S
MD_SFILES= ${ARM}/arm/vectors.S ${ACORN26}/acorn26/locore.S
locore.o: ${ARM26}/arm26/locore.S assym.h
locore.o: ${ACORN26}/acorn26/locore.S assym.h
${NORMAL_S}
vectors.o: ${ARM}/arm/vectors.S

View File

@ -1,4 +1,4 @@
# $NetBSD: files.arm26,v 1.45 2002/03/17 12:00:56 bjh21 Exp $
# $NetBSD: files.acorn26,v 1.1 2002/03/24 15:46:51 bjh21 Exp $
# Copyright (c) 1997, 1998, 2000 Ben Harris
# All rights reserved.
@ -25,7 +25,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.
# This file is part of NetBSD/arm26 -- a port of NetBSD to ARM2/3 machines.
# This file is part of NetBSD/acorn26 -- a port of NetBSD to ARM2/3 machines.
maxpartitions 8
maxusers 2 8 64
@ -48,48 +48,53 @@ define fiq
# CPU
#device cpu { }
attach cpu at root with cpu_root
file arch/arm26/arm26/cpu.c cpu
file arch/acorn26/acorn26/cpu.c cpu
# Floating-point unit
device fpu
attach fpu at cpu
defflag opt_fputypes.h FPU_FPPC FPU_FPA
file arch/arm26/arm26/fpu.c fpu needs-flag
file arch/arm26/arm26/fpu_asm.S fpu
file arch/acorn26/acorn26/fpu.c fpu needs-flag
file arch/acorn26/acorn26/fpu_asm.S fpu
# I/O bus (on the far side of the address and data latches)
device iobus { base = -1 }
attach iobus at root
file arch/arm26/iobus/iobus.c iobus
file arch/acorn26/iobus/iobus.c iobus
# 82C710/1 on A5000 etc will be at iobus0 base 0x00010000 (and 0x00012000???)
# I/O controller (Albion) (usually at iobus0 base 0x00200000)
device ioc { [bank = -1], [offset = 0] }
attach ioc at iobus
file arch/arm26/iobus/ioc.c ioc needs-flag
file arch/arm26/ioc/ioc_fiq_util.S fiq needs-flag
file arch/acorn26/iobus/ioc.c ioc needs-flag
file arch/acorn26/ioc/ioc_fiq_util.S fiq needs-flag
# I^2C bus (bit-banged through IOC control register)
device iic { addr = -1 }
attach iic at ioc
file arch/arm26/ioc/iic.c iic
file arch/acorn26/ioc/iic.c iic
# PCF8583 I^2C Clock/calendar/RAM
device rtc
attach rtc at iic
file arch/arm26/ioc/rtc.c rtc
file arch/acorn26/ioc/rtc.c rtc
file dev/clock_subr.c rtc
# DS2401 Silicon Serial Number
device ssn
attach ssn at ioc
file arch/acorn26/ioc/ssn.c ssn
# I/O Extension Block (usually at ioc0 bank 5)
device ioeb { [offset = -1] }
attach ioeb at ioc
file arch/arm26/ioc/ioeb.c ioeb needs-flag
file arch/acorn26/ioc/ioeb.c ioeb needs-flag
# Latches (random internal use) (usually at ioc0 bank 5)
device latches
attach latches at ioc
file arch/arm26/ioc/latches.c latches
file arch/acorn26/ioc/latches.c latches
# On-board keyboard interface
device arckbd { }
@ -98,9 +103,9 @@ device arcwskbd: wskbddev
attach arcwskbd at arckbd
device arcwsmouse: wsmousedev
attach arcwsmouse at arckbd
file arch/arm26/ioc/arckbd.c arckbd | arcwskbd | arcwsmouse
file arch/acorn26/ioc/arckbd.c arckbd | arcwskbd | arcwsmouse
needs-flag
file arch/arm26/ioc/arckbdmap.c arckbd
file arch/acorn26/ioc/arckbdmap.c arckbd
# On-board WD 1772 floppy controller (usually at bank 1 irq 12 fiq 0/1)
# Not to be confused with fdc, which will be the PC-style one on A5k etc.
@ -114,18 +119,18 @@ attach wf at wfdc
# Econet module (Motorola 6854) (usually at bank 2 fiq 2)
device eca: fiq, eco, ifnet
attach eca at ioc
file arch/arm26/ioc/if_eca.c eca needs-flag
file arch/arm26/ioc/if_eca_fiq.S eca
file arch/acorn26/ioc/if_eca.c eca needs-flag
file arch/acorn26/ioc/if_eca_fiq.S eca
# On-board Rockwell 6551 serial (usually at bank 3 irq 10/1)
device rs: tty
attach rs at ioc
file arch/arm26/arm26/rscons.c rs needs-flag
file arch/acorn26/acorn26/rscons.c rs needs-flag
# On-board printer port (usually at bank 5 addr 0x10 irq 0/2)
device arcpp
attach arcpp at ioc
file arch/arm26/ioc/arcpp.c arcpp needs-flag
file arch/acorn26/ioc/arcpp.c arcpp needs-flag
# Podule interface (podules listed later) (usually at bank 4 irq 13 fiq 6)
@ -138,9 +143,9 @@ attach unixbp at ioc
# attachments in the right order.
include "dev/podulebus/files.podulebus"
attach podulebus at ioc
file arch/arm26/podulebus/podulebus.c podulebus
file arch/arm26/podulebus/podloader_asm.S podloader needs-flag
file arch/arm26/podulebus/unixbp.c unixbp needs-flag
file arch/acorn26/podulebus/podulebus.c podulebus
file arch/acorn26/podulebus/podloader_asm.S podloader needs-flag
file arch/acorn26/podulebus/unixbp.c unixbp needs-flag
# Acorn ST506 interface (usually at bank 5 irq 11, or sometimes on a podule)
device hdc { drive = -1 }
@ -153,7 +158,7 @@ attach hd at hdc
# VIDC/MEMC audio/video subsystems.
device arcvideo: rasops1, rasops2, rasops4, rasops8, wsemuldisplaydev
attach arcvideo at root
file arch/arm26/vidc/arcvideo.c arcvideo needs-flag
file arch/acorn26/vidc/arcvideo.c arcvideo needs-flag
device arcaudio: audio
attach arcaudio at root
@ -171,7 +176,7 @@ file dev/ic/lpt_upc.c lpt_upc
# This section belongs here
attach upc at iobus with upc_iobus
file arch/arm26/iobus/upc_iobus.c upc_iobus
file arch/acorn26/iobus/upc_iobus.c upc_iobus
###
# Assorted podules
@ -180,12 +185,12 @@ file arch/arm26/iobus/upc_iobus.c upc_iobus
# i-cubed EtherLAN 100, 200 and 500
device eh: ether, ifnet, arp, dp8390nic, podloader
attach eh at podulebus
file arch/arm26/podulebus/if_eh.c eh
file arch/acorn26/podulebus/if_eh.c eh
# PowerROM test driver
device powerrom: podloader
attach powerrom at podulebus
file arch/arm26/podulebus/powerrom.c powerrom
file arch/acorn26/podulebus/powerrom.c powerrom
# Memory disk for installation (or ROM versions?)
file dev/md_root.c memory_disk_hooks
@ -198,27 +203,27 @@ major { md = 1 }
#file dev/cons.c
file dev/cninit.c
file arch/arm26/arm26/db_interface.c ddb
file arch/arm26/arm26/db_machdep.c ddb
file arch/acorn26/acorn26/db_interface.c ddb
file arch/acorn26/acorn26/db_machdep.c ddb
file arch/arm26/arm26/start.c
file arch/arm26/arm26/autoconf.c
file arch/arm26/arm26/bus.c
file arch/arm26/arm26/conf.c
file arch/arm26/arm26/cons_machdep.c
file arch/arm26/arm26/copyinout.S
file arch/arm26/arm26/except.c
file arch/arm26/arm26/irq.c
file arch/arm26/arm26/Locore.c
file arch/arm26/arm26/machdep.c
file arch/arm26/arm26/mem.c
file arch/arm26/arm26/pmap.c
#file arch/arm26/arm26/rscons.c
file arch/arm26/arm26/softintr.c
file arch/arm26/arm26/stubs.c
file arch/arm26/arm26/sys_machdep.c
file arch/arm26/arm26/vm_machdep.c
file arch/acorn26/acorn26/start.c
file arch/acorn26/acorn26/autoconf.c
file arch/acorn26/acorn26/bus.c
file arch/acorn26/acorn26/conf.c
file arch/acorn26/acorn26/cons_machdep.c
file arch/acorn26/acorn26/copyinout.S
file arch/acorn26/acorn26/except.c
file arch/acorn26/acorn26/irq.c
file arch/acorn26/acorn26/Locore.c
file arch/acorn26/acorn26/machdep.c
file arch/acorn26/acorn26/mem.c
file arch/acorn26/acorn26/pmap.c
#file arch/acorn26/acorn26/rscons.c
file arch/acorn26/acorn26/softintr.c
file arch/acorn26/acorn26/stubs.c
file arch/acorn26/acorn26/sys_machdep.c
file arch/acorn26/acorn26/vm_machdep.c
file arch/arm/arm/disksubr.c disk
file arch/arm/arm/disksubr_acorn.c disk
file arch/arm/arm/disksubr_mbr.c disk
file arch/arm/arm/disksubr.c disk
file arch/arm/arm/disksubr_acorn.c disk
file arch/arm/arm/disksubr_mbr.c disk

View File

@ -0,0 +1,6 @@
# $NetBSD: std.acorn26,v 1.1 2002/03/24 15:46:51 bjh21 Exp $
# Standard NetBSD/acorn26 options
machine acorn26 arm

View File

@ -1,7 +1,7 @@
# $NetBSD: Makefile,v 1.13 2001/11/25 16:22:48 thorpej Exp $
# $NetBSD: Makefile,v 1.1 2002/03/24 15:46:52 bjh21 Exp $
KDIR= /sys/arch/arm26/include
INCSDIR= /usr/include/arm26
KDIR= /sys/arch/acorn26/include
INCSDIR= /usr/include/acorn26
INCS= ansi.h aout_machdep.h asm.h \
boot.h bswap.h bus.h \

View File

@ -0,0 +1,3 @@
/* $NetBSD: ansi.h,v 1.1 2002/03/24 15:46:52 bjh21 Exp $ */
#include <arm/ansi.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: aout_machdep.h,v 1.1 2002/03/24 15:46:52 bjh21 Exp $ */
#include <arm/aout_machdep.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: asm.h,v 1.1 2002/03/24 15:46:53 bjh21 Exp $ */
#include <arm/asm.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: boot.h,v 1.2 2001/07/28 12:53:06 bjh21 Exp $ */
/* $NetBSD: boot.h,v 1.1 2002/03/24 15:46:53 bjh21 Exp $ */
/*-
* Copyright (c) 1998 Ben Harris
* All rights reserved.

View File

@ -0,0 +1,3 @@
/* $NetBSD: bootconfig.h,v 1.1 2002/03/24 15:46:53 bjh21 Exp $ */
#include <arm/bootconfig.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: bswap.h,v 1.1 2002/03/24 15:46:54 bjh21 Exp $ */
#include <arm/bswap.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: bus.h,v 1.7 2001/11/16 13:34:03 bjh21 Exp $ */
/* $NetBSD: bus.h,v 1.1 2002/03/24 15:46:54 bjh21 Exp $ */
/*-
* Copyright (c) 2000 Ben Harris
@ -31,8 +31,8 @@
* bus.h - Bus space functions for brivers
*/
#ifndef _ARM26_BUS_H_
#define _ARM26_BUS_H_
#ifndef _ACORN26_BUS_H_
#define _ACORN26_BUS_H_
#include <arm/blockio.h>
@ -70,7 +70,7 @@ extern int bus_space_shift(bus_space_tag_t, bus_space_handle_t, int,
#define bus_space_alloc(t, rs, re, s, a, b, c, ap, hp) (-1)
#define bus_space_free(t, h, s) /* Do nothing */
/* Mapping bus space into user address space (impossible on arm26) */
/* Mapping bus space into user address space (impossible on acorn26) */
#define bus_space_mmap(t, a, o, p, f) (-1)
/* Used by ne2000.c */
@ -145,4 +145,4 @@ extern void bus_space_copy_region_2(bus_space_tag_t, bus_space_handle_t,
typedef void *bus_dmamap_t;
#endif /* _ARM26_BUS_H_ */
#endif /* _ACORN26_BUS_H_ */

View File

@ -0,0 +1,3 @@
/* $NetBSD: cdefs.h,v 1.1 2002/03/24 15:46:55 bjh21 Exp $ */
#include <arm/cdefs.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: cpu.h,v 1.1 2002/03/24 15:46:55 bjh21 Exp $ */
#include <arm/cpu.h>

View File

@ -1,8 +1,8 @@
/* $NetBSD: db_machdep.h,v 1.6 2001/11/16 14:39:31 bjh21 Exp $ */
/* $NetBSD: db_machdep.h,v 1.1 2002/03/24 15:46:55 bjh21 Exp $ */
#include <arm/db_machdep.h>
/* arm26 uses ELF */
/* acorn26 uses ELF */
#undef DB_AOUT_SYMBOLS
#define DB_ELF_SYMBOLS
#define DB_ELFSIZE 32

View File

@ -0,0 +1,3 @@
/* $NetBSD: disklabel.h,v 1.1 2002/03/24 15:46:56 bjh21 Exp $ */
#include <arm/disklabel.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: elf_machdep.h,v 1.1 2002/03/24 15:46:56 bjh21 Exp $ */
#include <arm/elf_machdep.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: endian.h,v 1.1 2002/03/24 15:46:56 bjh21 Exp $ */
#include <sys/endian.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: endian_machdep.h,v 1.1 2002/03/24 15:46:57 bjh21 Exp $ */
#include <arm/endian_machdep.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: fiq.h,v 1.4 2001/12/20 01:20:25 thorpej Exp $ */
/* $NetBSD: fiq.h,v 1.1 2002/03/24 15:46:57 bjh21 Exp $ */
/*-
* Copyright (c) 2001 Ben Harris
@ -27,9 +27,9 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _ARM26_FIQ_H_
#define _ARM26_FIQ_H_
#include <arch/arm26/iobus/iocreg.h>
#ifndef _ACORN26_FIQ_H_
#define _ACORN26_FIQ_H_
#include <arch/acorn26/iobus/iocreg.h>
/*
* These definitions specify how the devices are wired to the IOC

View File

@ -0,0 +1,3 @@
/* $NetBSD: float.h,v 1.1 2002/03/24 15:46:57 bjh21 Exp $ */
#include <arm/float.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: fp.h,v 1.1 2002/03/24 15:46:57 bjh21 Exp $ */
#include <arm/fp.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: fpureg.h,v 1.1 2000/12/23 13:37:03 bjh21 Exp $ */
/* $NetBSD: fpureg.h,v 1.1 2002/03/24 15:46:58 bjh21 Exp $ */
/*
* ARM FPU definitions

View File

@ -1,4 +1,4 @@
/* $NetBSD: frame.h,v 1.7 2001/08/31 04:44:55 simonb Exp $ */
/* $NetBSD: frame.h,v 1.1 2002/03/24 15:46:58 bjh21 Exp $ */
/*
* Copyright (c) 1999 Ben Harris.

View File

@ -0,0 +1,3 @@
/* $NetBSD: ieee.h,v 1.1 2002/03/24 15:46:59 bjh21 Exp $ */
#include <arm/ieee.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: ieeefp.h,v 1.1 2002/03/24 15:46:59 bjh21 Exp $ */
#include <arm/ieeefp.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: int_const.h,v 1.1 2002/03/24 15:47:00 bjh21 Exp $ */
#include <arm/int_const.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: int_fmtio.h,v 1.1 2002/03/24 15:47:00 bjh21 Exp $ */
#include <arm/int_fmtio.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: int_limits.h,v 1.1 2002/03/24 15:47:00 bjh21 Exp $ */
#include <arm/int_limits.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: int_mwgwtypes.h,v 1.1 2002/03/24 15:47:01 bjh21 Exp $ */
#include <arm/int_mwgwtypes.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: int_types.h,v 1.1 2002/03/24 15:47:01 bjh21 Exp $ */
#include <arm/int_types.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: intr.h,v 1.10 2001/08/21 22:47:18 bjh21 Exp $ */
/* $NetBSD: intr.h,v 1.1 2002/03/24 15:47:02 bjh21 Exp $ */
/*-
* Copyright (c) 1998, 2000 Ben Harris
* All rights reserved.
@ -74,15 +74,16 @@
#define splserial() raisespl(IPL_SERIAL)
#define splclock() raisespl(IPL_CLOCK)
#define splstatclock() raisespl(IPL_STATCLOCK)
#define splsched() raisespl(IPL_SCHED)
#define splsched() splhigh()
/* #define splsched() splhigh() */
#define spllock() splhigh()
#define spl0() lowerspl(IPL_NONE)
#define spllowersoftclock() lowerspl(IPL_SOFTCLOCK)
#define splx(s) lowerspl(s)
extern int current_spl_level; /* XXX tautological name */
extern int current_spl; /* XXX tautological name */
extern int splhigh(void);
extern int raisespl(int);

View File

@ -1,4 +1,4 @@
/* $NetBSD: ipkdb.h,v 1.1 2000/05/09 21:55:59 bjh21 Exp $ */
/* $NetBSD: ipkdb.h,v 1.1 2002/03/24 15:47:03 bjh21 Exp $ */
/*
* Copyright (C) 1993, 1994 Wolfgang Solfrank.

View File

@ -1,4 +1,4 @@
/* $NetBSD: irq.h,v 1.8 2001/01/23 22:07:58 bjh21 Exp $ */
/* $NetBSD: irq.h,v 1.1 2002/03/24 15:47:03 bjh21 Exp $ */
/*-
* Copyright (c) 2000 Ben Harris
* All rights reserved.
@ -29,7 +29,7 @@
#ifndef _ARM26_IRQ_H
#define _ARM26_IRQ_H
#include <arch/arm26/iobus/iocreg.h>
#include <arch/acorn26/iobus/iocreg.h>
/* return values from interrupt handlers */
/* These are the same as arm32 uses */

View File

@ -0,0 +1,3 @@
/* $NetBSD: limits.h,v 1.1 2002/03/24 15:47:04 bjh21 Exp $ */
#include <arm/limits.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: loadfile_machdep.h,v 1.2 2001/10/31 17:59:38 bjh21 Exp $ */
/* $NetBSD: loadfile_machdep.h,v 1.1 2002/03/24 15:47:04 bjh21 Exp $ */
/*-
* Copyright (c) 1998, 1999 The NetBSD Foundation, Inc.

View File

@ -0,0 +1,3 @@
/* $NetBSD: lock.h,v 1.1 2002/03/24 15:47:05 bjh21 Exp $ */
#include <arm/lock.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: machdep.h,v 1.5 2001/12/21 22:56:18 bjh21 Exp $ */
/* $NetBSD: machdep.h,v 1.1 2002/03/24 15:47:05 bjh21 Exp $ */
/*-
* Copyright (c) 1998 Ben Harris
* All rights reserved.

View File

@ -0,0 +1,3 @@
/* $NetBSD: math.h,v 1.1 2002/03/24 15:47:05 bjh21 Exp $ */
#include <arm/math.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: memcreg.h,v 1.3 2001/03/28 13:04:57 bjh21 Exp $ */
/* $NetBSD: memcreg.h,v 1.1 2002/03/24 15:47:06 bjh21 Exp $ */
/*-
* Copyright (c) 1997, 1998 Ben Harris
* All rights reserved.

View File

@ -1,4 +1,4 @@
/* $NetBSD: param.h,v 1.15 2002/02/26 15:13:21 simonb Exp $ */
/* $NetBSD: param.h,v 1.1 2002/03/24 15:47:06 bjh21 Exp $ */
/*
* Copyright (c) 1994,1995 Mark Brinicombe.
@ -40,8 +40,8 @@
#include <machine/intr.h> /* XXX for spl(9) */
#endif
#define _MACHINE arm26
#define MACHINE "arm26"
#define _MACHINE acorn26
#define MACHINE "acorn26"
#define POOL_SUBPAGE 4096

View File

@ -0,0 +1,3 @@
/* $NetBSD: pcb.h,v 1.1 2002/03/24 15:47:07 bjh21 Exp $ */
#include <arm/pcb.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: pmap.h,v 1.5 2001/05/05 14:20:06 bjh21 Exp $ */
/* $NetBSD: pmap.h,v 1.1 2002/03/24 15:47:07 bjh21 Exp $ */
/*-
* Copyright (c) 1997, 1998 Ben Harris
* All rights reserved.

View File

@ -1,4 +1,4 @@
/* $NetBSD: podulebus_machdep.h,v 1.4 2001/07/04 13:58:04 bjh21 Exp $ */
/* $NetBSD: podulebus_machdep.h,v 1.1 2002/03/24 15:47:08 bjh21 Exp $ */
/*
* Copyright (c) 1995 Mark Brinicombe.

View File

@ -1,4 +1,4 @@
/* $NetBSD: proc.h,v 1.2 2001/02/17 20:07:01 bjh21 Exp $ */
/* $NetBSD: proc.h,v 1.1 2002/03/24 15:47:08 bjh21 Exp $ */
/*-
* Copyright (c) 1998 Ben Harris
* All rights reserved.

View File

@ -0,0 +1,3 @@
/* $NetBSD: profile.h,v 1.1 2002/03/24 15:47:08 bjh21 Exp $ */
#include <arm/profile.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: ptrace.h,v 1.1 2002/03/24 15:47:09 bjh21 Exp $ */
#include <arm/ptrace.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: reg.h,v 1.1 2002/03/24 15:47:09 bjh21 Exp $ */
#include <arm/reg.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: setjmp.h,v 1.1 2002/03/24 15:47:10 bjh21 Exp $ */
#include <arm/setjmp.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: signal.h,v 1.1 2002/03/24 15:47:10 bjh21 Exp $ */
#include <arm/signal.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: softintr.h,v 1.1 2000/05/09 21:56:00 bjh21 Exp $ */
/* $NetBSD: softintr.h,v 1.1 2002/03/24 15:47:10 bjh21 Exp $ */
/*-
* Copyright (c) 1999 Ben Harris
* All rights reserved.

View File

@ -0,0 +1,3 @@
/* $NetBSD: stdarg.h,v 1.1 2002/03/24 15:47:11 bjh21 Exp $ */
#include <arm/stdarg.h>

View File

@ -0,0 +1,4 @@
/* $NetBSD: sysarch.h,v 1.1 2002/03/24 15:47:11 bjh21 Exp $ */
#include <arm/sysarch.h>

View File

@ -0,0 +1,3 @@
/* $NetBSD: trap.h,v 1.1 2002/03/24 15:47:11 bjh21 Exp $ */
#include <arm/trap.h>

View File

@ -0,0 +1,10 @@
/* $NetBSD: types.h,v 1.1 2002/03/24 15:47:12 bjh21 Exp $ */
#ifndef _ACORN26_TYPES_H_
#define _ACORN26_TYPES_H_
#include <arm/arm26/types.h>
#define __HAVE_GENERIC_SOFT_INTERRUPTS
#endif /* _ACORN26_TYPES_H_ */

View File

@ -0,0 +1,3 @@
/* $NetBSD: varargs.h,v 1.1 2002/03/24 15:47:12 bjh21 Exp $ */
#include <arm/varargs.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: vmparam.h,v 1.6 2001/11/15 18:06:12 soren Exp $ */
/* $NetBSD: vmparam.h,v 1.1 2002/03/24 15:47:12 bjh21 Exp $ */
/*
* Copyright (c) 1988 The Regents of the University of California.

View File

@ -1,4 +1,4 @@
/* $NetBSD: iobus.c,v 1.5 2001/03/20 00:03:10 bjh21 Exp $ */
/* $NetBSD: iobus.c,v 1.1 2002/03/24 15:47:13 bjh21 Exp $ */
/*-
* Copyright (c) 1998 Ben Harris
* All rights reserved.
@ -32,7 +32,7 @@
#include <sys/param.h>
__RCSID("$NetBSD: iobus.c,v 1.5 2001/03/20 00:03:10 bjh21 Exp $");
__RCSID("$NetBSD: iobus.c,v 1.1 2002/03/24 15:47:13 bjh21 Exp $");
#include <sys/device.h>
#include <sys/systm.h>
@ -40,7 +40,7 @@ __RCSID("$NetBSD: iobus.c,v 1.5 2001/03/20 00:03:10 bjh21 Exp $");
#include <machine/bus.h>
#include <machine/memcreg.h>
#include <arch/arm26/iobus/iobusvar.h>
#include <arch/acorn26/iobus/iobusvar.h>
#include "locators.h"

View File

@ -1,4 +1,4 @@
/* $NetBSD: iobusvar.h,v 1.1 2000/05/09 21:56:01 bjh21 Exp $ */
/* $NetBSD: iobusvar.h,v 1.1 2002/03/24 15:47:13 bjh21 Exp $ */
/*-
* Copyright (c) 1998 Ben Harris
* All rights reserved.

View File

@ -1,4 +1,4 @@
/* $NetBSD: ioc.c,v 1.14 2001/08/25 17:59:38 bjh21 Exp $ */
/* $NetBSD: ioc.c,v 1.1 2002/03/24 15:47:13 bjh21 Exp $ */
/*-
* Copyright (c) 1998, 1999, 2000 Ben Harris
@ -33,7 +33,7 @@
#include <sys/param.h>
__RCSID("$NetBSD: ioc.c,v 1.14 2001/08/25 17:59:38 bjh21 Exp $");
__RCSID("$NetBSD: ioc.c,v 1.1 2002/03/24 15:47:13 bjh21 Exp $");
#include <sys/device.h>
#include <sys/kernel.h>
@ -45,10 +45,10 @@ __RCSID("$NetBSD: ioc.c,v 1.14 2001/08/25 17:59:38 bjh21 Exp $");
#include <machine/intr.h>
#include <machine/irq.h>
#include <arch/arm26/arm26/cpuvar.h>
#include <arch/arm26/iobus/iobusvar.h>
#include <arch/arm26/iobus/iocvar.h>
#include <arch/arm26/iobus/iocreg.h>
#include <arch/acorn26/acorn26/cpuvar.h>
#include <arch/acorn26/iobus/iobusvar.h>
#include <arch/acorn26/iobus/iocvar.h>
#include <arch/acorn26/iobus/iocreg.h>
#include "locators.h"
@ -59,17 +59,6 @@ static int ioc_print(void *aux, const char *pnp);
static int ioc_irq_clock(void *cookie);
static int ioc_irq_statclock(void *cookie);
struct ioc_softc {
struct device sc_dev;
bus_space_tag_t sc_bst;
bus_space_handle_t sc_bsh;
struct irq_handler *sc_clkirq;
struct evcnt sc_clkev;
struct irq_handler *sc_sclkirq;
struct evcnt sc_sclkev;
u_int8_t sc_ctl;
};
struct cfattach ioc_ca = {
sizeof(struct ioc_softc), ioc_match, ioc_attach
};
@ -182,43 +171,6 @@ ioc_print(void *aux, const char *pnp)
return UNCONF;
}
/*
* Control Register
*/
/*
* ioc_ctl_{read,write}
*
* Functions to manipulate the IOC control register. The bottom six
* bits of the control register map to bidirectional pins on the chip.
* The output circuits are open-drain, so a pin is made an input by
* writing '1' to it.
*/
u_int
ioc_ctl_read(struct device *self)
{
struct ioc_softc *sc = (void *)self;
return bus_space_read_1(sc->sc_bst, sc->sc_bsh, IOC_CTL);
}
void
ioc_ctl_write(struct device *self, u_int value, u_int mask)
{
struct ioc_softc *sc = (void *)self;
int s;
bus_space_tag_t bst = sc->sc_bst;
bus_space_handle_t bsh = sc->sc_bsh;
s = splhigh();
sc->sc_ctl = (sc->sc_ctl & ~mask) | (value & mask);
bus_space_barrier(bst, bsh, IOC_CTL, 1, BUS_BARRIER_WRITE);
bus_space_write_1(bst, bsh, IOC_CTL, sc->sc_ctl);
bus_space_barrier(bst, bsh, IOC_CTL, 1, BUS_BARRIER_WRITE);
splx(s);
}
/*
* Find out if an interrupt line is currently active
*/

View File

@ -1,4 +1,4 @@
/* $NetBSD: iocreg.h,v 1.2 2002/03/07 23:16:44 bjh21 Exp $ */
/* $NetBSD: iocreg.h,v 1.1 2002/03/24 15:47:13 bjh21 Exp $ */
/*
* Copyright (c) 1997 Ben Harris.

View File

@ -1,4 +1,4 @@
/* $NetBSD: iocvar.h,v 1.5 2001/08/20 23:08:11 bjh21 Exp $ */
/* $NetBSD: iocvar.h,v 1.1 2002/03/24 15:47:14 bjh21 Exp $ */
/*-
* Copyright (c) 1998, 1999 Ben Harris
* All rights reserved.
@ -51,12 +51,21 @@ struct ioc_attach_args {
int ioc_offset;
};
struct ioc_softc {
struct device sc_dev;
bus_space_tag_t sc_bst;
bus_space_handle_t sc_bsh;
struct irq_handler *sc_clkirq;
struct evcnt sc_clkev;
struct irq_handler *sc_sclkirq;
struct evcnt sc_sclkev;
u_int8_t sc_ctl;
};
extern struct device *the_ioc;
/* Public IOC functions */
extern u_int ioc_ctl_read(struct device *);
extern void ioc_ctl_write(struct device *, u_int, u_int);
extern int ioc_irq_status(int);
extern void ioc_irq_waitfor(int);
@ -72,4 +81,41 @@ extern void ioc_initclocks(struct device *);
extern void ioc_setstatclockrate(struct device *, int);
extern void ioc_microtime(struct device *, struct timeval *);
/*
* Control Register
*/
/*
* ioc_ctl_{read,write}
*
* Functions to manipulate the IOC control register. The bottom six
* bits of the control register map to bidirectional pins on the chip.
* The output circuits are open-drain, so a pin is made an input by
* writing '1' to it.
*/
static inline u_int
ioc_ctl_read(struct device *self)
{
struct ioc_softc *sc = (void *)self;
return bus_space_read_1(sc->sc_bst, sc->sc_bsh, IOC_CTL);
}
static inline void
ioc_ctl_write(struct device *self, u_int value, u_int mask)
{
struct ioc_softc *sc = (void *)self;
int s;
bus_space_tag_t bst = sc->sc_bst;
bus_space_handle_t bsh = sc->sc_bsh;
s = splhigh();
sc->sc_ctl = (sc->sc_ctl & ~mask) | (value & mask);
bus_space_barrier(bst, bsh, IOC_CTL, 1, BUS_BARRIER_WRITE);
bus_space_write_1(bst, bsh, IOC_CTL, sc->sc_ctl);
bus_space_barrier(bst, bsh, IOC_CTL, 1, BUS_BARRIER_WRITE);
splx(s);
}
#endif

View File

@ -1,4 +1,4 @@
/* $NetBSD: upc_iobus.c,v 1.7 2001/03/20 00:04:28 bjh21 Exp $ */
/* $NetBSD: upc_iobus.c,v 1.1 2002/03/24 15:47:14 bjh21 Exp $ */
/*-
* Copyright (c) 2000 Ben Harris
* All rights reserved.
@ -32,13 +32,13 @@
#include <sys/param.h>
__RCSID("$NetBSD: upc_iobus.c,v 1.7 2001/03/20 00:04:28 bjh21 Exp $");
__RCSID("$NetBSD: upc_iobus.c,v 1.1 2002/03/24 15:47:14 bjh21 Exp $");
#include <sys/device.h>
#include <arch/arm26/iobus/iobusvar.h>
#include <arch/acorn26/iobus/iobusvar.h>
#include <arch/arm26/iobus/iocreg.h>
#include <arch/acorn26/iobus/iocreg.h>
#include <machine/irq.h>
#include <dev/ic/upcreg.h>
@ -47,7 +47,7 @@ __RCSID("$NetBSD: upc_iobus.c,v 1.7 2001/03/20 00:04:28 bjh21 Exp $");
#include "ioeb.h"
#if NIOEB > 0
#include <arch/arm26/ioc/ioebvar.h>
#include <arch/acorn26/ioc/ioebvar.h>
#endif
static int upc_iobus_match(struct device *, struct cfdata *, void *);

View File

@ -1,4 +1,4 @@
/* $NetBSD: arckbd.c,v 1.17 2002/03/17 19:40:34 atatat Exp $ */
/* $NetBSD: arckbd.c,v 1.1 2002/03/24 15:47:14 bjh21 Exp $ */
/*-
* Copyright (c) 1998, 1999, 2000 Ben Harris
* All rights reserved.
@ -43,7 +43,7 @@
#include <sys/param.h>
__RCSID("$NetBSD: arckbd.c,v 1.17 2002/03/17 19:40:34 atatat Exp $");
__RCSID("$NetBSD: arckbd.c,v 1.1 2002/03/24 15:47:14 bjh21 Exp $");
#include <sys/device.h>
#include <sys/errno.h>
@ -63,10 +63,10 @@ __RCSID("$NetBSD: arckbd.c,v 1.17 2002/03/17 19:40:34 atatat Exp $");
#include <dev/wscons/wsksymdef.h>
#include <dev/wscons/wsmousevar.h>
#include <arch/arm26/iobus/iocreg.h>
#include <arch/arm26/iobus/iocvar.h>
#include <arch/arm26/ioc/arckbdreg.h>
#include <arch/arm26/ioc/arckbdvar.h>
#include <arch/acorn26/iobus/iocreg.h>
#include <arch/acorn26/iobus/iocvar.h>
#include <arch/acorn26/ioc/arckbdreg.h>
#include <arch/acorn26/ioc/arckbdvar.h>
#include "arckbd.h"
#include "locators.h"

View File

@ -1,4 +1,4 @@
/* $NetBSD: arckbdmap.c,v 1.3 2000/05/13 14:40:11 bjh21 Exp $ */
/* $NetBSD: arckbdmap.c,v 1.1 2002/03/24 15:47:15 bjh21 Exp $ */
/*-
* Copyright (c) 1998 Ben Harris
* All rights reserved.
@ -32,13 +32,13 @@
#include <sys/types.h>
__RCSID("$NetBSD: arckbdmap.c,v 1.3 2000/05/13 14:40:11 bjh21 Exp $");
__RCSID("$NetBSD: arckbdmap.c,v 1.1 2002/03/24 15:47:15 bjh21 Exp $");
#include <sys/device.h>
#include <dev/wscons/wsksymdef.h>
#include <dev/wscons/wsksymvar.h>
#include <arch/arm26/ioc/arckbdvar.h>
#include <arch/arm26/ioc/arckbdreg.h>
#include <arch/acorn26/ioc/arckbdvar.h>
#include <arch/acorn26/ioc/arckbdreg.h>
#define KC(n) (0xe000 | (n)) /* see wsksymdef.h */

View File

@ -1,4 +1,4 @@
/* $NetBSD: arckbdreg.h,v 1.1 2000/05/09 21:56:02 bjh21 Exp $ */
/* $NetBSD: arckbdreg.h,v 1.1 2002/03/24 15:47:15 bjh21 Exp $ */
/*-
* Copyright (c) 1997, 1998 Ben Harris
* All rights reserved.

View File

@ -1,4 +1,4 @@
/* $NetBSD: arckbdvar.h,v 1.1 2000/05/09 21:56:02 bjh21 Exp $ */
/* $NetBSD: arckbdvar.h,v 1.1 2002/03/24 15:47:15 bjh21 Exp $ */
/*-
* Copyright (c) 1998 Ben Harris
* All rights reserved.

View File

@ -1,4 +1,4 @@
/* $NetBSD: arcpp.c,v 1.1 2001/04/22 15:01:25 bjh21 Exp $ */
/* $NetBSD: arcpp.c,v 1.1 2002/03/24 15:47:15 bjh21 Exp $ */
/*-
* Copyright (c) 2001 Ben Harris
@ -52,7 +52,7 @@
#include <sys/param.h>
__KERNEL_RCSID(0, "$NetBSD: arcpp.c,v 1.1 2001/04/22 15:01:25 bjh21 Exp $");
__KERNEL_RCSID(0, "$NetBSD: arcpp.c,v 1.1 2002/03/24 15:47:15 bjh21 Exp $");
#include <sys/conf.h>
#include <sys/device.h>
@ -65,11 +65,11 @@ __KERNEL_RCSID(0, "$NetBSD: arcpp.c,v 1.1 2001/04/22 15:01:25 bjh21 Exp $");
#include <machine/intr.h>
#include <machine/irq.h>
#include <arch/arm26/iobus/iocvar.h>
#include <arch/arm26/ioc/arcppreg.h>
#include <arch/arm26/ioc/latchreg.h>
#include <arch/arm26/ioc/latchvar.h>
#include <arch/arm26/ioc/ioebvar.h>
#include <arch/acorn26/iobus/iocvar.h>
#include <arch/acorn26/ioc/arcppreg.h>
#include <arch/acorn26/ioc/latchreg.h>
#include <arch/acorn26/ioc/latchvar.h>
#include <arch/acorn26/ioc/ioebvar.h>
#include "ioeb.h"
@ -113,7 +113,6 @@ static int arcpp_match(struct device *, struct cfdata *, void *);
static void arcpp_attach(struct device *, struct device *, void *);
static int arcppintr(void *);
static void arcppwakeup(void *);
static int arcpppushbytes(struct arcpp_softc *);
struct cfattach arcpp_ca = {
@ -173,7 +172,7 @@ arcppopen(dev_t dev, int flag, int mode, struct proc *p)
struct arcpp_softc *sc;
bus_space_tag_t iot;
bus_space_handle_t ioh;
int error;
int error, s;
sc = device_lookup(&arcpp_cd, ARCPPUNIT(dev));
if (sc == NULL)
@ -193,6 +192,7 @@ arcppopen(dev_t dev, int flag, int mode, struct proc *p)
iot = sc->sc_iot;
ioh = sc->sc_ioh;
s = spllpt();
/* wait till ready (printer running diagnostics) */
irq_enable(sc->sc_bih);
/* XXX Is it really appropriate to time out? */
@ -211,20 +211,10 @@ arcppopen(dev_t dev, int flag, int mode, struct proc *p)
sc->sc_state = ARCPP_OPEN;
arcppwakeup(sc);
return 0;
}
static void
arcppwakeup(void *arg)
{
struct arcpp_softc *sc = arg;
int s;
s = spllpt();
arcppintr(sc);
splx(s);
return 0;
}
/*

View File

@ -1,4 +1,4 @@
/* $NetBSD: arcppreg.h,v 1.1 2001/04/22 15:01:25 bjh21 Exp $ */
/* $NetBSD: arcppreg.h,v 1.1 2002/03/24 15:47:16 bjh21 Exp $ */
/*
* This file is in the public domain.

View File

@ -1,4 +1,4 @@
/* $NetBSD: if_eca.c,v 1.11 2001/12/20 01:20:25 thorpej Exp $ */
/* $NetBSD: if_eca.c,v 1.1 2002/03/24 15:47:16 bjh21 Exp $ */
/*-
* Copyright (c) 2001 Ben Harris
@ -29,7 +29,7 @@
#include <sys/param.h>
__KERNEL_RCSID(0, "$NetBSD: if_eca.c,v 1.11 2001/12/20 01:20:25 thorpej Exp $");
__KERNEL_RCSID(0, "$NetBSD: if_eca.c,v 1.1 2002/03/24 15:47:16 bjh21 Exp $");
#include <sys/device.h>
#include <sys/malloc.h>
@ -46,10 +46,10 @@ __KERNEL_RCSID(0, "$NetBSD: if_eca.c,v 1.11 2001/12/20 01:20:25 thorpej Exp $");
#include <machine/intr.h>
#include <machine/machdep.h>
#include <arch/arm26/iobus/iocvar.h>
#include <arch/acorn26/iobus/iocvar.h>
#include <dev/ic/mc6854reg.h>
#include <arch/arm26/ioc/if_ecavar.h>
#include <arch/acorn26/ioc/if_ecavar.h>
static int eca_match(struct device *, struct cfdata *, void *);
static void eca_attach(struct device *, struct device *, void *);

Some files were not shown because too many files have changed in this diff Show More