diff --git a/headers/private/kernel/arch/sh4/arch_cpu.h b/headers/private/kernel/arch/sh4/arch_cpu.h deleted file mode 100644 index 0a96a113d0..0000000000 --- a/headers/private/kernel/arch/sh4/arch_cpu.h +++ /dev/null @@ -1,10 +0,0 @@ -/* -** Copyright 2003, Marcus Overhagen. All rights reserved. -** Distributed under the terms of the MIT license. -*/ -#ifndef _KERNEL_ARCH_CPU_H -#define _KERNEL_ARCH_CPU_H - -#define ATOMIC_FUNCS_ARE_SYSCALLS 1 - -#endif diff --git a/headers/private/kernel/arch/sh4/defs.h b/headers/private/kernel/arch/sh4/defs.h deleted file mode 100644 index deb96a7cc7..0000000000 --- a/headers/private/kernel/arch/sh4/defs.h +++ /dev/null @@ -1,36 +0,0 @@ -/* $Id: defs.h 11896 2005-03-18 01:50:45Z axeld $ -** -** Copyright 2001 Brian J. Swetland -** 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 _DEFS_H -#define _DEFS_H - -typedef unsigned char u1; -typedef unsigned short u2; -typedef unsigned int u4; - -#endif diff --git a/headers/private/kernel/arch/sh4/kernel.h b/headers/private/kernel/arch/sh4/kernel.h deleted file mode 100644 index a6d95b83df..0000000000 --- a/headers/private/kernel/arch/sh4/kernel.h +++ /dev/null @@ -1,30 +0,0 @@ -/* -** Copyright 2001-2002, Travis Geiselbrecht. All rights reserved. -** Distributed under the terms of the NewOS License. -*/ -#ifndef _NEWOS_KERNEL_ARCH_SH4_KERNEL_H -#define _NEWOS_KERNEL_ARCH_SH4_KERNEL_H - -#include - -// memory layout -#define KERNEL_BASE P3_AREA -#define KERNEL_SIZE P3_AREA_LEN -#define KERNEL_TOP (KERNEL_BASE + (KERNEL_SIZE - 1)) - -/* -** User space layout is a little special: -** The user space does not completely cover the space not covered by the kernel. -** This is accomplished by starting user space at 1Mb and running to 64kb short of kernel space. -** The lower 1Mb reserved spot makes it easy to find null pointer references and guarantees a -** region wont be placed there. The 64kb region assures a user space thread cannot pass -** a buffer into the kernel as part of a syscall that would cross into kernel space. -*/ -#define USER_BASE (U0_AREA + 0x100000) -#define USER_SIZE (U0_AREA_LEN - (0x10000 + 0x100000)) -#define USER_TOP (USER_BASE + USER_SIZE) - -#define USER_STACK_REGION (USER_BASE + USER_SIZE - USER_STACK_REGION_SIZE) -#define USER_STACK_REGION_SIZE 0x10000000 - -#endif diff --git a/headers/private/kernel/arch/sh4/ktypes.h b/headers/private/kernel/arch/sh4/ktypes.h deleted file mode 100644 index 84099ae34b..0000000000 --- a/headers/private/kernel/arch/sh4/ktypes.h +++ /dev/null @@ -1,11 +0,0 @@ -/* -** Copyright 2001-2002, Travis Geiselbrecht. All rights reserved. -** Distributed under the terms of the NewOS License. -*/ -#ifndef _NEWOS_KERNEL_ARCH_SH4_KTYPES_H -#define _NEWOS_KERNEL_ARCH_SH4_KTYPES_H - -typedef unsigned long addr; - -#endif - diff --git a/headers/private/kernel/arch/sh4/mmu.h b/headers/private/kernel/arch/sh4/mmu.h deleted file mode 100644 index 2dadff7994..0000000000 --- a/headers/private/kernel/arch/sh4/mmu.h +++ /dev/null @@ -1,14 +0,0 @@ -/* -** Copyright 2001, Travis Geiselbrecht. All rights reserved. -** Distributed under the terms of the NewOS License. -*/ -#ifndef _MMU_H -#define _MMU_H - -#include - -void mmu_init(kernel_args *ka, unsigned int *next_paddr); -void mmu_map_page(unsigned int vaddr, unsigned int paddr); - -#endif - diff --git a/headers/private/kernel/arch/sh4/rtl8139_priv.h b/headers/private/kernel/arch/sh4/rtl8139_priv.h deleted file mode 100644 index ce42583381..0000000000 --- a/headers/private/kernel/arch/sh4/rtl8139_priv.h +++ /dev/null @@ -1,13 +0,0 @@ -/* -** Copyright 2001, Travis Geiselbrecht. All rights reserved. -** Distributed under the terms of the NewOS License. -*/ -#ifndef _RTL8139_PRIV_H -#define _RTL8139_PRIV_H - -int rtl8139_detect(); -int rtl8139_init(); -void rtl8139_xmit(const char *ptr, int len); -int rtl8139_rx(char *buf, int buf_len); - -#endif diff --git a/headers/private/kernel/arch/sh4/rtl8139c.h b/headers/private/kernel/arch/sh4/rtl8139c.h deleted file mode 100644 index 57735699a5..0000000000 --- a/headers/private/kernel/arch/sh4/rtl8139c.h +++ /dev/null @@ -1,84 +0,0 @@ -/* -** -** Naive RealTek 8139C driver for the DC Broadband Adapter. Some -** assistance on names of things from the NetBSD-DC sources. -** -** (c)2001 Dan Potter -** License: X11 -** -*/ - -#ifndef _RTL_8139C_H -#define _RTL_8139C_H - -/* RTL8139C register definitions */ -#define RT_IDR0 0x00 /* Mac address */ -#define RT_MAR0 0x08 /* Multicast filter */ -#define RT_TXSTATUS0 0x10 /* Transmit status (4 32bit regs) */ -#define RT_TXADDR0 0x20 /* Tx descriptors (also 4 32bit) */ -#define RT_RXBUF 0x30 /* Receive buffer start address */ -#define RT_RXEARLYCNT 0x34 /* Early Rx byte count */ -#define RT_RXEARLYSTATUS 0x36 /* Early Rx status */ -#define RT_CHIPCMD 0x37 /* Command register */ -#define RT_RXBUFTAIL 0x38 /* Current address of packet read (queue tail) */ -#define RT_RXBUFHEAD 0x3A /* Current buffer address (queue head) */ -#define RT_INTRMASK 0x3C /* Interrupt mask */ -#define RT_INTRSTATUS 0x3E /* Interrupt status */ -#define RT_TXCONFIG 0x40 /* Tx config */ -#define RT_RXCONFIG 0x44 /* Rx config */ -#define RT_TIMER 0x48 /* A general purpose counter */ -#define RT_RXMISSED 0x4C /* 24 bits valid, write clears */ -#define RT_CFG9346 0x50 /* 93C46 command register */ -#define RT_CONFIG0 0x51 /* Configuration reg 0 */ -#define RT_CONFIG1 0x52 /* Configuration reg 1 */ -#define RT_TIMERINT 0x54 /* Timer interrupt register (32 bits) */ -#define RT_MEDIASTATUS 0x58 /* Media status register */ -#define RT_CONFIG3 0x59 /* Config register 3 */ -#define RT_CONFIG4 0x5A /* Config register 4 */ -#define RT_MULTIINTR 0x5C /* Multiple interrupt select */ -#define RT_MII_TSAD 0x60 /* Transmit status of all descriptors (16 bits) */ -#define RT_MII_BMCR 0x62 /* Basic Mode Control Register (16 bits) */ -#define RT_MII_BMSR 0x64 /* Basic Mode Status Register (16 bits) */ -#define RT_AS_ADVERT 0x66 /* Auto-negotiation advertisement reg (16 bits) */ -#define RT_AS_LPAR 0x68 /* Auto-negotiation link partner reg (16 bits) */ -#define RT_AS_EXPANSION 0x6A /* Auto-negotiation expansion reg (16 bits) */ - -/* RTL8193C command bits; or these together and write teh resulting value - into CHIPCMD to execute it. */ -#define RT_CMD_RESET 0x10 -#define RT_CMD_RX_ENABLE 0x08 -#define RT_CMD_TX_ENABLE 0x04 -#define RT_CMD_RX_BUF_EMPTY 0x01 - -/* RTL8139C interrupt status bits */ -#define RT_INT_PCIERR 0x8000 /* PCI Bus error */ -#define RT_INT_TIMEOUT 0x4000 /* Set when TCTR reaches TimerInt value */ -#define RT_INT_RXFIFO_OVERFLOW 0x0040 /* Rx FIFO overflow */ -#define RT_INT_RXFIFO_UNDERRUN 0x0020 /* Packet underrun / link change */ -#define RT_INT_RXBUF_OVERFLOW 0x0010 /* Rx BUFFER overflow */ -#define RT_INT_TX_ERR 0x0008 -#define RT_INT_TX_OK 0x0004 -#define RT_INT_RX_ERR 0x0002 -#define RT_INT_RX_OK 0x0001 - -/* RTL8139C transmit status bits */ -#define RT_TX_CARRIER_LOST 0x80000000 /* Carrier sense lost */ -#define RT_TX_ABORTED 0x40000000 /* Transmission aborted */ -#define RT_TX_OUT_OF_WINDOW 0x20000000 /* Out of window collision */ -#define RT_TX_STATUS_OK 0x00008000 /* Status ok: a good packet was transmitted */ -#define RT_TX_UNDERRUN 0x00004000 /* Transmit FIFO underrun */ -#define RT_TX_HOST_OWNS 0x00002000 /* Set to 1 when DMA operation is completed */ -#define RT_TX_SIZE_MASK 0x00001fff /* Descriptor size mask */ - -/* RTL8139C receive status bits */ -#define RT_RX_MULTICAST 0x00008000 /* Multicast packet */ -#define RT_RX_PAM 0x00004000 /* Physical address matched */ -#define RT_RX_BROADCAST 0x00002000 /* Broadcast address matched */ -#define RT_RX_BAD_SYMBOL 0x00000020 /* Invalid symbol in 100TX packet */ -#define RT_RX_RUNT 0x00000010 /* Packet size is <64 bytes */ -#define RT_RX_TOO_LONG 0x00000008 /* Packet size is >4K bytes */ -#define RT_RX_CRC_ERR 0x00000004 /* CRC error */ -#define RT_RX_FRAME_ALIGN 0x00000002 /* Frame alignment error */ -#define RT_RX_STATUS_OK 0x00000001 /* Status ok: a good packet was received */ - -#endif diff --git a/headers/private/kernel/arch/sh4/serial.h b/headers/private/kernel/arch/sh4/serial.h deleted file mode 100644 index c724c31483..0000000000 --- a/headers/private/kernel/arch/sh4/serial.h +++ /dev/null @@ -1,14 +0,0 @@ -/* -** Copyright 2001, Travis Geiselbrecht. All rights reserved. -** Distributed under the terms of the NewOS License. -*/ -#ifndef _SERIAL_H -#define _SERIAL_H - -int dprintf(const char *fmt, ...); -int serial_init(); -char serial_putch(const char c); -void serial_puts(const char *str); - -#endif - diff --git a/headers/private/kernel/arch/sh4/stage2.h b/headers/private/kernel/arch/sh4/stage2.h deleted file mode 100644 index 20659a8ced..0000000000 --- a/headers/private/kernel/arch/sh4/stage2.h +++ /dev/null @@ -1,19 +0,0 @@ -/* -** Copyright 2001, Travis Geiselbrecht. All rights reserved. -** Distributed under the terms of the NewOS License. -*/ -#ifndef _SH4_STAGE2_H -#define _SH4_STAGE2_H - -#include - -#include - -// kernel args -typedef struct { - // architecture specific - vcpu_struct *vcpu; -} arch_kernel_args; - -#endif - diff --git a/headers/private/kernel/arch/sh4/thread_struct.h b/headers/private/kernel/arch/sh4/thread_struct.h deleted file mode 100644 index e36c52cde3..0000000000 --- a/headers/private/kernel/arch/sh4/thread_struct.h +++ /dev/null @@ -1,17 +0,0 @@ -/* -** Copyright 2001-2002, Travis Geiselbrecht. All rights reserved. -** Distributed under the terms of the NewOS License. -*/ -#ifndef _NEWOS_KERNEL_ARCH_SH4_THREAD_STRUCT_H -#define _NEWOS_KERNEL_ARCH_SH4_THREAD_STRUCT_H - -// architecture specific thread info -struct arch_thread { - unsigned int *sp; -}; - -struct arch_proc { -}; - -#endif - diff --git a/headers/private/kernel/arch/sh4/types.h b/headers/private/kernel/arch/sh4/types.h deleted file mode 100644 index 95ef7aeffe..0000000000 --- a/headers/private/kernel/arch/sh4/types.h +++ /dev/null @@ -1,19 +0,0 @@ -/* -** Copyright 2001, Travis Geiselbrecht. All rights reserved. -** Distributed under the terms of the NewOS License. -*/ -#ifndef _SH4_TYPES_H -#define _SH4_TYPES_H - -// XXX is this accurate? -typedef unsigned long long uint64; -typedef long long int64; -typedef unsigned int uint32; -typedef int int32; -typedef unsigned short uint16; -typedef short int16; -typedef unsigned char uint8; -typedef char int8; - -#endif - diff --git a/headers/private/kernel/arch/sh4/va-sh.h b/headers/private/kernel/arch/sh4/va-sh.h deleted file mode 100644 index 729269045d..0000000000 --- a/headers/private/kernel/arch/sh4/va-sh.h +++ /dev/null @@ -1,230 +0,0 @@ -/* The ! __SH3E_VARG case is similar to the default gvarargs.h . */ - -#if (defined (__SH3E__) || defined (__SH4_SINGLE__) || defined (__SH4__) || defined (__SH4_SINGLE_ONLY__)) && ! defined (__HITACHI__) -#define __SH3E_VARG -#endif - -/* Define __gnuc_va_list. */ - -#ifndef __GNUC_VA_LIST -#define __GNUC_VA_LIST - -#ifdef __SH3E_VARG - -typedef long __va_greg; -typedef float __va_freg; - -typedef struct { - __va_greg * __va_next_o; /* next available register */ - __va_greg * __va_next_o_limit; /* past last available register */ - __va_freg * __va_next_fp; /* next available fp register */ - __va_freg * __va_next_fp_limit; /* last available fp register */ - __va_greg * __va_next_stack; /* next extended word on stack */ -} __gnuc_va_list; - -#else /* ! SH3E */ - -typedef void *__gnuc_va_list; - -#endif /* ! SH3E */ - -#endif /* __GNUC_VA_LIST */ - -/* If this is for internal libc use, don't define anything but - __gnuc_va_list. */ -#if defined (_STDARG_H) || defined (_VARARGS_H) - -#ifdef _STDARG_H - -#ifdef __SH3E_VARG - -#define va_start(AP, LASTARG) \ -__extension__ \ - ({ \ - (AP).__va_next_fp = (__va_freg *) __builtin_saveregs (); \ - (AP).__va_next_fp_limit = ((AP).__va_next_fp + \ - (__builtin_args_info (1) < 8 ? 8 - __builtin_args_info (1) : 0)); \ - (AP).__va_next_o = (__va_greg *) (AP).__va_next_fp_limit; \ - (AP).__va_next_o_limit = ((AP).__va_next_o + \ - (__builtin_args_info (0) < 4 ? 4 - __builtin_args_info (0) : 0)); \ - (AP).__va_next_stack = (__va_greg *) __builtin_next_arg (LASTARG); \ - }) - -#else /* ! SH3E */ - -#define va_start(AP, LASTARG) \ - ((AP) = ((__gnuc_va_list) __builtin_next_arg (LASTARG))) - -#endif /* ! SH3E */ - -#else /* _VARARGS_H */ - -#define va_alist __builtin_va_alist -#define va_dcl int __builtin_va_alist;... - -#ifdef __SH3E_VARG - -#define va_start(AP) \ -__extension__ \ - ({ \ - (AP).__va_next_fp = (__va_freg *) __builtin_saveregs (); \ - (AP).__va_next_fp_limit = ((AP).__va_next_fp + \ - (__builtin_args_info (1) < 8 ? 8 - __builtin_args_info (1) : 0)); \ - (AP).__va_next_o = (__va_greg *) (AP).__va_next_fp_limit; \ - (AP).__va_next_o_limit = ((AP).__va_next_o + \ - (__builtin_args_info (0) < 4 ? 4 - __builtin_args_info (0) : 0)); \ - (AP).__va_next_stack \ - = ((__va_greg *) __builtin_next_arg (__builtin_va_alist) \ - - (__builtin_args_info (0) >= 4 || __builtin_args_info (1) >= 8 \ - ? 1 : 0)); \ - }) - -#else /* ! SH3E */ - -#define va_start(AP) ((AP) = (char *) &__builtin_va_alist) - -#endif /* ! SH3E */ - -#endif /* _STDARG */ - -#ifndef va_end -void va_end (__gnuc_va_list); /* Defined in libgcc.a */ - -/* Values returned by __builtin_classify_type. */ - -enum __va_type_classes { - __no_type_class = -1, - __void_type_class, - __integer_type_class, - __char_type_class, - __enumeral_type_class, - __boolean_type_class, - __pointer_type_class, - __reference_type_class, - __offset_type_class, - __real_type_class, - __complex_type_class, - __function_type_class, - __method_type_class, - __record_type_class, - __union_type_class, - __array_type_class, - __string_type_class, - __set_type_class, - __file_type_class, - __lang_type_class -}; - -#endif -#define va_end(pvar) ((void)0) - -#ifdef __LITTLE_ENDIAN__ -#define __LITTLE_ENDIAN_P 1 -#else -#define __LITTLE_ENDIAN_P 0 -#endif - -#define __SCALAR_TYPE(TYPE) \ - ((TYPE) == __integer_type_class \ - || (TYPE) == __char_type_class \ - || (TYPE) == __enumeral_type_class) - -/* RECORD_TYPE args passed using the C calling convention are - passed by invisible reference. ??? RECORD_TYPE args passed - in the stack are made to be word-aligned; for an aggregate that is - not word-aligned, we advance the pointer to the first non-reg slot. */ - - /* When this is a smaller-than-int integer, using - auto-increment in the promoted (SImode) is fastest; - however, there is no way to express that is C. Therefore, - we use an asm. - We want the MEM_IN_STRUCT_P bit set in the emitted RTL, therefore we - use unions even when it would otherwise be unnecessary. */ - -/* gcc has an extension that allows to use a casted lvalue as an lvalue, - But it doesn't work in C++ with -pedantic - even in the presence of - __extension__ . We work around this problem by using a reference type. */ -#ifdef __cplusplus -#define __VA_REF & -#else -#define __VA_REF -#endif - -#define __va_arg_sh1(AP, TYPE) __extension__ \ -({(sizeof (TYPE) == 1 \ - ? ({union {TYPE t; char c;} __t; \ - __asm("" \ - : "=r" (__t.c) \ - : "0" ((((union { int i, j; } *__VA_REF) (AP))++)->i)); \ - __t.t;}) \ - : sizeof (TYPE) == 2 \ - ? ({union {TYPE t; short s;} __t; \ - __asm("" \ - : "=r" (__t.s) \ - : "0" ((((union { int i, j; } *__VA_REF) (AP))++)->i)); \ - __t.t;}) \ - : sizeof (TYPE) >= 4 || __LITTLE_ENDIAN_P \ - ? (((union { TYPE t; int i;} *__VA_REF) (AP))++)->t \ - : ((union {TYPE t;TYPE u;}*) ((char *)++(int *__VA_REF)(AP) - sizeof (TYPE)))->t);}) - -#ifdef __SH3E_VARG - -#define __PASS_AS_FLOAT(TYPE_CLASS,SIZE) \ - (TYPE_CLASS == __real_type_class && SIZE == 4) - -#define __TARGET_SH4_P 0 - -#if defined(__SH4__) || defined(__SH4_SINGLE__) -#undef __PASS_AS_FLOAT -#define __PASS_AS_FLOAT(TYPE_CLASS,SIZE) \ - ((TYPE_CLASS == __real_type_class && SIZE <= 8) \ - || (TYPE_CLASS == __complex_type_class && SIZE <= 16)) -#undef __TARGET_SH4_P -#define __TARGET_SH4_P 1 -#endif - -#define va_arg(pvar,TYPE) \ -__extension__ \ -({int __type = __builtin_classify_type (* (TYPE *) 0); \ - void * __result_p; \ - if (__PASS_AS_FLOAT (__type, sizeof(TYPE))) \ - { \ - if ((pvar).__va_next_fp < (pvar).__va_next_fp_limit) \ - { \ - if (((__type == __real_type_class && sizeof (TYPE) > 4)\ - || sizeof (TYPE) > 8) \ - && (((int) (pvar).__va_next_fp ^ (int) (pvar).__va_next_fp_limit)\ - & 4)) \ - (pvar).__va_next_fp++; \ - __result_p = &(pvar).__va_next_fp; \ - } \ - else \ - __result_p = &(pvar).__va_next_stack; \ - } \ - else \ - { \ - if ((pvar).__va_next_o + ((sizeof (TYPE) + 3) / 4) \ - <= (pvar).__va_next_o_limit) \ - __result_p = &(pvar).__va_next_o; \ - else \ - { \ - if (sizeof (TYPE) > 4) \ - if (! __TARGET_SH4_P) \ - (pvar).__va_next_o = (pvar).__va_next_o_limit; \ - \ - __result_p = &(pvar).__va_next_stack; \ - } \ - } \ - __va_arg_sh1(*(void **)__result_p, TYPE);}) - -#else /* ! SH3E */ - -#define va_arg(AP, TYPE) __va_arg_sh1((AP), TYPE) - -#endif /* SH3E */ - -/* Copy __gnuc_va_list into another variable of this type. */ -#define __va_copy(dest, src) ((dest) = (src)) - -#endif /* defined (_STDARG_H) || defined (_VARARGS_H) */ - diff --git a/headers/private/kernel/arch/sh4/vcpu.h b/headers/private/kernel/arch/sh4/vcpu.h deleted file mode 100644 index 92dd611297..0000000000 --- a/headers/private/kernel/arch/sh4/vcpu.h +++ /dev/null @@ -1,103 +0,0 @@ -/* -** Copyright 2001, Travis Geiselbrecht. All rights reserved. -** Distributed under the terms of the NewOS License. -*/ -#ifndef _VCPU_H -#define _VCPU_H - -#include - -// layout of the iframe is defined in boot/sh4/vcpu.S -struct iframe { - unsigned int page_fault_addr; - unsigned int excode; - unsigned int spc; - unsigned int ssr; - unsigned int sgr; - unsigned int pr; - unsigned int macl; - unsigned int mach; - unsigned int gbr; - unsigned int fpscr; - unsigned int fpul; - - float fr15_1; - float fr14_1; - float fr13_1; - float fr12_1; - float fr11_1; - float fr10_1; - float fr9_1; - float fr8_1; - float fr7_1; - float fr6_1; - float fr5_1; - float fr4_1; - float fr3_1; - float fr2_1; - float fr1_1; - float fr0_1; - - float fr15_0; - float fr14_0; - float fr13_0; - float fr12_0; - float fr11_0; - float fr10_0; - float fr9_0; - float fr8_0; - float fr7_0; - float fr6_0; - float fr5_0; - float fr4_0; - float fr3_0; - float fr2_0; - float fr1_0; - float fr0_0; - - unsigned int r7; - unsigned int r6; - unsigned int r5; - unsigned int r4; - unsigned int r3; - unsigned int r2; - unsigned int r1; - unsigned int r0; - unsigned int r14; - unsigned int r13; - unsigned int r12; - unsigned int r11; - unsigned int r10; - unsigned int r9; - unsigned int r8; -}; - -// page table structures -struct pdent { - unsigned int v:1; - unsigned int unused0:11; - unsigned int ppn:17; - unsigned int unused1:3; -}; - -struct ptent { - unsigned int v:1; - unsigned int d:1; - unsigned int sh:1; - unsigned int sz:2; - unsigned int c:1; - unsigned int tlb_ent:6; - unsigned int ppn:17; - unsigned int pr:2; - unsigned int wt:1; -}; - -// soft faults -#define EXCEPTION_PAGE_FAULT_READ 0xfe -#define EXCEPTION_PAGE_FAULT_WRITE 0xff - -// can only be used in stage2 -int vcpu_init(kernel_args *ka); - -#endif - diff --git a/headers/private/kernel/arch/sh4/vcpu_struct.h b/headers/private/kernel/arch/sh4/vcpu_struct.h deleted file mode 100644 index e0f425e9cd..0000000000 --- a/headers/private/kernel/arch/sh4/vcpu_struct.h +++ /dev/null @@ -1,22 +0,0 @@ -/* -** Copyright 2001, Travis Geiselbrecht. All rights reserved. -** Distributed under the terms of the NewOS License. -*/ -#ifndef _VCPU_STRUCT_H -#define _VCPU_STRUCT_H - -struct vector { - int (*func)(void *iframe); -}; - -typedef struct { - unsigned int *kernel_pgdir; - unsigned int *user_pgdir; - unsigned int kernel_asid; - unsigned int user_asid; - unsigned int *kstack; - struct vector vt[256]; -} vcpu_struct; - -#endif -