xref: /linux/arch/m68k/include/asm/mvme16xhw.h (revision 0e287d31b62bb53ad81d5e59778384a40f8b6f56)
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef _M68K_MVME16xHW_H_
3 #define _M68K_MVME16xHW_H_
4 
5 #include <asm/irq.h>
6 
7 
8 typedef struct {
9 	u_char	ack_icr,
10 		flt_icr,
11 		sel_icr,
12 		pe_icr,
13 		bsy_icr,
14 		spare1,
15 		isr,
16 		cr,
17 		spare2,
18 		spare3,
19 		spare4,
20 		data;
21 } MVMElp, *MVMElpPtr;
22 
23 #define MVME_LPR_BASE	0xfff42030
24 
25 #define mvmelp   ((*(volatile MVMElpPtr)(MVME_LPR_BASE)))
26 
27 #define MVME_RTC_BASE	0xfffc0000
28 
29 #define MVME_I596_BASE	0xfff46000
30 
31 #define MVME_SCC_A_ADDR	0xfff45005
32 #define MVME_SCC_B_ADDR	0xfff45001
33 #define MVME_SCC_PCLK	10000000
34 
35 #define MVME162_IRQ_TYPE_PRIO	0
36 
37 #define MVME167_IRQ_PRN		(IRQ_USER+20)
38 #define MVME16x_IRQ_I596	(IRQ_USER+23)
39 #define MVME16x_IRQ_SCSI	(IRQ_USER+21)
40 #define MVME16x_IRQ_FLY		(IRQ_USER+63)
41 #define MVME167_IRQ_SER_ERR	(IRQ_USER+28)
42 #define MVME167_IRQ_SER_MODEM	(IRQ_USER+29)
43 #define MVME167_IRQ_SER_TX	(IRQ_USER+30)
44 #define MVME167_IRQ_SER_RX	(IRQ_USER+31)
45 #define MVME16x_IRQ_TIMER	(IRQ_USER+25)
46 #define MVME167_IRQ_ABORT	(IRQ_USER+46)
47 #define MVME162_IRQ_ABORT	(IRQ_USER+30)
48 
49 /* SCC interrupts, for MVME162 */
50 #define MVME162_IRQ_SCC_BASE		(IRQ_USER+0)
51 #define MVME162_IRQ_SCCB_TX		(IRQ_USER+0)
52 #define MVME162_IRQ_SCCB_STAT		(IRQ_USER+2)
53 #define MVME162_IRQ_SCCB_RX		(IRQ_USER+4)
54 #define MVME162_IRQ_SCCB_SPCOND		(IRQ_USER+6)
55 #define MVME162_IRQ_SCCA_TX		(IRQ_USER+8)
56 #define MVME162_IRQ_SCCA_STAT		(IRQ_USER+10)
57 #define MVME162_IRQ_SCCA_RX		(IRQ_USER+12)
58 #define MVME162_IRQ_SCCA_SPCOND		(IRQ_USER+14)
59 
60 /* MVME162 version register */
61 
62 #define MVME162_VERSION_REG	0xfff4202e
63 
64 extern unsigned short mvme16x_config;
65 
66 /* Lower 8 bits must match the revision register in the MC2 chip */
67 
68 #define MVME16x_CONFIG_SPEED_32		0x0001
69 #define MVME16x_CONFIG_NO_VMECHIP2	0x0002
70 #define MVME16x_CONFIG_NO_SCSICHIP	0x0004
71 #define MVME16x_CONFIG_NO_ETHERNET	0x0008
72 #define MVME16x_CONFIG_GOT_FPU		0x0010
73 
74 #define MVME16x_CONFIG_GOT_LP		0x0100
75 #define MVME16x_CONFIG_GOT_CD2401	0x0200
76 #define MVME16x_CONFIG_GOT_SCCA		0x0400
77 #define MVME16x_CONFIG_GOT_SCCB		0x0800
78 
79 #endif
80