diff options
Diffstat (limited to 'sys/arch/mac68k/include')
44 files changed, 0 insertions, 2194 deletions
diff --git a/sys/arch/mac68k/include/_types.h b/sys/arch/mac68k/include/_types.h deleted file mode 100644 index 35b1108bd5b..00000000000 --- a/sys/arch/mac68k/include/_types.h +++ /dev/null @@ -1,10 +0,0 @@ -/* $OpenBSD: _types.h,v 1.2 2011/03/23 16:54:35 pirofti Exp $ */ - -/* public domain */ - -#ifndef _MACHINE__TYPES_H_ -#define _MACHINE__TYPES_H_ - -#include <m68k/_types.h> - -#endif /* _MACHINE__TYPES_H_ */ diff --git a/sys/arch/mac68k/include/asm.h b/sys/arch/mac68k/include/asm.h deleted file mode 100644 index 95c23293bbe..00000000000 --- a/sys/arch/mac68k/include/asm.h +++ /dev/null @@ -1,9 +0,0 @@ -/* $OpenBSD: asm.h,v 1.4 2011/03/23 16:54:35 pirofti Exp $ */ -/* $NetBSD: asm.h,v 1.2 1994/10/26 08:46:25 cgd Exp $ */ - -#ifndef _MACHINE_ASM_H_ -#define _MACHINE_ASM_H_ - -#include <m68k/asm.h> - -#endif diff --git a/sys/arch/mac68k/include/atomic.h b/sys/arch/mac68k/include/atomic.h deleted file mode 100644 index c62462c7c3a..00000000000 --- a/sys/arch/mac68k/include/atomic.h +++ /dev/null @@ -1,10 +0,0 @@ -/* $OpenBSD: atomic.h,v 1.3 2011/03/23 16:54:35 pirofti Exp $ */ - -/* Public Domain */ - -#ifndef _MACHINE_ATOMIC_H_ -#define _MACHINE_ATOMIC_H_ - -#include <m68k/atomic.h> - -#endif /* _MACHINE_ATOMIC_H_ */ diff --git a/sys/arch/mac68k/include/autoconf.h b/sys/arch/mac68k/include/autoconf.h deleted file mode 100644 index 863e6ebf4fd..00000000000 --- a/sys/arch/mac68k/include/autoconf.h +++ /dev/null @@ -1,57 +0,0 @@ -/* $OpenBSD: autoconf.h,v 1.15 2011/03/23 16:54:35 pirofti Exp $ */ -/* $NetBSD: autoconf.h,v 1.5 1996/12/17 06:47:40 scottr Exp $ */ - -/* - * Copyright (c) 1994 Gordon W. Ross - * Copyright (c) 1993 Adam Glass - * 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 Adam Glass. - * 4. The name of the Author may not be used to endorse or promote products - * derived from this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY Adam Glass ``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 REGENTS OR CONTRIBUTORS 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. - */ - -#ifndef _MACHINE_AUTOCONF_H_ -#define _MACHINE_AUTOCONF_H_ - -/* - * Autoconfiguration information. - * From sun3 port--adapted for mac68k platform by Allen Briggs. - */ - -#ifdef _KERNEL -/* machdep.c */ -void mac68k_set_io_offsets(vaddr_t); -void dumpconf(void); - -/* clock.h */ - -u_long clkread(void); -void mac68k_calibrate_delay(void); -void startrtclock(void); - -#endif /* _KERNEL */ - -#endif /* _MACHINE_AUTOCONF_H_ */ diff --git a/sys/arch/mac68k/include/bus.h b/sys/arch/mac68k/include/bus.h deleted file mode 100644 index af7d89dc0dc..00000000000 --- a/sys/arch/mac68k/include/bus.h +++ /dev/null @@ -1,434 +0,0 @@ -/* $OpenBSD: bus.h,v 1.15 2011/03/23 16:54:35 pirofti Exp $ */ -/* $NetBSD: bus.h,v 1.9 1998/01/13 18:32:15 scottr Exp $ */ - -/*- - * Copyright (c) 1996, 1997, 1998 The NetBSD Foundation, Inc. - * All rights reserved. - * - * This code is derived from software contributed to The NetBSD Foundation - * by Jason R. Thorpe of the Numerical Aerospace Simulation Facility, - * NASA Ames Research Center. - * - * 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. - * - * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS - * ``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 FOUNDATION OR CONTRIBUTORS - * 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. - */ - -/* - * Copyright (C) 1997 Scott Reynolds. 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. - */ - -#ifndef _MACHINE_BUS_H_ -#define _MACHINE_BUS_H_ - -/* - * Value for the mac68k bus space tag, not to be used directly by MI code. - */ -#define MAC68K_BUS_SPACE_MEM 0 /* space is mem space */ - -/* - * Bus address and size types - */ -typedef u_long bus_addr_t; -typedef u_long bus_size_t; - -/* - * Access methods for bus resources and address space. - */ -#define BSH_T struct bus_space_handle_s -typedef int bus_space_tag_t; -typedef struct bus_space_handle_s { - u_long base; - int swapped; - - u_int8_t (*bsr1)(bus_space_tag_t, BSH_T *, bus_size_t); - u_int16_t (*bsr2)(bus_space_tag_t, BSH_T *, bus_size_t); - u_int32_t (*bsr4)(bus_space_tag_t, BSH_T *, bus_size_t); - void (*bsrm1)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int8_t *, size_t); - void (*bsrm2)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int16_t *, size_t); - void (*bsrm4)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int32_t *, size_t); - void (*bsrms2)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int16_t *, size_t); - void (*bsrms4)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int32_t *, size_t); - void (*bsrr1)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int8_t *, size_t); - void (*bsrr2)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int16_t *, size_t); - void (*bsrr4)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int32_t *, size_t); - void (*bsrrs1)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int8_t *, size_t); - void (*bsrrs2)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int16_t *, size_t); - void (*bsrrs4)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int32_t *, size_t); - void (*bsw1)(bus_space_tag_t, BSH_T *, bus_size_t, u_int8_t); - void (*bsw2)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int16_t); - void (*bsw4)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int32_t); - void (*bswm1)(bus_space_tag_t, BSH_T *, bus_size_t, - const u_int8_t *, size_t); - void (*bswm2)(bus_space_tag_t, BSH_T *, bus_size_t, - const u_int16_t *, size_t); - void (*bswm4)(bus_space_tag_t, BSH_T *, bus_size_t, - const u_int32_t *, size_t); - void (*bswms1)(bus_space_tag_t, BSH_T *, bus_size_t, - const u_int8_t *, size_t); - void (*bswms2)(bus_space_tag_t, BSH_T *, bus_size_t, - const u_int16_t *, size_t); - void (*bswms4)(bus_space_tag_t, BSH_T *, bus_size_t, - const u_int32_t *, size_t); - void (*bswr1)(bus_space_tag_t, BSH_T *, bus_size_t, - const u_int8_t *, size_t); - void (*bswr2)(bus_space_tag_t, BSH_T *, bus_size_t, - const u_int16_t *, size_t); - void (*bswr4)(bus_space_tag_t, BSH_T *, bus_size_t, - const u_int32_t *, size_t); - void (*bswrs1)(bus_space_tag_t, BSH_T *, bus_size_t, - const u_int8_t *, size_t); - void (*bswrs2)(bus_space_tag_t, BSH_T *, bus_size_t, - const u_int16_t *, size_t); - void (*bswrs4)(bus_space_tag_t, BSH_T *, bus_size_t, - const u_int32_t *, size_t); - void (*bssm1)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int8_t v, size_t); - void (*bssm2)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int16_t v, size_t); - void (*bssm4)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int32_t v, size_t); - void (*bssr1)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int8_t v, size_t); - void (*bssr2)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int16_t v, size_t); - void (*bssr4)(bus_space_tag_t, BSH_T *, bus_size_t, - u_int32_t v, size_t); -} bus_space_handle_t; -#undef BSH_T - -void mac68k_bus_space_handle_swapped(bus_space_tag_t, - bus_space_handle_t *h); - -/* - * int bus_space_map(bus_space_tag_t t, bus_addr_t addr, - * bus_size_t size, int flags, bus_space_handle_t *bshp); - * - * Map a region of bus space. - */ - -#define BUS_SPACE_MAP_CACHEABLE 0x01 -#define BUS_SPACE_MAP_LINEAR 0x02 -#define BUS_SPACE_MAP_PREFETCHABLE 0x04 - -int bus_space_map(bus_space_tag_t, bus_addr_t, bus_size_t, - int, bus_space_handle_t *); - -/* - * void bus_space_unmap(bus_space_tag_t t, - * bus_space_handle_t bsh, bus_size_t size); - * - * Unmap a region of bus space. - */ - -void bus_space_unmap(bus_space_tag_t, bus_space_handle_t, bus_size_t); - -/* - * int bus_space_subregion(bus_space_tag_t t, - * bus_space_handle_t bsh, bus_size_t offset, bus_size_t size, - * bus_space_handle_t *nbshp); - * - * Get a new handle for a subregion of an already-mapped area of bus space. - */ - -int bus_space_subregion(bus_space_tag_t t, bus_space_handle_t bsh, - bus_size_t offset, bus_size_t size, bus_space_handle_t *nbshp); - -/* - * int bus_space_alloc(bus_space_tag_t t, bus_addr_t, rstart, - * bus_addr_t rend, bus_size_t size, bus_size_t align, - * bus_size_t boundary, int flags, bus_addr_t *addrp, - * bus_space_handle_t *bshp); - * - * Allocate a region of bus space. - */ - -int bus_space_alloc(bus_space_tag_t t, bus_addr_t rstart, - bus_addr_t rend, bus_size_t size, bus_size_t align, - bus_size_t boundary, int flags, bus_addr_t *addrp, - bus_space_handle_t *bshp); - -/* - * int bus_space_free(bus_space_tag_t t, - * bus_space_handle_t bsh, bus_size_t size); - * - * Free a region of bus space. - */ - -void bus_space_free(bus_space_tag_t t, bus_space_handle_t bsh, - bus_size_t size); - -/* - * int mac68k_bus_space_probe(bus_space_tag_t t, - * bus_space_handle_t bsh, bus_size_t offset, int sz); - * - * Probe the bus at t/bsh/offset, using sz as the size of the load. - * - * This is a machine-dependent extension, and is not to be used by - * machine-independent code. - */ - -int mac68k_bus_space_probe(bus_space_tag_t t, - bus_space_handle_t bsh, bus_size_t offset, int sz); - -/* - * u_intN_t bus_space_read_N(bus_space_tag_t tag, - * bus_space_handle_t bsh, bus_size_t offset); - * - * Read a 1, 2, 4, or 8 byte quantity from bus space - * described by tag/handle/offset. - */ - -u_int8_t mac68k_bsr1(bus_space_tag_t tag, bus_space_handle_t *bsh, - bus_size_t offset); -u_int16_t mac68k_bsr2(bus_space_tag_t tag, bus_space_handle_t *bsh, - bus_size_t offset); -u_int16_t mac68k_bsr2_swap(bus_space_tag_t tag, bus_space_handle_t *bsh, - bus_size_t offset); -u_int32_t mac68k_bsr4(bus_space_tag_t tag, bus_space_handle_t *bsh, - bus_size_t offset); -u_int32_t mac68k_bsr4_swap(bus_space_tag_t tag, bus_space_handle_t *bsh, - bus_size_t offset); - -#define bus_space_read_1(t,h,o) (h).bsr1((t), &(h), (o)) -#define bus_space_read_2(t,h,o) (h).bsr2((t), &(h), (o)) -#define bus_space_read_4(t,h,o) (h).bsr4((t), &(h), (o)) - -/* - * void bus_space_read_multi_N(bus_space_tag_t tag, - * bus_space_handle_t bsh, bus_size_t offset, - * u_intN_t *addr, size_t count); - * - * Read `count' 1, 2, 4, or 8 byte quantities from bus space - * described by tag/handle/offset and copy into buffer provided. - */ - -void mac68k_bsrm1(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - u_int8_t *, size_t); -void mac68k_bsrm2(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - u_int16_t *, size_t); -void mac68k_bsrm2_swap(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - u_int16_t *, size_t); -void mac68k_bsrm4(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - u_int32_t *, size_t); -void mac68k_bsrms4(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - u_int32_t *, size_t); -void mac68k_bsrm4_swap(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - u_int32_t *, size_t); - -#define bus_space_read_multi_1(t, h, o, a, c) (h).bsrm1(t, &(h), o, a, c) -#define bus_space_read_multi_2(t, h, o, a, c) (h).bsrm2(t, &(h), o, a, c) -#define bus_space_read_multi_4(t, h, o, a, c) (h).bsrm4(t, &(h), o, a, c) - -/* - * void bus_space_read_region_N(bus_space_tag_t tag, - * bus_space_handle_t bsh, bus_size_t offset, - * u_intN_t *addr, size_t count); - * - * Read `count' 1, 2, 4, or 8 byte quantities from bus space - * described by tag/handle and starting at `offset' and copy into - * buffer provided. - */ - -void mac68k_bsrr1(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - u_int8_t *, size_t); -void mac68k_bsrr2(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - u_int16_t *, size_t); -void mac68k_bsrr2_swap(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - u_int16_t *, size_t); -void mac68k_bsrr4(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - u_int32_t *, size_t); -void mac68k_bsrr4_swap(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - u_int32_t *, size_t); - -#define bus_space_read_region_1(t, h, o, a, c) (h).bsrr1(t,&(h),o,a,c) -#define bus_space_read_region_2(t, h, o, a, c) (h).bsrr2(t,&(h),o,a,c) -#define bus_space_read_region_4(t, h, o, a, c) (h).bsrr4(t,&(h),o,a,c) - -/* - * void bus_space_write_N(bus_space_tag_t tag, - * bus_space_handle_t bsh, bus_size_t offset, - * u_intN_t value); - * - * Write the 1, 2, 4, or 8 byte value `value' to bus space - * described by tag/handle/offset. - */ - -void mac68k_bsw1(bus_space_tag_t, bus_space_handle_t *, bus_size_t, u_int8_t); -void mac68k_bsw2(bus_space_tag_t, bus_space_handle_t *, bus_size_t, u_int16_t); -void mac68k_bsw2_swap(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - u_int16_t); -void mac68k_bsw4(bus_space_tag_t, bus_space_handle_t *, bus_size_t, u_int32_t); -void mac68k_bsw4_swap(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - u_int32_t); - -#define bus_space_write_1(t, h, o, v) (h).bsw1(t, &(h), o, v) -#define bus_space_write_2(t, h, o, v) (h).bsw2(t, &(h), o, v) -#define bus_space_write_4(t, h, o, v) (h).bsw4(t, &(h), o, v) - -/* - * void bus_space_write_multi_N(bus_space_tag_t tag, - * bus_space_handle_t bsh, bus_size_t offset, - * const u_intN_t *addr, size_t count); - * - * Write `count' 1, 2, 4, or 8 byte quantities from the buffer - * provided to bus space described by tag/handle/offset. - */ - -void mac68k_bswm1(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - const u_int8_t *, size_t); -void mac68k_bswm2(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - const u_int16_t *, size_t); -void mac68k_bswm2_swap(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - const u_int16_t *, size_t); -void mac68k_bswm4(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - const u_int32_t *, size_t); -void mac68k_bswm4_swap(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - const u_int32_t *, size_t); - -#define bus_space_write_multi_1(t, h, o, a, c) (h).bswm1(t, &(h), o, a, c) -#define bus_space_write_multi_2(t, h, o, a, c) (h).bswm2(t, &(h), o, a, c) -#define bus_space_write_multi_4(t, h, o, a, c) (h).bswm4(t, &(h), o, a, c) - -/* - * void bus_space_write_region_N(bus_space_tag_t tag, - * bus_space_handle_t bsh, bus_size_t offset, - * const u_intN_t *addr, size_t count); - * - * Write `count' 1, 2, 4, or 8 byte quantities from the buffer provided - * to bus space described by tag/handle starting at `offset'. - */ - -void mac68k_bswr1(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - const u_int8_t *, size_t); -void mac68k_bswr2(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - const u_int16_t *, size_t); -void mac68k_bswr2_swap(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - const u_int16_t *, size_t); -void mac68k_bswr4(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - const u_int32_t *, size_t); -void mac68k_bswr4_swap(bus_space_tag_t, bus_space_handle_t *, bus_size_t, - const u_int32_t *, size_t); - -#define bus_space_write_region_1(t, h, o, a, c) (h).bswr1(t, &(h), o, a, c) -#define bus_space_write_region_2(t, h, o, a, c) (h).bswr2(t, &(h), o, a, c) -#define bus_space_write_region_4(t, h, o, a, c) (h).bswr4(t, &(h), o, a, c) - -/* - * void bus_space_set_multi_N(bus_space_tag_t tag, - * bus_space_handle_t bsh, bus_size_t offset, u_intN_t val, - * size_t count); - * - * Write the 1, 2, 4, or 8 byte value `val' to bus space described - * by tag/handle/offset `count' times. - */ - -void mac68k_bssm1(bus_space_tag_t t, bus_space_handle_t *h, - bus_size_t o, u_int8_t v, size_t c); -void mac68k_bssm2(bus_space_tag_t t, bus_space_handle_t *h, - bus_size_t o, u_int16_t v, size_t c); -void mac68k_bssm2_swap(bus_space_tag_t t, bus_space_handle_t *h, - bus_size_t o, u_int16_t v, size_t c); -void mac68k_bssm4(bus_space_tag_t t, bus_space_handle_t *h, - bus_size_t o, u_int32_t v, size_t c); -void mac68k_bssm4_swap(bus_space_tag_t t, bus_space_handle_t *h, - bus_size_t o, u_int32_t v, size_t c); - -#define bus_space_set_multi_1(t, h, o, val, c) (h).bssm1(t, &(h), o, val, c) -#define bus_space_set_multi_2(t, h, o, val, c) (h).bssm2(t, &(h), o, val, c) -#define bus_space_set_multi_4(t, h, o, val, c) (h).bssm4(t, &(h), o, val, c) - -/* - * void bus_space_set_region_N(bus_space_tag_t tag, - * bus_space_handle_t bsh, bus_size_t offset, u_intN_t val, - * size_t count); - * - * Write `count' 1, 2, 4, or 8 byte value `val' to bus space described - * by tag/handle starting at `offset'. - */ - -void mac68k_bssr1(bus_space_tag_t t, bus_space_handle_t *h, - bus_size_t o, u_int8_t v, size_t c); -void mac68k_bssr2(bus_space_tag_t t, bus_space_handle_t *h, - bus_size_t o, u_int16_t v, size_t c); -void mac68k_bssr2_swap(bus_space_tag_t t, bus_space_handle_t *h, - bus_size_t o, u_int16_t v, size_t c); -void mac68k_bssr4(bus_space_tag_t t, bus_space_handle_t *h, - bus_size_t o, u_int32_t v, size_t c); -void mac68k_bssr4_swap(bus_space_tag_t t, bus_space_handle_t *h, - bus_size_t o, u_int32_t v, size_t c); - -#define bus_space_set_region_1(t, h, o, val, c) (h).bssr1(t, &(h), o, val, c) -#define bus_space_set_region_2(t, h, o, val, c) (h).bssr2(t, &(h), o, val, c) -#define bus_space_set_region_4(t, h, o, val, c) (h).bssr4(t, &(h), o, val, c) - -/* - * Bus read/write barrier methods. - * - * void bus_space_barrier(bus_space_tag_t tag, - * bus_space_handle_t bsh, bus_size_t offset, - * bus_size_t len, int flags); - * - * Note: the 680x0 does not currently require barriers, but we must - * provide the flags to MI code. - */ -#define bus_space_barrier(t, h, o, l, f) \ - ((void)((void)(t), (void)(h), (void)(o), (void)(l), (void)(f))) -#define BUS_SPACE_BARRIER_READ 0x01 /* force read barrier */ -#define BUS_SPACE_BARRIER_WRITE 0x02 /* force write barrier */ - -#define bus_space_vaddr(t, h) (void *)((h).base) - -#endif /* _MACHINE_BUS_H_ */ diff --git a/sys/arch/mac68k/include/cdefs.h b/sys/arch/mac68k/include/cdefs.h deleted file mode 100644 index 5c9b2fcc416..00000000000 --- a/sys/arch/mac68k/include/cdefs.h +++ /dev/null @@ -1,3 +0,0 @@ -/* $OpenBSD: cdefs.h,v 1.6 2011/03/23 16:54:36 pirofti Exp $ */ -/* public domain */ -#include <m68k/cdefs.h> diff --git a/sys/arch/mac68k/include/cpu.h b/sys/arch/mac68k/include/cpu.h deleted file mode 100644 index ccb64ea8219..00000000000 --- a/sys/arch/mac68k/include/cpu.h +++ /dev/null @@ -1,280 +0,0 @@ -/* $OpenBSD: cpu.h,v 1.50 2011/11/01 21:20:55 miod Exp $ */ -/* $NetBSD: cpu.h,v 1.45 1997/02/10 22:13:40 scottr Exp $ */ - -/* - * Copyright (c) 1988 University of Utah. - * Copyright (c) 1982, 1990 The Regents of the University of California. - * All rights reserved. - * - * This code is derived from software contributed to Berkeley by - * the Systems Programming Group of the University of Utah Computer - * Science Department. - * - * 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. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. - */ - -/* - * Copyright (c) 1992, 1993 BCDL Labs. All rights reserved. - * Allen Briggs, Chris Caputo, Michael Finch, Brad Grantham, Lawrence Kesteloot - - * Redistribution of this source code or any part thereof is permitted, - * provided that the following conditions are met: - * 1) Utilized source contains the copyright message above, this list - * of conditions, and the following disclaimer. - * 2) Binary objects containing compiled source reproduce the - * copyright notice above on startup. - * - * CAVEAT: This source code is provided "as-is" by BCDL Labs, and any - * warranties of ANY kind are disclaimed. We don't even claim that it - * won't crash your hard disk. Basically, we want a little credit if - * it works, but we don't want to get mail-bombed if it doesn't. - */ - -/* - * from: Utah $Hdr: cpu.h 1.16 91/03/25$ - * - * @(#)cpu.h 7.7 (Berkeley) 6/27/91 - */ - -#ifndef _CPU_MACHINE_ -#define _CPU_MACHINE_ - -/* - * Exported definitions unique to mac68k/68k cpu support. - */ - -/* - * Get common m68k definitions. - */ -#include <m68k/cpu.h> - -#ifdef _KERNEL - -/* - * Get interrupt glue. - */ -#include <machine/intr.h> - -/* - * Arguments to hardclock and gatherstats encapsulate the previous - * machine state in an opaque clockframe. On the m68k, we use - * what the hardware pushes on an interrupt (frame format 0). - */ -struct clockframe { - u_short sr; /* sr at time of interrupt */ - u_long pc; /* pc at time of interrupt */ - u_short vo; /* vector offset (4-word frame) */ -}; - -#define CLKF_USERMODE(framep) (((framep)->sr & PSL_S) == 0) -#define CLKF_PC(framep) ((framep)->pc) -#define CLKF_INTR(framep) (0) /* XXX should use PSL_M (see hp300) */ - -/* - * Preempt the current process if in interrupt from user mode, - * or after the current trap/syscall if in system mode. - */ -extern int want_resched; /* resched() was called */ -#define need_resched(ci) { want_resched = 1; aston(); } -#define clear_resched(ci) want_resched = 0 - -/* - * Give a profiling tick to the current process from the softclock - * interrupt. Request an ast to send us through trap(), - * marking the proc as needing a profiling tick. - */ -#define need_proftick(p) aston() - -/* - * Notify the current process (p) that it has a signal pending, - * process as soon as possible. - */ -#define signotify(p) aston() - -extern int astpending; /* need to trap before returning to user mode */ -#define aston() (astpending = 1) - -#endif /* _KERNEL */ - -#define CPU_CONSDEV 1 -#define CPU_MAXID 2 - -#define CTL_MACHDEP_NAMES { \ - { 0, 0 }, \ - { "console_device", CTLTYPE_STRUCT }, \ -} - -#ifdef _KERNEL - -/* values for machineid -- - * These are equivalent to the MacOS Gestalt values. */ -#define MACH_MACII 6 -#define MACH_MACIIX 7 -#define MACH_MACIICX 8 -#define MACH_MACSE30 9 -#define MACH_MACIICI 11 -#define MACH_MACIIFX 13 -#define MACH_MACIISI 18 -#define MACH_MACQ900 20 -#define MACH_MACPB170 21 -#define MACH_MACQ700 22 -#define MACH_MACCLASSICII 23 -#define MACH_MACPB100 24 -#define MACH_MACPB140 25 -#define MACH_MACQ950 26 -#define MACH_MACLCIII 27 -#define MACH_MACPB210 29 -#define MACH_MACC650 30 -#define MACH_MACPB230 32 -#define MACH_MACPB180 33 -#define MACH_MACPB160 34 -#define MACH_MACQ800 35 -#define MACH_MACQ650 36 -#define MACH_MACLCII 37 -#define MACH_MACPB250 38 -#define MACH_MACIIVI 44 -#define MACH_MACP600 45 -#define MACH_MACIIVX 48 -#define MACH_MACCCLASSIC 49 -#define MACH_MACPB165C 50 -#define MACH_MACC610 52 -#define MACH_MACQ610 53 -#define MACH_MACPB145 54 -#define MACH_MACLC520 56 -#define MACH_MACC660AV 60 -#define MACH_MACP460 62 -#define MACH_MACPB180C 71 -#define MACH_MACPB500 72 -#define MACH_MACPB270 77 -#define MACH_MACQ840AV 78 -#define MACH_MACP550 80 -#define MACH_MACCCLASSICII 83 -#define MACH_MACPB165 84 -#define MACH_MACPB190CS 85 -#define MACH_MACTV 88 -#define MACH_MACLC475 89 -#define MACH_MACLC475_33 90 -#define MACH_MACLC575 92 -#define MACH_MACQ605 94 -#define MACH_MACQ605_33 95 -#define MACH_MACQ630 98 -#define MACH_MACP580 99 -#define MACH_MACPB280 102 -#define MACH_MACPB280C 103 -#define MACH_MACPB150 115 -#define MACH_MACPB190 122 - -/* - * Machine classes. These define subsets of the above machines. - */ -#define MACH_CLASSH 0 /* Hopeless cases... */ -#define MACH_CLASSII 1 /* MacII class */ -#define MACH_CLASSIIci 2 /* Have RBV, but no Egret */ -#define MACH_CLASSIIsi 3 /* Similar to IIci -- Have Egret. */ -#define MACH_CLASSIIvx 4 /* Similar to IIsi -- different via2 emul? */ -#define MACH_CLASSLC 5 /* Low-Cost/Performa/Wal-Mart Macs. */ -#define MACH_CLASSPB 6 /* Powerbooks. Power management. */ -#define MACH_CLASSDUO 7 /* Powerbooks Duos. More integration/Docks. */ -#define MACH_CLASSIIfx 8 /* The IIfx is in a class by itself. */ -#define MACH_CLASSQ 9 /* non-A/V Centris/Quadras. */ -#define MACH_CLASSAV 10 /* A/V Centris/Quadras. */ -#define MACH_CLASSQ2 11 /* More Centris/Quadras, different sccA. */ - -struct mac68k_machine_S { - int cpu_model_index; - /* - * Misc. info from booter. - */ - int machineid; - int mach_memsize; - int booter_version; - /* - * Debugging flags. - */ - int do_graybars; - int serial_boot_echo; - int serial_console; - - int modem_flags; - int modem_cts_clk; - int modem_dcd_clk; - int modem_d_speed; - int print_flags; - int print_cts_clk; - int print_dcd_clk; - int print_d_speed; - /* - * Misc. hardware info. - */ - int scsi80; /* Has NCR 5380 */ - int scsi96; /* Has NCR 53C96 */ - int scsi96_2; /* Has 2nd 53C96 */ - int sonic; /* Has SONIC e-net */ - - int via1_ipl; - int aux_interrupts; -}; - - /* What kind of model is this */ -struct cpu_model_info { - int machineid; /* MacOS Gestalt value. */ - const char *model; /* Model description */ - int class; /* Rough class of machine. */ -}; -extern const struct cpu_model_info *current_mac_model; - -extern unsigned long IOBase; /* Base address of I/O */ -extern unsigned long NuBusBase; /* Base address of NuBus */ - -extern struct mac68k_machine_S mac68k_machine; -extern unsigned long load_addr; - -#define IIOMAPSIZE (0x040000 / PAGE_SIZE) - -/* XXX -- Need to do something about superspace. - * Technically, NuBus superspace starts at 0x60000000, but no - * known Macintosh has used any slot lower numbered than 9, and - * the super space is defined as 0xS000 0000 through 0xSFFF FFFF - * where S is the slot number--ranging from 0x9 - 0xE. - */ -#define NBSBASE 0x90000000 -#define NBSTOP 0xF0000000 -#define NBBASE 0xF9000000 /* NUBUS space */ -#define NBTOP 0xFF000000 /* NUBUS space */ -#define NBMAPSIZE atop(NBTOP-NBBASE) /* ~ 96 megs */ -#define NBMEMSIZE 0x01000000 /* 16 megs per card */ -#define NBROMOFFSET 0x00FF0000 /* Last 64K == ROM */ - -/* locore.s */ -void PCIA(void); - -/* machdep.c */ -void mac68k_set_bell_callback(int (*)(void *, int, int, int), void *); -int mac68k_ring_bell(int, int, int); -u_int get_mapping(void); - -#endif - -#endif /* _CPU_MACHINE_ */ diff --git a/sys/arch/mac68k/include/db_machdep.h b/sys/arch/mac68k/include/db_machdep.h deleted file mode 100644 index f8188f7e258..00000000000 --- a/sys/arch/mac68k/include/db_machdep.h +++ /dev/null @@ -1,9 +0,0 @@ -/* $OpenBSD: db_machdep.h,v 1.4 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: db_machdep.h,v 1.3 1994/10/26 08:46:27 cgd Exp $ */ - -#ifndef _MACHINE_DB_MACHDEP_H_ -#define _MACHINE_DB_MACHDEP_H_ - -#include <m68k/db_machdep.h> - -#endif /* _MACHINE_DB_MACHDEP_H_ */ diff --git a/sys/arch/mac68k/include/disklabel.h b/sys/arch/mac68k/include/disklabel.h deleted file mode 100644 index 98612bee869..00000000000 --- a/sys/arch/mac68k/include/disklabel.h +++ /dev/null @@ -1,40 +0,0 @@ -/* $OpenBSD: disklabel.h,v 1.9 2011/03/23 16:54:36 pirofti Exp $ */ - -/* - * Copyright (c) 1994 Christopher G. Demetriou - * 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 Christopher G. Demetriou. - * 4. The name of the author may not be used to endorse or promote products - * derived from this software without specific prior written permission - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * 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. - */ - -#ifndef _MACHINE_DISKLABEL_H_ -#define _MACHINE_DISKLABEL_H_ - -#define LABELSECTOR 0 /* sector containing label */ -#define LABELOFFSET 64 /* offset of label in sector */ -#define MAXPARTITIONS 16 /* number of partitions */ - -#endif /* _MACHINE_DISKLABEL_H_ */ diff --git a/sys/arch/mac68k/include/endian.h b/sys/arch/mac68k/include/endian.h deleted file mode 100644 index 40e1fdac923..00000000000 --- a/sys/arch/mac68k/include/endian.h +++ /dev/null @@ -1,4 +0,0 @@ -/* $OpenBSD: endian.h,v 1.5 2011/03/15 18:23:38 deraadt Exp $ */ -/* $NetBSD: endian.h,v 1.5 1994/10/26 08:46:28 cgd Exp $ */ - -#include <m68k/endian.h> diff --git a/sys/arch/mac68k/include/exec.h b/sys/arch/mac68k/include/exec.h deleted file mode 100644 index 7e02e75ecf4..00000000000 --- a/sys/arch/mac68k/include/exec.h +++ /dev/null @@ -1,38 +0,0 @@ -/* $OpenBSD: exec.h,v 1.8 2003/10/09 21:48:48 miod Exp $ */ -/* $NetBSD: exec.h,v 1.8 1996/05/05 06:17:40 briggs Exp $ */ - -/*- - * Copyright (C) 1993 Allen K. Briggs, Chris P. Caputo, - * Michael L. Finch, Bradley A. Grantham, and - * Lawrence A. Kesteloot - * 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 the Alice Group. - * 4. The names of the Alice Group or any of its members may not be used - * to endorse or promote products derived from this software without - * specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE ALICE GROUP ``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 ALICE GROUP 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. - * - */ - -#include <m68k/exec.h> diff --git a/sys/arch/mac68k/include/fenv.h b/sys/arch/mac68k/include/fenv.h deleted file mode 100644 index f7924ba05fa..00000000000 --- a/sys/arch/mac68k/include/fenv.h +++ /dev/null @@ -1,3 +0,0 @@ -/* $OpenBSD: fenv.h,v 1.1 2011/04/28 18:05:39 martynas Exp $ */ - -#include <m68k/fenv.h> diff --git a/sys/arch/mac68k/include/float.h b/sys/arch/mac68k/include/float.h deleted file mode 100644 index 142d8258609..00000000000 --- a/sys/arch/mac68k/include/float.h +++ /dev/null @@ -1,9 +0,0 @@ -/* $OpenBSD: float.h,v 1.5 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: float.h,v 1.6 1996/05/05 06:17:44 briggs Exp $ */ - -#ifndef _MACHINE_FLOAT_H_ -#define _MACHINE_FLOAT_H_ - -#include <m68k/float.h> - -#endif /* _MACHINE_FLOAT_H_ */ diff --git a/sys/arch/mac68k/include/frame.h b/sys/arch/mac68k/include/frame.h deleted file mode 100644 index 79c680e1459..00000000000 --- a/sys/arch/mac68k/include/frame.h +++ /dev/null @@ -1,9 +0,0 @@ -/* $OpenBSD: frame.h,v 1.5 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: frame.h,v 1.5 1996/05/05 06:17:46 briggs Exp $ */ - -#ifndef _MACHINE_FRAME_H_ -#define _MACHINE_FRAME_H_ - -#include <m68k/frame.h> - -#endif /* _MACHINE_FRAME_H_ */ diff --git a/sys/arch/mac68k/include/ieee.h b/sys/arch/mac68k/include/ieee.h deleted file mode 100644 index a71abb6e62c..00000000000 --- a/sys/arch/mac68k/include/ieee.h +++ /dev/null @@ -1,3 +0,0 @@ -/* $OpenBSD: ieee.h,v 1.1 2001/09/06 00:07:10 millert Exp $ */ - -#include <m68k/ieee.h> diff --git a/sys/arch/mac68k/include/ieeefp.h b/sys/arch/mac68k/include/ieeefp.h deleted file mode 100644 index b9f71534588..00000000000 --- a/sys/arch/mac68k/include/ieeefp.h +++ /dev/null @@ -1,9 +0,0 @@ -/* $OpenBSD: ieeefp.h,v 1.4 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: ieeefp.h,v 1.2 1995/04/16 16:47:07 jtc Exp $ */ - -#ifndef _MACHINE_IEEEFP_H_ -#define _MACHINE_IEEEFP_H_ - -#include <m68k/ieeefp.h> - -#endif /* _MACHINE_IEEEFP_H_ */ diff --git a/sys/arch/mac68k/include/internal_types.h b/sys/arch/mac68k/include/internal_types.h deleted file mode 100644 index 61dd1740f08..00000000000 --- a/sys/arch/mac68k/include/internal_types.h +++ /dev/null @@ -1,3 +0,0 @@ -/* $OpenBSD: internal_types.h,v 1.1 2002/04/24 21:53:11 espie Exp $ */ -/* Public domain */ -#include <m68k/internal_types.h> diff --git a/sys/arch/mac68k/include/intr.h b/sys/arch/mac68k/include/intr.h deleted file mode 100644 index 64364f25a09..00000000000 --- a/sys/arch/mac68k/include/intr.h +++ /dev/null @@ -1,124 +0,0 @@ -/* $OpenBSD: intr.h,v 1.22 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: intr.h,v 1.9 1998/08/12 06:58:42 scottr Exp $ */ - -/* - * Copyright (C) 1997 Scott Reynolds - * 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. - */ - -#ifndef _MACHINE_INTR_H_ -#define _MACHINE_INTR_H_ - -#include <machine/psl.h> - -#ifdef _KERNEL - -/* - * splnet must block hardware network interrupts - * splvm must be > spltty - */ -extern u_short mac68k_ttyipl; -extern u_short mac68k_netipl; -extern u_short mac68k_vmipl; -extern u_short mac68k_audioipl; -extern u_short mac68k_clockipl; -extern u_short mac68k_statclockipl; - -/* - * Interrupt "levels". These are a more abstract representation - * of interrupt levels, and do not have the same meaning as m68k - * CPU interrupt levels. They serve two purposes: - * - * - properly order ISRs in the list for that CPU ipl - * - compute CPU PSL values for the spl*() calls. - */ -#define IPL_NONE 0 -#define IPL_SOFTINT 1 -#define IPL_BIO 2 -#define IPL_AUDIO PSLTOIPL(mac68k_audioipl) -#define IPL_NET PSLTOIPL(mac68k_netipl) -#define IPL_TTY PSLTOIPL(mac68k_ttyipl) -#define IPL_VM PSLTOIPL(mac68k_vmipl) -#define IPL_CLOCK PSLTOIPL(mac68k_clockipl) -#define IPL_STATCLOCK PSLTOIPL(mac68k_statclockipl) -#define IPL_SCHED 7 -#define IPL_HIGH 7 - -#define MD_IPLTOPSL(ipl) IPLTOPSL(ipl) - -/* - * These should be used for: - * 1) ensuring mutual exclusion (why use processor level?) - * 2) allowing faster devices to take priority - * - * Note that on the Mac, most things are masked at spl1, almost - * everything at spl2, and everything but the panic switch and - * power at spl4. - */ -#define splsoft() _splraise(PSL_S | PSL_IPL1) -#define splsoftclock() splsoft() -#define splsoftnet() splsoft() -#define spltty() _splraise(mac68k_ttyipl) -#define splbio() _splraise(PSL_S | PSL_IPL2) -#define splnet() _splraise(mac68k_netipl) -#define splvm() _splraise(mac68k_vmipl) -#define splaudio() _splraise(mac68k_audioipl) -#define splclock() _splraise(mac68k_clockipl) -#define splstatclock() _splraise(mac68k_statclockipl) -#define splserial() _splraise(PSL_S | PSL_IPL4) -#define splhigh() _spl(PSL_S | PSL_IPL7) -#define splsched() splhigh() - -/* These spl calls are _not_ to be used by machine-independent code. */ -#define splzs() splserial() - -/* watch out for side effects */ -#define splx(s) ((s) & PSL_IPL ? _spl(s) : spl0()) - -#include <m68k/intr.h> /* soft interrupt support */ - -/* intr.c */ -void intr_init(void); -void intr_establish(int (*)(void *), void *, int, const char *); -void intr_disestablish(int); -void intr_dispatch(int); - -/* locore.s */ -int spl0(void); - -/* - * Interrupt handler. - * There is no support for shared interrupts at the moment. - */ -#include <sys/evcount.h> -struct intrhand { - int (*ih_fn)(void *); - void *ih_arg; - int ih_ipl; - struct evcount ih_count; -}; -#endif /* _KERNEL */ - -#endif /* _MACHINE_INTR_H_ */ diff --git a/sys/arch/mac68k/include/iop.h b/sys/arch/mac68k/include/iop.h deleted file mode 100644 index 01fa00738c9..00000000000 --- a/sys/arch/mac68k/include/iop.h +++ /dev/null @@ -1,76 +0,0 @@ -/* $OpenBSD: iop.h,v 1.1 2006/01/22 13:53:16 miod Exp $ */ -/* $NetBSD: iopreg.h,v 1.7 2005/12/11 12:18:03 christos Exp $ */ - -/* - * Copyright (c) 2000 Allen Briggs. - * 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. - */ - -#define SCC_IOP 0 -#define ISM_IOP 1 - -#define IOP_CS_BYPASS 0x01 -#define IOP_CS_AUTOINC 0x02 -#define IOP_CS_RUN 0x04 -#define IOP_CS_IRQ 0x08 -#define IOP_CS_INT0 0x10 -#define IOP_CS_INT1 0x20 -#define IOP_CS_HWINT 0x40 -#define IOP_CS_DMAINACT 0x80 - -#define IOP_RESET (IOP_CS_DMAINACT | IOP_CS_AUTOINC) -#define IOP_BYPASS \ - (IOP_CS_BYPASS | IOP_CS_AUTOINC | IOP_CS_RUN | IOP_CS_DMAINACT) -#define IOP_INTERRUPT (IOP_CS_INT0 | IOP_CS_INT1) - -typedef struct { - volatile u_char ram_hi; - u_char pad0; - volatile u_char ram_lo; - u_char pad1; - volatile u_char control_status; - u_char pad2[3]; - volatile u_char data; - u_char pad3[23]; - union { - struct { - volatile u_char sccb_cmd; - u_char pad0; - volatile u_char scca_cmd; - u_char pad1; - volatile u_char sccb_data; - u_char pad2; - volatile u_char scca_data; - u_char pad3; - } scc; - struct { - volatile u_char wdata; - u_char pad0; - /* etc... */ - } iwm; - } bypass; -} IOPHW; - -void iop_serial_compatible(void); diff --git a/sys/arch/mac68k/include/kcore.h b/sys/arch/mac68k/include/kcore.h deleted file mode 100644 index d41bc4a19d3..00000000000 --- a/sys/arch/mac68k/include/kcore.h +++ /dev/null @@ -1,9 +0,0 @@ -/* $OpenBSD: kcore.h,v 1.1 1999/04/23 05:12:35 downsj Exp $ */ -/* $NetBSD: kcore.h,v 1.1 1997/04/23 19:15:16 scottr Exp $ */ - -#ifndef _MACHINE_KCORE_H_ -#define _MACHINE_KCORE_H_ - -#include <m68k/kcore.h> - -#endif diff --git a/sys/arch/mac68k/include/limits.h b/sys/arch/mac68k/include/limits.h deleted file mode 100644 index 0dd4fb31483..00000000000 --- a/sys/arch/mac68k/include/limits.h +++ /dev/null @@ -1,4 +0,0 @@ -/* $OpenBSD: limits.h,v 1.5 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: limits.h,v 1.6 1994/10/26 08:46:34 cgd Exp $ */ -/* public domain */ -#include <m68k/limits.h> diff --git a/sys/arch/mac68k/include/lock.h b/sys/arch/mac68k/include/lock.h deleted file mode 100644 index a83fd0016e1..00000000000 --- a/sys/arch/mac68k/include/lock.h +++ /dev/null @@ -1,3 +0,0 @@ -/* $OpenBSD: lock.h,v 1.1 2007/05/01 18:56:30 miod Exp $ */ -/* public domain */ -#include <m68k/lock.h> diff --git a/sys/arch/mac68k/include/mutex.h b/sys/arch/mac68k/include/mutex.h deleted file mode 100644 index f899120c22e..00000000000 --- a/sys/arch/mac68k/include/mutex.h +++ /dev/null @@ -1,3 +0,0 @@ -/* $OpenBSD: mutex.h,v 1.1 2007/02/03 20:08:50 miod Exp $ */ -/* public domain */ -#include <m68k/mutex.h> diff --git a/sys/arch/mac68k/include/param.h b/sys/arch/mac68k/include/param.h deleted file mode 100644 index 1747f5fc8ee..00000000000 --- a/sys/arch/mac68k/include/param.h +++ /dev/null @@ -1,100 +0,0 @@ -/* $OpenBSD: param.h,v 1.22 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: param.h,v 1.28 1997/03/01 06:57:45 scottr Exp $ */ - -/* - * Copyright (c) 1988 University of Utah. - * Copyright (c) 1982, 1990 The Regents of the University of California. - * All rights reserved. - * - * This code is derived from software contributed to Berkeley by - * the Systems Programming Group of the University of Utah Computer - * Science Department. - * - * 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. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. - */ -/*- - * Copyright (C) 1993 Allen K. Briggs, Chris P. Caputo, - * Michael L. Finch, Bradley A. Grantham, and - * Lawrence A. Kesteloot - * 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 the Alice Group. - * 4. The names of the Alice Group or any of its members may not be used - * to endorse or promote products derived from this software without - * specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE ALICE GROUP ``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 ALICE GROUP 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. - * - */ -/* - * from: Utah $Hdr: machparam.h 1.11 89/08/14$ - * - * @(#)param.h 7.8 (Berkeley) 6/28/91 - */ - -#ifndef _MACHINE_PARAM_H_ -#define _MACHINE_PARAM_H_ - -/* - * Machine dependent constants for Macintosh II-and-similar series. - */ -#define _MACHINE mac68k -#define MACHINE "mac68k" - -#define PAGE_SHIFT 12 - -#define KERNBASE 0x00000000 /* start of kernel virtual */ - -#define UPAGES 3 /* pages of u-area */ - -#include <m68k/param.h> - -#define MSGBUFSIZE 4096 - -#if defined(_KERNEL) && !defined(_LOCORE) -void delay(unsigned); -#define DELAY(ms) delay(ms) -#endif /* _KERNEL && !_LOCORE */ - -#endif /* _MACHINE_PARAM_H_ */ diff --git a/sys/arch/mac68k/include/pcb.h b/sys/arch/mac68k/include/pcb.h deleted file mode 100644 index 4c1192d3cbe..00000000000 --- a/sys/arch/mac68k/include/pcb.h +++ /dev/null @@ -1,76 +0,0 @@ -/* $OpenBSD: pcb.h,v 1.7 2003/10/09 21:48:48 miod Exp $ */ -/* $NetBSD: pcb.h,v 1.7 1996/05/05 06:17:51 briggs Exp $ */ - -/* - * Copyright (c) 1988 University of Utah. - * Copyright (c) 1982, 1990 The Regents of the University of California. - * All rights reserved. - * - * This code is derived from software contributed to Berkeley by - * the Systems Programming Group of the University of Utah Computer - * Science Department. - * - * 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. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. - */ -/*- - * Copyright (C) 1993 Allen K. Briggs, Chris P. Caputo, - * Michael L. Finch, Bradley A. Grantham, and - * Lawrence A. Kesteloot - * 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 the Alice Group. - * 4. The names of the Alice Group or any of its members may not be used - * to endorse or promote products derived from this software without - * specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE ALICE GROUP ``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 ALICE GROUP 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. - * - */ -/* - * from: Utah $Hdr: pcb.h 1.13 89/04/23$ - * - * @(#)pcb.h 7.4 (Berkeley) 5/4/91 - */ - -#include <m68k/pcb.h> diff --git a/sys/arch/mac68k/include/pmap.h b/sys/arch/mac68k/include/pmap.h deleted file mode 100644 index ad7cd3d90ea..00000000000 --- a/sys/arch/mac68k/include/pmap.h +++ /dev/null @@ -1,13 +0,0 @@ -/* $OpenBSD: pmap.h,v 1.20 2011/03/23 16:54:36 pirofti Exp $ */ - -#ifndef _MACHINE_PMAP_H_ -#define _MACHINE_PMAP_H_ - -#include <m68k/pmap_motorola.h> - -#ifdef _KERNEL -void pmap_init_md(void); -#define PMAP_INIT_MD() pmap_init_md() -#endif /* _KERNEL */ - -#endif /* _MACHINE_PMAP_H_ */ diff --git a/sys/arch/mac68k/include/proc.h b/sys/arch/mac68k/include/proc.h deleted file mode 100644 index 19d35bfe80e..00000000000 --- a/sys/arch/mac68k/include/proc.h +++ /dev/null @@ -1,35 +0,0 @@ -/* $OpenBSD: proc.h,v 1.7 2003/10/09 21:48:48 miod Exp $ */ -/* $NetBSD: proc.h,v 1.5 1994/10/26 08:46:40 cgd Exp $ */ - -/* - * Copyright (c) 1991 Regents of the University of California. - * 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. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. - * - * @(#)proc.h 7.1 (Berkeley) 5/15/91 - */ - -#include <m68k/proc.h> diff --git a/sys/arch/mac68k/include/profile.h b/sys/arch/mac68k/include/profile.h deleted file mode 100644 index d8f8974df40..00000000000 --- a/sys/arch/mac68k/include/profile.h +++ /dev/null @@ -1,9 +0,0 @@ -/* $OpenBSD: profile.h,v 1.5 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: profile.h,v 1.3 1996/05/05 06:17:55 briggs Exp $ */ - -#ifndef _MACHINE_PROFILE_H_ -#define _MACHINE_PROFILE_H_ - -#include <m68k/profile.h> - -#endif diff --git a/sys/arch/mac68k/include/psc.h b/sys/arch/mac68k/include/psc.h deleted file mode 100644 index 999e30b6c41..00000000000 --- a/sys/arch/mac68k/include/psc.h +++ /dev/null @@ -1,126 +0,0 @@ -/* $OpenBSD: psc.h,v 1.5 2004/12/14 14:50:55 martin Exp $ */ -/* $NetBSD: psc.h,v 1.5 2004/03/26 12:15:46 wiz Exp $ */ - -/*- - * Copyright (c) 1997 David Huang <khym@azeotrope.org> - * 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. 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. - * - */ - -/* - * Some register definitions for the PSC, present only on the - * Centris/Quadra 660av and the Quadra 840av. - */ - -extern volatile u_int8_t *PSCBase; - -#define psc_reg1(r) (*((volatile u_int8_t *)(PSCBase+r))) -#define psc_reg2(r) (*((volatile u_int16_t *)(PSCBase+r))) -#define psc_reg4(r) (*((volatile u_int32_t *)(PSCBase+r))) - -void psc_init(void); - -int add_psc_lev3_intr(void (*)(void *), void *); -int add_psc_lev4_intr(int, int (*)(void *), void *); -int add_psc_lev5_intr(int, void (*)(void *), void *); -int add_psc_lev6_intr(int, void (*)(void *), void *); - -int remove_psc_lev3_intr(void); -int remove_psc_lev4_intr(int); -int remove_psc_lev5_intr(int); -int remove_psc_lev6_intr(int); - -/* - * Reading an interrupt status register returns a mask of the - * currently interrupting devices (one bit per device). Reading an - * interrupt enable register returns a mask of the currently enabled - * devices. Writing an interrupt enable register with the MSB set - * enables the interrupts in the lower 4 bits, while writing with the - * MSB clear disables the corresponding interrupts. - * e.g. write 0x81 to enable device 0, write 0x86 to enable devices 1 - * and 2, write 0x02 to disable device 1. - * - * Level 3 device 0 is MACE - * Level 4 device 0 is 3210 DSP? - * Level 4 device 1 is SCC channel A (modem port) - * Level 4 device 2 is SCC channel B (printer port) - * Level 4 device 3 is MACE DMA completion - * Level 5 device 0 is 3210 DSP? - * Level 5 device 1 is 3210 DSP? - * Level 6 device 0 is ? - * Level 6 device 1 is ? - * Level 6 device 2 is ? - */ - -/* PSC interrupt registers */ -#define PSC_ISR_BASE 0x100 /* ISR is BASE + 0x10 * level */ -#define PSC_IER_BASE 0x104 /* IER is BASE + 0x10 * level */ - -#define PSC_LEV3_ISR 0x130 /* level 3 interrupt status register */ -#define PSC_LEV3_IER 0x134 /* level 3 interrupt enable register */ -#define PSCINTR_ENET 0 /* Ethernet interrupt */ - -#define PSC_LEV4_ISR 0x140 /* level 4 interrupt status register */ -#define PSC_LEV4_IER 0x144 /* level 4 interrupt enable register */ -#define PSCINTR_SCCA 1 /* SCC channel A interrupt */ -#define PSCINTR_SCCB 2 /* SCC channel B interrupt */ -#define PSCINTR_ENET_DMA 3 /* Ethernet DMA completion interrupt */ - -#define PSC_LEV5_ISR 0x150 /* level 5 interrupt status register */ -#define PSC_LEV5_IER 0x154 /* level 5 interrupt enable register */ - -#define PSC_LEV6_ISR 0x160 /* level 6 interrupt status register */ -#define PSC_LEV6_IER 0x164 /* level 6 interrupt enable register */ - -/* PSC DMA channel control registers */ -#define PSC_CTLBASE 0xc00 - -#define PSC_SCSI_CTL 0xc00 /* SCSI control/status */ -#define PSC_ENETRD_CTL 0xc10 /* MACE receive DMA channel control/status */ -#define PSC_ENETWR_CTL 0xc20 /* MACE transmit DMA channel control/status */ -#define PSC_FDC_CTL 0xc30 /* Floppy disk */ -#define PSC_SCCA_CTL 0xc40 /* SCC channel A */ -#define PSC_SCCB_CTL 0xc50 /* SCC channel B */ -#define PSC_SCCATX_CTL 0xc60 /* SCC channel A transmit */ - -/* PSC DMA channels */ -#define PSC_ADDRBASE 0x1000 -#define PSC_LENBASE 0x1004 -#define PSC_CMDBASE 0x1008 - -#define PSC_SCSI_ADDR 0x1000 /* SCSI DMA address register */ -#define PSC_SCSI_LEN 0x1004 /* SCSI DMA buffer count */ -#define PSC_SCSI_CMD 0x1008 /* SCSI DMA command register */ -#define PSC_ENETRD_ADDR 0x1020 /* MACE receive DMA address register */ -#define PSC_ENETRD_LEN 0x1024 /* MACE receive DMA buffer count */ -#define PSC_ENETRD_CMD 0x1028 /* MACE receive DMA command register */ -#define PSC_ENETWR_ADDR 0x1040 /* MACE transmit DMA address register */ -#define PSC_ENETWR_LEN 0x1044 /* MACE transmit DMA length */ -#define PSC_ENETWR_CMD 0x1048 /* MACE transmit DMA command register */ - -/* - * PSC DMA channels are controlled by two sets of registers (see p.29 - * of the Quadra 840av and Centris 660av Developer Note). Add the - * following offsets to get the desired register set. - */ -#define PSC_SET0 0x00 -#define PSC_SET1 0x10 diff --git a/sys/arch/mac68k/include/psl.h b/sys/arch/mac68k/include/psl.h deleted file mode 100644 index e272a8e0e2f..00000000000 --- a/sys/arch/mac68k/include/psl.h +++ /dev/null @@ -1,4 +0,0 @@ -/* $OpenBSD: psl.h,v 1.6 1998/05/03 07:10:48 gene Exp $ */ -/* $NetBSD: psl.h,v 1.11 1996/06/21 21:51:15 briggs Exp $ */ - -#include <m68k/psl.h> diff --git a/sys/arch/mac68k/include/pte.h b/sys/arch/mac68k/include/pte.h deleted file mode 100644 index 1689e29b9f1..00000000000 --- a/sys/arch/mac68k/include/pte.h +++ /dev/null @@ -1,14 +0,0 @@ -/* $OpenBSD: pte.h,v 1.7 2002/01/10 22:25:40 miod Exp $ */ - -#ifndef _MACHINE_PTE_H_ -#define _MACHINE_PTE_H_ - -#include <m68k/pte_motorola.h> - -#define MACHINE_STSIZE M68K_STSIZE -#define MACHINE_MAX_PTSIZE M68K_MAX_PTSIZE -#define MACHINE_MAX_KPTSIZE M68K_MAX_KPTSIZE -#define MACHINE_PTBASE M68K_PTBASE -#define MACHINE_PTMAXSIZE M68K_PTMAXSIZE - -#endif /* _MACHINE_PTE_H_ */ diff --git a/sys/arch/mac68k/include/ptrace.h b/sys/arch/mac68k/include/ptrace.h deleted file mode 100644 index 17a3905e7f5..00000000000 --- a/sys/arch/mac68k/include/ptrace.h +++ /dev/null @@ -1,9 +0,0 @@ -/* $OpenBSD: ptrace.h,v 1.4 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: ptrace.h,v 1.2 1994/10/26 08:46:43 cgd Exp $ */ - -#ifndef _MACHINE_PTRACE_H_ -#define _MACHINE_PTRACE_H_ - -#include <m68k/ptrace.h> - -#endif diff --git a/sys/arch/mac68k/include/reg.h b/sys/arch/mac68k/include/reg.h deleted file mode 100644 index 68d9dbd8fa1..00000000000 --- a/sys/arch/mac68k/include/reg.h +++ /dev/null @@ -1,10 +0,0 @@ -/* $OpenBSD: reg.h,v 1.6 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: reg.h,v 1.10 1996/05/05 06:18:00 briggs Exp $ */ - -#ifndef _MACHINE_REG_H_ -#define _MACHINE_REG_H_ - -#include <machine/frame.h> -#include <m68k/reg.h> - -#endif /* _MACHINE_REG_H_ */ diff --git a/sys/arch/mac68k/include/scsi_5380.h b/sys/arch/mac68k/include/scsi_5380.h deleted file mode 100644 index dd52f93069f..00000000000 --- a/sys/arch/mac68k/include/scsi_5380.h +++ /dev/null @@ -1,147 +0,0 @@ -/* $OpenBSD: scsi_5380.h,v 1.4 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: scsi_5380.h,v 1.3 1994/10/26 08:46:46 cgd Exp $ */ - -/* - * Mach Operating System - * Copyright (c) 1991,1990,1989 Carnegie Mellon University - * All Rights Reserved. - * - * Permission to use, copy, modify and distribute this software and its - * documentation is hereby granted, provided that both the copyright - * notice and this permission notice appear in all copies of the - * software, derivative works or modified versions, and any portions - * thereof, and that both notices appear in supporting documentation. - * - * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS - * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR - * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE. - * - * Carnegie Mellon requests users of this software to return to - * - * Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU - * School of Computer Science - * Carnegie Mellon University - * Pittsburgh PA 15213-3890 - * - * any improvements or extensions that they make and grant Carnegie the - * rights to redistribute these changes. - */ -/* - * File: scsi_5380.h - * Author: Alessandro Forin, Carnegie Mellon University - * Date: 5/91 - * - * Defines for the NCR 5380 (SCSI chip), aka Am5380 - */ - -#ifndef _MACHINE_SCSI_5380_H_ -#define _MACHINE_SCSI_5380_H_ - -/* - * Register map - */ - -typedef struct { - volatile unsigned char sci_data; /* r: Current data */ -#define sci_odata sci_data /* w: Out data */ - PAD(pad0); - - volatile unsigned char sci_icmd; /* rw: Initiator command */ - PAD(pad1); - - volatile unsigned char sci_mode; /* rw: Mode */ - PAD(pad2); - - volatile unsigned char sci_tcmd; /* rw: Target command */ - PAD(pad3); - - volatile unsigned char sci_bus_csr; /* r: Bus Status */ -#define sci_sel_enb sci_bus_csr /* w: Select enable */ - PAD(pad4); - - volatile unsigned char sci_csr; /* r: Status */ -#define sci_dma_send sci_csr /* w: Start dma send data */ - PAD(pad5); - - volatile unsigned char sci_idata; /* r: Input data */ -#define sci_trecv sci_idata /* w: Start dma receive, target */ - PAD(pad6); - - volatile unsigned char sci_iack; /* r: Interrupt Acknowledge */ -#define sci_irecv sci_iack /* w: Start dma receive, initiator */ -} sci_regmap_t; - - -/* - * Initiator command register - */ - -#define SCI_ICMD_DATA 0x01 /* rw: Assert data bus */ -#define SCI_ICMD_ATN 0x02 /* rw: Assert ATN signal */ -#define SCI_ICMD_SEL 0x04 /* rw: Assert SEL signal */ -#define SCI_ICMD_BSY 0x08 /* rw: Assert BSY signal */ -#define SCI_ICMD_ACK 0x10 /* rw: Assert ACK signal */ -#define SCI_ICMD_LST 0x20 /* r: Lost arbitration */ -#define SCI_ICMD_DIFF SCI_ICMD_LST /* w: Differential cable */ -#define SCI_ICMD_AIP 0x40 /* r: Arbitration in progress */ -#define SCI_ICMD_TEST SCI_ICMD_AIP /* w: Test mode */ -#define SCI_ICMD_RST 0x80 /* rw: Assert RST signal */ - - -/* - * Mode register - */ - -#define SCI_MODE_ARB 0x01 /* rw: Start arbitration */ -#define SCI_MODE_DMA 0x02 /* rw: Enable DMA xfers */ -#define SCI_MODE_MONBSY 0x04 /* rw: Monitor BSY signal */ -#define SCI_MODE_DMA_IE 0x08 /* rw: Enable DMA complete interrupt */ -#define SCI_MODE_PERR_IE 0x10 /* rw: Interrupt on parity errors */ -#define SCI_MODE_PAR_CHK 0x20 /* rw: Check parity */ -#define SCI_MODE_TARGET 0x40 /* rw: Target mode (Initiator if 0) */ -#define SCI_MODE_BLOCKDMA 0x80 /* rw: Block-mode DMA handshake (MBZ) */ - - -/* - * Target command register - */ - -#define SCI_TCMD_IO 0x01 /* rw: Assert I/O signal */ -#define SCI_TCMD_CD 0x02 /* rw: Assert C/D signal */ -#define SCI_TCMD_MSG 0x04 /* rw: Assert MSG signal */ -#define SCI_TCMD_PHASE_MASK 0x07 /* r: Mask for current bus phase */ -#define SCI_TCMD_REQ 0x08 /* rw: Assert REQ signal */ -#define SCI_TCMD_LAST_SENT 0x80 /* ro: Last byte was xferred - * (not on 5380/1) */ - -#define SCI_PHASE(x) SCSI_PHASE(x) - -/* - * Current (SCSI) Bus status - */ - -#define SCI_BUS_DBP 0x01 /* r: Data Bus parity */ -#define SCI_BUS_SEL 0x02 /* r: SEL signal */ -#define SCI_BUS_IO 0x04 /* r: I/O signal */ -#define SCI_BUS_CD 0x08 /* r: C/D signal */ -#define SCI_BUS_MSG 0x10 /* r: MSG signal */ -#define SCI_BUS_REQ 0x20 /* r: REQ signal */ -#define SCI_BUS_BSY 0x40 /* r: BSY signal */ -#define SCI_BUS_RST 0x80 /* r: RST signal */ - -#define SCI_CUR_PHASE(x) SCSI_PHASE((x)>>2) - -/* - * Bus and Status register - */ - -#define SCI_CSR_ACK 0x01 /* r: ACK signal */ -#define SCI_CSR_ATN 0x02 /* r: ATN signal */ -#define SCI_CSR_DISC 0x04 /* r: Disconnected (BSY==0) */ -#define SCI_CSR_PHASE_MATCH 0x08 /* r: Bus and SCI_TCMD match */ -#define SCI_CSR_INT 0x10 /* r: Interrupt request */ -#define SCI_CSR_PERR 0x20 /* r: Parity error */ -#define SCI_CSR_DREQ 0x40 /* r: DMA request */ -#define SCI_CSR_DONE 0x80 /* r: DMA count is zero */ - -#endif /* _MACHINE_SCSI_5380_H_ */ diff --git a/sys/arch/mac68k/include/setjmp.h b/sys/arch/mac68k/include/setjmp.h deleted file mode 100644 index d3ee5255fdf..00000000000 --- a/sys/arch/mac68k/include/setjmp.h +++ /dev/null @@ -1,9 +0,0 @@ -/* $OpenBSD: setjmp.h,v 1.4 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: setjmp.h,v 1.1 1994/12/20 10:36:57 cgd Exp $ */ - -#ifndef _MACHINE_SETJMP_H_ -#define _MACHINE_SETJMP_H_ - -#include <m68k/setjmp.h> - -#endif diff --git a/sys/arch/mac68k/include/signal.h b/sys/arch/mac68k/include/signal.h deleted file mode 100644 index 8236a88bbde..00000000000 --- a/sys/arch/mac68k/include/signal.h +++ /dev/null @@ -1,9 +0,0 @@ -/* $OpenBSD: signal.h,v 1.4 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: signal.h,v 1.3 1994/10/26 08:46:47 cgd Exp $ */ - -#ifndef _MACHINE_SIGNAL_H_ -#define _MACHINE_SIGNAL_H_ - -#include <m68k/signal.h> - -#endif diff --git a/sys/arch/mac68k/include/spinlock.h b/sys/arch/mac68k/include/spinlock.h deleted file mode 100644 index 46634aefed3..00000000000 --- a/sys/arch/mac68k/include/spinlock.h +++ /dev/null @@ -1,3 +0,0 @@ -/* $OpenBSD: spinlock.h,v 1.1 1999/01/21 02:59:34 millert Exp $ */ - -#include <m68k/spinlock.h> diff --git a/sys/arch/mac68k/include/stdarg.h b/sys/arch/mac68k/include/stdarg.h deleted file mode 100644 index d6ca78ac8dc..00000000000 --- a/sys/arch/mac68k/include/stdarg.h +++ /dev/null @@ -1,9 +0,0 @@ -/* $OpenBSD: stdarg.h,v 1.4 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: stdarg.h,v 1.5 1994/10/26 08:46:48 cgd Exp $ */ - -#ifndef _MACHINE_STDARG_H_ -#define _MACHINE_STDARG_H_ - -#include <m68k/stdarg.h> - -#endif diff --git a/sys/arch/mac68k/include/tcb.h b/sys/arch/mac68k/include/tcb.h deleted file mode 100644 index 34ed3c65c1d..00000000000 --- a/sys/arch/mac68k/include/tcb.h +++ /dev/null @@ -1,3 +0,0 @@ -/* $OpenBSD: tcb.h,v 1.1 2011/10/27 04:01:17 guenther Exp $ */ - -#include <m68k/tcb.h> diff --git a/sys/arch/mac68k/include/trap.h b/sys/arch/mac68k/include/trap.h deleted file mode 100644 index 74e07d224b7..00000000000 --- a/sys/arch/mac68k/include/trap.h +++ /dev/null @@ -1,9 +0,0 @@ -/* $OpenBSD: trap.h,v 1.4 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: trap.h,v 1.5 1994/10/26 08:46:49 cgd Exp $ */ - -#ifndef _MACHINE_TRAP_H_ -#define _MACHINE_TRAP_H_ - -#include <m68k/trap.h> - -#endif diff --git a/sys/arch/mac68k/include/varargs.h b/sys/arch/mac68k/include/varargs.h deleted file mode 100644 index 1e90c548efc..00000000000 --- a/sys/arch/mac68k/include/varargs.h +++ /dev/null @@ -1,9 +0,0 @@ -/* $OpenBSD: varargs.h,v 1.4 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: varargs.h,v 1.2 1994/10/26 08:46:51 cgd Exp $ */ - -#ifndef _MACHINE_VARARGS_H_ -#define _MACHINE_VARARGS_H_ - -#include <m68k/varargs.h> - -#endif diff --git a/sys/arch/mac68k/include/viareg.h b/sys/arch/mac68k/include/viareg.h deleted file mode 100644 index 52ad5f10686..00000000000 --- a/sys/arch/mac68k/include/viareg.h +++ /dev/null @@ -1,222 +0,0 @@ -/* $OpenBSD: viareg.h,v 1.20 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: viareg.h,v 1.6 1997/02/28 07:41:41 scottr Exp $ */ - -/*- - * Copyright (C) 1993 Allen K. Briggs, Chris P. Caputo, - * Michael L. Finch, Bradley A. Grantham, and - * Lawrence A. Kesteloot - * 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 the Alice Group. - * 4. The names of the Alice Group or any of its members may not be used - * to endorse or promote products derived from this software without - * specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE ALICE GROUP ``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 ALICE GROUP 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. - * - */ - -/* - * Prototype VIA control definitions - */ -#ifndef _MACHINE_VIAREG_H_ -#define _MACHINE_VIAREG_H_ - -/* VIA1 data register A */ -#define DA1I_vSCCWrReq 0x80 -#define DA1O_vPage2 0x40 -#define DA1I_CPU_ID1 0x40 -#define DA1O_vHeadSel 0x20 -#define DA1O_vOverlay 0x10 -#define DA1O_vSync 0x08 -#define DA1O_RESERVED2 0x04 -#define DA1O_RESERVED1 0x02 -#define DA1O_RESERVED0 0x01 - -/* VIA1 data register B */ -#define DB1I_Par_Err 0x80 -#define DB1O_vSndEnb 0x80 -#define DB1O_Par_Enb 0x40 -#define DB1O_AuxIntEnb 0x40 /* 0 = enabled, 1 = disabled */ -#define DB1O_vFDesk2 0x20 -#define DB1O_vFDesk1 0x10 -#define DB1I_vFDBInt 0x08 -#define DB1O_rTCEnb 0x04 -#define DB1O_rTCCLK 0x02 -#define DB1O_rTCData 0x01 -#define DB1I_rTCData 0x01 - -/* VIA2 data register A */ -#define DA2O_v2Ram1 0x80 -#define DA2O_v2Ram0 0x40 -#define DA2I_v2IRQ0 0x40 -#define DA2I_v2IRQE 0x20 -#define DA2I_v2IRQD 0x10 -#define DA2I_v2IRQC 0x08 -#define DA2I_v2IRQB 0x04 -#define DA2I_v2IRQA 0x02 -#define DA2I_v2IRQ9 0x01 - -/* VIA2 data register B */ -#define DB2O_v2VBL 0x80 -#define DB2O_Par_Test 0x80 -#define DB2I_v2SNDEXT 0x40 -#define DB2I_v2TM0A 0x20 -#define DB2I_v2TM1A 0x10 -#define DB2I_vFC3 0x08 -#define DB2O_vFC3 0x08 -#define DB2O_v2PowerOff 0x04 -#define DB2O_v2BusLk 0x02 -#define DB2O_vCDis 0x01 -#define DB2O_CEnable 0x01 - -/* - * VIA1 interrupts - */ -#define VIA1_T1 6 -#define VIA1_T2 5 -#define VIA1_ADBCLK 4 -#define VIA1_ADBDATA 3 -#define VIA1_ADBRDY 2 -#define VIA1_VBLNK 1 -#define VIA1_ONESEC 0 - -/* VIA1 interrupt bits */ -#define V1IF_IRQ 0x80 -#define V1IF_T1 (1 << VIA1_T1) -#define V1IF_T2 (1 << VIA1_T2) -#define V1IF_ADBCLK (1 << VIA1_ADBCLK) -#define V1IF_ADBDATA (1 << VIA1_ADBDATA) -#define V1IF_ADBRDY (1 << VIA1_ADBRDY) -#define V1IF_VBLNK (1 << VIA1_VBLNK) -#define V1IF_ONESEC (1 << VIA1_ONESEC) - -/* - * VIA2 interrupts - */ -#define VIA2_T1 6 -#define VIA2_T2 5 -#define VIA2_ASC 4 -#define VIA2_SCSIIRQ 3 -#define VIA2_EXPIRQ 2 -#define VIA2_SLOTINT 1 -#define VIA2_SCSIDRQ 0 - -/* VIA2 interrupt bits */ -#define V2IF_IRQ 0x80 -#define V2IF_T1 (1 << VIA2_T1) -#define V2IF_T2 (1 << VIA2_T2) -#define V2IF_ASC (1 << VIA2_ASC) -#define V2IF_SCSIIRQ (1 << VIA2_SCSIIRQ) -#define V2IF_EXPIRQ (1 << VIA2_EXPIRQ) -#define V2IF_SLOTINT (1 << VIA2_SLOTINT) -#define V2IF_SCSIDRQ (1 << VIA2_SCSIDRQ) - -#define VIA1_INTS (V1IF_T1 | V1IF_ADBRDY) -#define VIA2_INTS (V2IF_T1 | V2IF_ASC | V2IF_SCSIIRQ | V2IF_SLOTINT | \ - V2IF_SCSIDRQ) - -#define RBV_INTS (V2IF_T1 | V2IF_ASC | V2IF_SCSIIRQ | V2IF_SLOTINT | \ - V2IF_SCSIDRQ | V1IF_ADBRDY) - -#define ACR_T1LATCH 0x40 - -extern volatile unsigned char *Via1Base; -extern volatile unsigned char *Via2Base; /* init in VIA_Initialize */ -#define VIA1_addr Via1Base /* at PA 0x50f00000 */ - -#define VIA2OFF 1 /* VIA2 addr = VIA1_addr + 0x2000 */ -#define RBVOFF 0x13 /* RBV addr = VIA1_addr + 0x26000 */ -#define OSSOFF 0xd /* OSS addr = VIA1_addr + 0x1A000 */ - -#define VIA1 0 -extern int VIA2; - - /* VIA interface registers */ -#define vBufA 0x1e00 /* register A */ -#define vBufB 0 /* register B */ -#define vDirA 0x0600 /* data direction register */ -#define vDirB 0x0400 /* data direction register */ -#define vT1C 0x0800 -#define vT1CH 0x0a00 -#define vT1L 0x0c00 -#define vT1LH 0x0e00 -#define vT2C 0x1000 -#define vT2CH 0x1200 -#define vSR 0x1400 /* shift register */ -#define vACR 0x1600 /* aux control register */ -#define vPCR 0x1800 /* peripheral control register */ -#define vIFR 0x1a00 /* interrupt flag register */ -#define vIER 0x1c00 /* interrupt enable register */ - -/* RBV interface registers */ -#define rBufB 0 /* register B */ -#define rBufA 2 /* register A */ -#define rIFR 0x3 /* interrupt flag register (writes?) */ -#define rIER 0x13 /* interrupt enable register */ -#define rMonitor 0x10 /* Monitor type */ -#define rSlotInt 0x12 /* Slot interrupt */ - -/* RBV monitor type flags and masks */ -#define RBVDepthMask 0x07 /* Depth in bits */ -#define RBVMonitorMask 0x38 /* Type numbers */ -#define RBVOff 0x40 /* Monitor turned off */ -#define RBVMonIDBWP 0x08 /* 15 inch BW portrait */ -#define RBVMonIDRGB12 0x10 /* 12 inch color */ -#define RBVMonIDRGB15 0x28 /* 15 inch RGB */ -#define RBVMonIDStd 0x30 /* 12 inch BW or 13 inch color */ -#define RBVMonIDNone 0x38 /* No monitor connected */ - -/* OSS registers */ -#define OSS_IFR 0x202 -#define OSS_PENDING_IRQ (*(volatile u_short *)(Via2Base + (OSS_IFR))) - -#define OSS_oRCR 0x204 -#define OSS_POWEROFF 0x80 - -#define via_reg(v, r) (*(Via1Base+(v)*0x2000+(r))) -#define via2_reg(r) (*(Via2Base+(r))) - -#define vDirA_ADBState 0x30 - -#ifdef _KERNEL -/* VIA2 interrupts may be shared */ -struct via2hand { - SLIST_ENTRY(via2hand) v2h_link; - struct intrhand v2h_ih; -#define vh_fn v2h_ih.ih_fn -#define vh_arg v2h_ih.ih_arg -#define vh_ipl v2h_ih.ih_ipl -#define vh_count v2h_ih.ih_count -}; -typedef SLIST_HEAD(, via2hand) via2hand_t; - -void via_init(void); -void via_powerdown(void); -void via_set_modem(int); -void add_nubus_intr(int, int, int (*)(void *), void *, const char *); -void enable_nubus_intr(void); -void via1_register_irq(int, int (*)(void *), void *, const char *); -int via2_register_irq(struct via2hand *, const char *); -#endif /* _KERNEL */ - -#endif /* _MACHINE_VIAREG_H_ */ diff --git a/sys/arch/mac68k/include/vmparam.h b/sys/arch/mac68k/include/vmparam.h deleted file mode 100644 index ec07dcede74..00000000000 --- a/sys/arch/mac68k/include/vmparam.h +++ /dev/null @@ -1,100 +0,0 @@ -/* $OpenBSD: vmparam.h,v 1.17 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: vmparam.h,v 1.8 1996/11/15 14:21:00 briggs Exp $ */ - -/* - * Copyright (c) 1988 University of Utah. - * Copyright (c) 1982, 1990 The Regents of the University of California. - * All rights reserved. - * - * This code is derived from software contributed to Berkeley by - * the Systems Programming Group of the University of Utah Computer - * Science Department. - * - * 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. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. - */ -/*- - * Copyright (C) 1993 Allen K. Briggs, Chris P. Caputo, - * Michael L. Finch, Bradley A. Grantham, and - * Lawrence A. Kesteloot - * 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 the Alice Group. - * 4. The names of the Alice Group or any of its members may not be used - * to endorse or promote products derived from this software without - * specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE ALICE GROUP ``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 ALICE GROUP 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. - * - */ -/* - * from: Utah $Hdr: vmparam.h 1.16 91/01/18$ - * - * @(#)vmparam.h 7.3 (Berkeley) 5/7/91 - */ - -#ifndef _MACHINE_VMPARAM_H_ -#define _MACHINE_VMPARAM_H_ - -/* - * Machine dependent constants for mac68k -- mostly derived from hp300. - */ - -#include <m68k/vmparam.h> - -/* - * Constants which control the way the VM system deals with memory segments. - * Most mac68k systems have only 1 physical memory segment, but some have 2. - * - * On the systems that have multiple segments, specifically the IIsi and - * IIci, the optimal configuration is to put the higher-density SIMMs in - * bank B. This is because the on-board video uses main memory in bank A - * for the framebuffer, and a memory controller prevents access during - * video refresh cycles. Even if both banks contain the same amount of - * RAM, a minimum of ~320KB will be subtracted from the amount in bank A - * for the framebuffer (if on-board video is in use). - */ -#define VM_PHYSSEG_MAX 8 -#define VM_PHYSSEG_STRAT VM_PSTRAT_BIGFIRST - -#endif /* _MACHINE_VMPARAM_H_ */ diff --git a/sys/arch/mac68k/include/z8530var.h b/sys/arch/mac68k/include/z8530var.h deleted file mode 100644 index 7e5e45e0641..00000000000 --- a/sys/arch/mac68k/include/z8530var.h +++ /dev/null @@ -1,129 +0,0 @@ -/* $OpenBSD: z8530var.h,v 1.9 2011/03/23 16:54:36 pirofti Exp $ */ -/* $NetBSD: z8530var.h,v 1.2 1996/06/07 10:27:19 briggs Exp $ */ - -/* - * Copyright (c) 1994 Gordon W. Ross - * Copyright (c) 1992, 1993 - * The Regents of the University of California. All rights reserved. - * - * This software was developed by the Computer Systems Engineering group - * at Lawrence Berkeley Laboratory under DARPA contract BG 91-66 and - * contributed to Berkeley. - * - * All advertising materials mentioning features or use of this software - * must display the following acknowledgement: - * This product includes software developed by the University of - * California, Lawrence Berkeley Laboratory. - * - * 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. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. - * - * @(#)zsvar.h 8.1 (Berkeley) 6/11/93 - */ - -#ifndef _MACHINE_Z8530VAR_H_ -#define _MACHINE_Z8530VAR_H_ - -#ifdef _KERNEL -#include <mac68k/dev/z8530sc.h> - -/* - * Clock source info structure, added here so xzs_chanstate works - */ -struct zsclksrc { - long clk; /* clock rate, in MHz, present on signal line */ - int flags; /* Specifies how this source can be used - (RTxC divided, RTxC BRG, PCLK BRG, TRxC divided) and also if the source is "external" and if it - is changeable (by an ioctl ex.). The - source usage flags are used by the tty - child. The other bits tell zsloadchannelregs - if it should call an md signal source - changing routine. ZSC_VARIABLE says if - an ioctl should be able to change the - clock rate.*/ -}; -#define ZSC_PCLK 0x01 -#define ZSC_RTXBRG 0x02 -#define ZSC_RTXDIV 0x04 -#define ZSC_TRXDIV 0x08 -#define ZSC_VARIABLE 0x40 -#define ZSC_EXTERN 0x80 - -#define ZSC_BRG 0x03 -#define ZSC_DIV 0x0c - -/* - * These are the machine-dependent (extended) variants of - * struct zs_chanstate and struct zsc_softc - */ -struct xzs_chanstate { - /* machine-independent part (First!)*/ - struct zs_chanstate xzs_cs; - /* machine-dependent extensions */ - int cs_hwflags; - int cs_chip; /* type of chip */ - /* Clock source info... */ - int cs_clock_count; /* how many signal sources available */ - struct zsclksrc cs_clocks[4]; /* info on available signal sources */ - long cs_cclk_flag; /* flag for current clock source */ - long cs_pclk_flag; /* flag for pending clock source */ - int cs_csource; /* current source # */ - int cs_psource; /* pending source # */ -}; - -struct zsc_softc { - struct device zsc_dev; /* required first: base device */ - struct zs_chanstate *zsc_cs[2]; /* channel A and B soft state */ - /* Machine-dependent part follows... */ - struct xzs_chanstate xzsc_xcs_store[2]; - void *zsc_softih; -}; - -/* - * Functions to read and write individual registers in a channel. - * The ZS chip requires a 1.6 uSec. recovery time between accesses, - * and the Sun3 hardware does NOT take care of this for you. - * MacII hardware DOES dake care of the delay for us. - */ - -u_char zs_read_reg(struct zs_chanstate *cs, u_char reg); -u_char zs_read_csr(struct zs_chanstate *cs); -u_char zs_read_data(struct zs_chanstate *cs); - -void zs_write_reg(struct zs_chanstate *cs, u_char reg, u_char val); -void zs_write_csr(struct zs_chanstate *cs, u_char val); -void zs_write_data(struct zs_chanstate *cs, u_char val); -#endif /* _KERNEL */ - -/* XXX - Could define splzs() here instead of in psl.h */ - -/* Hook for MD ioctl support */ -int zsmdioctl (struct zs_chanstate *cs, u_long cmd, caddr_t data); -/* XXX - This is a bit gross... */ -#define ZS_MD_IOCTL zsmdioctl(cs, cmd, data) - -/* Callback for "external" clock sources */ -void zsmd_setclock(struct zs_chanstate *cs); -#define ZS_MD_SETCLK(cs) zsmd_setclock(cs) -#endif /* _KERNEL */ |