/[gxemul]/upstream/0.4.4/src/include/alpha_lcareg.h
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Contents of /upstream/0.4.4/src/include/alpha_lcareg.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 35 - (show annotations)
Mon Oct 8 16:21:26 2007 UTC (16 years, 6 months ago) by dpavlin
File MIME type: text/plain
File size: 4334 byte(s)
0.4.4
1 /* GXemul: $Id: alpha_lcareg.h,v 1.2 2006/06/16 18:31:26 debug Exp $ */
2 /* $NetBSD: lcareg.h,v 1.8 1997/09/05 02:14:31 thorpej Exp $ */
3
4 #ifndef ALPHA_LCAREG_H
5 #define ALPHA_LCAREG_H
6
7 /*
8 * Copyright (c) 1995 Carnegie-Mellon University.
9 * All rights reserved.
10 *
11 * Authors: Jeffrey Hsu, Jason R. Thorpe
12 *
13 * Permission to use, copy, modify and distribute this software and
14 * its documentation is hereby granted, provided that both the copyright
15 * notice and this permission notice appear in all copies of the
16 * software, derivative works or modified versions, and any portions
17 * thereof, and that both notices appear in supporting documentation.
18 *
19 * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
20 * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND
21 * FOR ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
22 *
23 * Carnegie Mellon requests users of this software to return to
24 *
25 * Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU
26 * School of Computer Science
27 * Carnegie Mellon University
28 * Pittsburgh PA 15213-3890
29 *
30 * any improvements or extensions that they make and grant Carnegie the
31 * rights to redistribute these changes.
32 */
33
34 /*
35 * 21066 chip registers
36 */
37
38 #define REGVAL(r) (*(volatile int32_t *)ALPHA_PHYS_TO_K0SEG(r))
39 #define REGVAL64(r) (*(volatile int64_t *)ALPHA_PHYS_TO_K0SEG(r))
40
41 /*
42 * Base addresses
43 */
44 #define LCA_IOC_BASE 0x180000000ULL /* LCA IOC Regs */
45 #define LCA_PCI_SIO 0x1c0000000ULL /* PCI Sp. I/O Space */
46 #define LCA_PCI_CONF 0x1e0000000ULL /* PCI Conf. Space */
47 #define LCA_PCI_SPARSE 0x200000000ULL /* PCI Sparse Space */
48 #define LCA_PCI_DENSE 0x300000000ULL /* PCI Dense Space */
49
50 #define LCA_IOC_HAE LCA_IOC_BASE /* Host Address Ext. (64) */
51 #define IOC_HAE_ADDREXT 0x00000000f8000000ULL
52 #define IOC_HAE_RSVSD 0xffffffff07ffffffULL
53
54 #define LCA_IOC_CONF (LCA_IOC_BASE + 0x020) /* Configuration Cycle Type */
55
56 #define LCA_IOC_STAT0 (LCA_IOC_BASE + 0x040) /* Status 0 */
57 #define IOC_STAT0_CMD 0x000000000000000fULL /* PCI command mask */
58 #define IOC_STAT0_ERR 0x0000000000000010ULL /* IOC error indicator R/W1C */
59 #define IOC_STAT0_LOST 0x0000000000000020ULL /* IOC lose error info R/W1C */
60 #define IOC_STAT0_THIT 0x0000000000000040ULL /* test hit */
61 #define IOC_STAT0_TREF 0x0000000000000080ULL /* test reference */
62 #define IOC_STAT0_CODE 0x0000000000000700ULL /* code mask */
63 #define IOC_STAT0_CODESHIFT 8
64 #define IOC_STAT0_P_NBR 0x00000000ffffe000ULL /* page number mask */
65
66 #define LCA_IOC_STAT1 (LCA_IOC_BASE + 0x060) /* Status 1 */
67 #define IOC_STAT1_ADDR 0x00000000ffffffffULL /* PCI address mask */
68
69 #define LCA_IOC_TBIA (LCA_IOC_BASE + 0x080) /* TLB Invalidate All */
70 #define LCA_IOC_TB_ENA (LCA_IOC_BASE + 0x0a0) /* TLB Enable */
71 #define IOC_TB_ENA_TEN 0x0000000000000080ULL
72
73 #define LCA_IOC_W_BASE0 (LCA_IOC_BASE + 0x100) /* Window Base */
74 #define LCA_IOC_W_MASK0 (LCA_IOC_BASE + 0x140) /* Window Mask */
75 #define LCA_IOC_W_T_BASE0 (LCA_IOC_BASE + 0x180) /* Translated Base */
76
77 #define LCA_IOC_W_BASE1 (LCA_IOC_BASE + 0x120) /* Window Base */
78 #define LCA_IOC_W_MASK1 (LCA_IOC_BASE + 0x160) /* Window Mask */
79 #define LCA_IOC_W_T_BASE1 (LCA_IOC_BASE + 0x1a0) /* Translated Base */
80
81 #define IOC_W_BASE_W_BASE 0x00000000fff00000ULL /* Window base value */
82 #define IOC_W_BASE_SG 0x0000000100000000ULL /* Window uses SGMAPs */
83 #define IOC_W_BASE_WEN 0x0000000200000000ULL /* Window enable */
84
85 #define IOC_W_MASK_1M 0x0000000000000000ULL /* 1MB window */
86 #define IOC_W_MASK_2M 0x0000000000100000ULL /* 2MB window */
87 #define IOC_W_MASK_4M 0x0000000000300000ULL /* 4MB window */
88 #define IOC_W_MASK_8M 0x0000000000700000ULL /* 8MB window */
89 #define IOC_W_MASK_16M 0x0000000000f00000ULL /* 16MB window */
90 #define IOC_W_MASK_32M 0x0000000001f00000ULL /* 32MB window */
91 #define IOC_W_MASK_64M 0x0000000003f00000ULL /* 64MB window */
92 #define IOC_W_MASK_128M 0x0000000007f00000ULL /* 128M window */
93 #define IOC_W_MASK_256M 0x000000000ff00000ULL /* 256M window */
94 #define IOC_W_MASK_512M 0x000000001ff00000ULL /* 512M window */
95 #define IOC_W_MASK_1G 0x000000003ff00000ULL /* 1GB window */
96 #define IOC_W_MASK_2G 0x000000007ff00000ULL /* 2GB window */
97 #define IOC_W_MASK_4G 0x00000000fff00000ULL /* 4GB window */
98
99 #define IOC_W_T_BASE 0x00000000fffffc00ULL /* page table base */
100
101 #endif /* ALPHA_LCAREG_H */

  ViewVC Help
Powered by ViewVC 1.1.26