1*4913ab8eSaoyama /* $OpenBSD: board.h,v 1.15 2017/11/03 06:55:08 aoyama Exp $ */ 202b01b5eSaoyama /* 302b01b5eSaoyama * Mach Operating System 402b01b5eSaoyama * Copyright (c) 1993-1991 Carnegie Mellon University 502b01b5eSaoyama * Copyright (c) 1991 OMRON Corporation 602b01b5eSaoyama * All Rights Reserved. 702b01b5eSaoyama * 802b01b5eSaoyama * Permission to use, copy, modify and distribute this software and its 902b01b5eSaoyama * documentation is hereby granted, provided that both the copyright 1002b01b5eSaoyama * notice and this permission notice appear in all copies of the 1102b01b5eSaoyama * software, derivative works or modified versions, and any portions 1202b01b5eSaoyama * thereof, and that both notices appear in supporting documentation. 1302b01b5eSaoyama * 1402b01b5eSaoyama * CARNEGIE MELLON AND OMRON ALLOW FREE USE OF THIS SOFTWARE IN ITS "AS IS" 1502b01b5eSaoyama * CONDITION. CARNEGIE MELLON AND OMRON DISCLAIM ANY LIABILITY OF ANY KIND 1602b01b5eSaoyama * FOR ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE. 1702b01b5eSaoyama * 1802b01b5eSaoyama * Carnegie Mellon requests users of this software to return to 1902b01b5eSaoyama * 2002b01b5eSaoyama * Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU 2102b01b5eSaoyama * School of Computer Science 2202b01b5eSaoyama * Carnegie Mellon University 2302b01b5eSaoyama * Pittsburgh PA 15213-3890 2402b01b5eSaoyama * 2502b01b5eSaoyama * any improvements or extensions that they make and grant Carnegie the 2602b01b5eSaoyama * rights to redistribute these changes. 2702b01b5eSaoyama */ 2802b01b5eSaoyama 292fa72412Spirofti #ifndef _MACHINE_BOARD_H_ 302fa72412Spirofti #define _MACHINE_BOARD_H_ 3102b01b5eSaoyama 3202b01b5eSaoyama /* 3302b01b5eSaoyama * OMRON SX9100DT CPU board constants 3402b01b5eSaoyama */ 3502b01b5eSaoyama 3602b01b5eSaoyama /* 3702b01b5eSaoyama * Something to put append a 'U' to a long constant if it's C so that 3802b01b5eSaoyama * it'll be unsigned in both ANSI and traditional. 3902b01b5eSaoyama */ 4002b01b5eSaoyama #if defined(_LOCORE) 4102b01b5eSaoyama #define U(num) num 4202b01b5eSaoyama #elif defined(__STDC__) 4302b01b5eSaoyama #define U(num) num ## U 4402b01b5eSaoyama #else 4502b01b5eSaoyama #define U(num) num/**/U 4602b01b5eSaoyama #endif 4702b01b5eSaoyama 4802b01b5eSaoyama /* machtype values */ 497d51a68fSaoyama #define LUNA_88K 0x1 507d51a68fSaoyama #define LUNA_88K2 0x2 5102b01b5eSaoyama 5202b01b5eSaoyama #define MAXPHYSMEM U(0x10000000) /* max physical memory */ 5302b01b5eSaoyama 5402b01b5eSaoyama #define PROM_ADDR U(0x41000000) /* PROM */ 5502b01b5eSaoyama #define PROM_SPACE U(0x00040000) 5602b01b5eSaoyama #define NVRAM_ADDR U(0x45000000) /* Non Volatile */ 5702b01b5eSaoyama #define NVRAM_SPACE U(0x00001FDC) 5802b01b5eSaoyama #define FUSE_ROM_ADDR U(0x43000000) /* FUSE_ROM */ 5902b01b5eSaoyama #define FUSE_ROM_SPACE 1024 6002b01b5eSaoyama #define OBIO_CAL_CTL U(0x45001FE0) /* calendar control register */ 6102b01b5eSaoyama #define OBIO_CAL_SEC U(0x45001FE4) /* seconds */ 6202b01b5eSaoyama #define OBIO_CAL_MIN U(0x45001FE8) /* minutes */ 6302b01b5eSaoyama #define OBIO_CAL_HOUR U(0x45001FEC) /* hours */ 6402b01b5eSaoyama #define OBIO_CAL_DOW U(0x45001FF0) /* Day Of the Week */ 6502b01b5eSaoyama #define OBIO_CAL_DAY U(0x45001FF4) /* days */ 6602b01b5eSaoyama #define OBIO_CAL_MON U(0x45001FF8) /* months */ 6702b01b5eSaoyama #define OBIO_CAL_YEAR U(0x45001FFC) /* years */ 68d696b1acSaoyama #define NVRAM_ADDR_88K2 U(0x47000000) /* Non Volatile RAM area for LUNA-88K2 */ 6902b01b5eSaoyama #define OBIO_PIO0_BASE U(0x49000000) /* PIO-0 */ 7002b01b5eSaoyama #define OBIO_PIO0_SPACE U(0x0000000C) 7102b01b5eSaoyama #define OBIO_PIO0A U(0x49000000) /* PIO-0 port A */ 7202b01b5eSaoyama #define OBIO_PIO0B U(0x49000004) /* PIO-0 port B */ 7302b01b5eSaoyama #define OBIO_PIO0C U(0x49000008) /* PIO-0 port C*/ 7402b01b5eSaoyama #define OBIO_PIO0 U(0x4900000C) /* PIO-0 control */ 7502b01b5eSaoyama #define OBIO_PIO1_BASE U(0x4D000000) /* PIO-1 */ 7602b01b5eSaoyama #define OBIO_PIO1_SPACE U(0x0000000C) 7702b01b5eSaoyama #define OBIO_PIO1A U(0x4D000000) /* PIO-1 port A */ 7802b01b5eSaoyama #define OBIO_PIO1B U(0x4D000004) /* PIO-1 port B */ 7902b01b5eSaoyama #define OBIO_PIO1C U(0x4D000008) /* PIO-1 port C*/ 8002b01b5eSaoyama #define OBIO_PIO1 U(0x4D00000C) /* PIO-1 control */ 8102b01b5eSaoyama #define OBIO_SIO U(0x51000000) /* SIO */ 8202b01b5eSaoyama #define OBIO_TAS U(0x61000000) /* TAS register */ 8302b01b5eSaoyama #define OBIO_CLOCK0 U(0x63000000) /* system clock CPU 0 */ 8402b01b5eSaoyama #define OBIO_CLOCK1 U(0x63000004) /* system clock CPU 1 */ 8502b01b5eSaoyama #define OBIO_CLOCK2 U(0x63000008) /* system clock CPU 2 */ 8602b01b5eSaoyama #define OBIO_CLOCK3 U(0x6300000C) /* system clock CPU 3 */ 8702b01b5eSaoyama #define OBIO_CLK_INTR 31 /* system clock interrupt flag */ 8802b01b5eSaoyama #define INT_ST_MASK0 U(0x65000000) /* interrupt status register CPU 0 */ 8902b01b5eSaoyama #define INT_ST_MASK1 U(0x65000004) /* interrupt status register CPU 1 */ 9002b01b5eSaoyama #define INT_ST_MASK2 U(0x65000008) /* interrupt status register CPU 2 */ 9102b01b5eSaoyama #define INT_ST_MASK3 U(0x6500000C) /* interrupt status register CPU 3 */ 927c7c5fceSmiod #define INT_LEVEL 8 /* # of interrupt level + 1 */ 937c7c5fceSmiod #define INT_SET_LV7 U(0x00000000) /* disable interrupts */ 947c7c5fceSmiod #define INT_SET_LV6 U(0x00000000) /* enable level 7 */ 957c7c5fceSmiod #define INT_SET_LV5 U(0x84000000) /* enable level 7-6 */ 967c7c5fceSmiod #define INT_SET_LV4 U(0xC4000000) /* enable level 7-5 */ 977c7c5fceSmiod #define INT_SET_LV3 U(0xE4000000) /* enable level 7-4 */ 987c7c5fceSmiod #define INT_SET_LV2 U(0xF4000000) /* enable level 7-3 */ 997c7c5fceSmiod #define INT_SET_LV1 U(0xFC000000) /* enable level 7-2 */ 1007c7c5fceSmiod #define INT_SET_LV0 U(0xFC000000) /* enable interrupts */ 1017c7c5fceSmiod #define INT_SLAVE_MASK U(0x84000000) /* slave can only enable 6 and 1 */ 10202b01b5eSaoyama 10302b01b5eSaoyama #define SOFT_INT0 U(0x69000000) /* software interrupt CPU 0 */ 10402b01b5eSaoyama #define SOFT_INT1 U(0x69000004) /* software interrupt CPU 1 */ 10502b01b5eSaoyama #define SOFT_INT2 U(0x69000008) /* software interrupt CPU 2 */ 10602b01b5eSaoyama #define SOFT_INT3 U(0x6900000C) /* software interrupt CPU 3 */ 107916c390bSkrw #define SOFT_INT_FLAG0 U(0x6B000000) /* software interrupt flag CPU 0 */ 108916c390bSkrw #define SOFT_INT_FLAG1 U(0x6B000000) /* software interrupt flag CPU 1 */ 109916c390bSkrw #define SOFT_INT_FLAG2 U(0x6B000000) /* software interrupt flag CPU 2 */ 110916c390bSkrw #define SOFT_INT_FLAG3 U(0x6B000000) /* software interrupt flag CPU 3 */ 11102b01b5eSaoyama #define RESET_CPU0 U(0x6D000000) /* reset CPU 0 */ 11202b01b5eSaoyama #define RESET_CPU1 U(0x6D000004) /* reset CPU 1 */ 11302b01b5eSaoyama #define RESET_CPU2 U(0x6D000008) /* reset CPU 2 */ 11402b01b5eSaoyama #define RESET_CPU3 U(0x6D00000C) /* reset CPU 3 */ 11502b01b5eSaoyama #define RESET_CPU_ALL U(0x6D000010) /* reset ALL CPUs */ 11602b01b5eSaoyama #define TRI_PORT_RAM U(0x71000000) /* 3 port RAM */ 11702b01b5eSaoyama #define TRI_PORT_RAM_SPACE 0x20000 11802b01b5eSaoyama #define EXT_A_ADDR U(0x81000000) /* extension board A */ 11902b01b5eSaoyama #define EXT_A_SPACE U(0x02000000) 12002b01b5eSaoyama #define EXT_B_ADDR U(0x83000000) /* extension board B */ 12102b01b5eSaoyama #define EXT_B_SPACE U(0x01000000) 12202b01b5eSaoyama #define PC_BASE U(0x90000000) /* pc-98 extension board */ 12302b01b5eSaoyama #define PC_SPACE U(0x02000000) 12402b01b5eSaoyama 12502b01b5eSaoyama #define MROM_ADDR U(0xA1000000) /* Mask ROM address */ 12602b01b5eSaoyama #define MROM_SPACE 0x400000 12702b01b5eSaoyama #define BMAP_START U(0xB1000000) /* Bitmap start address */ 12802b01b5eSaoyama #define BMAP_SPACE (BMAP_END - BMAP_START) 12902b01b5eSaoyama #define BMAP_RFCNT U(0xB1000000) /* RFCNT register */ 13002b01b5eSaoyama #define BMAP_BMSEL U(0xB1040000) /* BMSEL register */ 13102b01b5eSaoyama #define BMAP_BMP U(0xB1080000) /* common bitmap plane */ 13202b01b5eSaoyama #define BMAP_BMAP0 U(0xB10C0000) /* bitmap plane 0 */ 13302b01b5eSaoyama #define BMAP_BMAP1 U(0xB1100000) /* bitmap plane 1 */ 13402b01b5eSaoyama #define BMAP_BMAP2 U(0xB1140000) /* bitmap plane 2 */ 13502b01b5eSaoyama #define BMAP_BMAP3 U(0xB1180000) /* bitmap plane 3 */ 13602b01b5eSaoyama #define BMAP_BMAP4 U(0xB11C0000) /* bitmap plane 4 */ 13702b01b5eSaoyama #define BMAP_BMAP5 U(0xB1200000) /* bitmap plane 5 */ 13802b01b5eSaoyama #define BMAP_BMAP6 U(0xB1240000) /* bitmap plane 6 */ 13902b01b5eSaoyama #define BMAP_BMAP7 U(0xB1280000) /* bitmap plane 7 */ 14002b01b5eSaoyama #define BMAP_FN U(0xB12C0000) /* common bitmap function */ 14102b01b5eSaoyama #define BMAP_FN0 U(0xB1300000) /* bitmap function 0 */ 14202b01b5eSaoyama #define BMAP_FN1 U(0xB1340000) /* bitmap function 1 */ 14302b01b5eSaoyama #define BMAP_FN2 U(0xB1380000) /* bitmap function 2 */ 14402b01b5eSaoyama #define BMAP_FN3 U(0xB13C0000) /* bitmap function 3 */ 14502b01b5eSaoyama #define BMAP_FN4 U(0xB1400000) /* bitmap function 4 */ 14602b01b5eSaoyama #define BMAP_FN5 U(0xB1440000) /* bitmap function 5 */ 14702b01b5eSaoyama #define BMAP_FN6 U(0xB1480000) /* bitmap function 6 */ 14802b01b5eSaoyama #define BMAP_FN7 U(0xB14C0000) /* bitmap function 7 */ 14902b01b5eSaoyama #define BMAP_END U(0xB1500000) 15002b01b5eSaoyama #define BMAP_END24P U(0xB1800000) /* end of 24p framemem */ 15102b01b5eSaoyama #define BMAP_PALLET0 U(0xC0000000) /* color pallet */ 15202b01b5eSaoyama #define BMAP_PALLET1 U(0xC1000000) /* color pallet */ 15302b01b5eSaoyama #define BMAP_PALLET2 U(0xC1100000) /* color pallet */ 15402b01b5eSaoyama #define BOARD_CHECK_REG U(0xD0000000) /* board check register */ 1559d69f153Smiod #define BMAP_CRTC U(0xD1000000) /* CRTC-II */ 156e03f5730Smiod #define BMAP_IDENTROM U(0xD1800000) /* bitmap-board identify ROM */ 15702b01b5eSaoyama #define SCSI_ADDR U(0xE1000000) /* SCSI address */ 15802b01b5eSaoyama #define LANCE_ADDR U(0xF1000000) /* LANCE */ 15902b01b5eSaoyama 16002b01b5eSaoyama #define CMMU_I0 U(0xFFF07000) /* CMMU instruction cpu 0 */ 16102b01b5eSaoyama #define CMMU_D0 U(0xFFF06000) /* CMMU data cpu 0 */ 16202b01b5eSaoyama #define CMMU_I1 U(0xFFF05000) /* CMMU instruction cpu 1 */ 16302b01b5eSaoyama #define CMMU_D1 U(0xFFF04000) /* CMMU data cpu 1 */ 16402b01b5eSaoyama #define CMMU_I2 U(0xFFF03000) /* CMMU instruction cpu 2 */ 16502b01b5eSaoyama #define CMMU_D2 U(0xFFF02000) /* CMMU data cpu 2 */ 16602b01b5eSaoyama #define CMMU_I3 U(0xFFF01000) /* CMMU instruction cpu 3 */ 16702b01b5eSaoyama #define CMMU_D3 U(0xFFF00000) /* CMMU data cpu 3 */ 16802b01b5eSaoyama 1692fa72412Spirofti #endif /* _MACHINE_BOARD_H_ */ 170