blob: f7c43fa24aa8374cf8ab2d8bd5b94c1540e4dea7 [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001/*
2 * This file is subject to the terms and conditions of the GNU General Public
3 * License. See the file "COPYING" in the main directory of this archive
4 * for more details.
5 *
6 * SGI IP27 specific setup.
7 *
8 * Copyright (C) 1995 - 1997, 1999 Silcon Graphics, Inc.
9 * Copyright (C) 1999 Ralf Baechle (ralf@gnu.org)
10 */
11#ifndef _ASM_SN_SN0_ARCH_H
12#define _ASM_SN_SN0_ARCH_H
13
14#include <linux/config.h>
15
Linus Torvalds1da177e2005-04-16 15:20:36 -070016#ifndef SN0XXL /* 128 cpu SMP max */
17/*
18 * This is the maximum number of nodes that can be part of a kernel.
19 * Effectively, it's the maximum number of compact node ids (cnodeid_t).
20 */
21#define MAX_COMPACT_NODES 64
22
23/*
24 * MAXCPUS refers to the maximum number of CPUs in a single kernel.
25 * This is not necessarily the same as MAXNODES * CPUS_PER_NODE
26 */
27#define MAXCPUS 128
28
29#else /* SN0XXL system */
30
31#define MAX_COMPACT_NODES 128
32#define MAXCPUS 256
33
34#endif /* SN0XXL */
35
36/*
37 * This is the maximum number of NASIDS that can be present in a system.
38 * (Highest NASID plus one.)
39 */
40#define MAX_NASIDS 256
41
42/*
43 * MAX_REGIONS refers to the maximum number of hardware partitioned regions.
44 */
45#define MAX_REGIONS 64
46#define MAX_NONPREMIUM_REGIONS 16
47#define MAX_PREMIUM_REGIONS MAX_REGIONS
48
49/*
50 * MAX_PARITIONS refers to the maximum number of logically defined
51 * partitions the system can support.
52 */
53#define MAX_PARTITIONS MAX_REGIONS
54
Linus Torvalds1da177e2005-04-16 15:20:36 -070055#define NASID_MASK_BYTES ((MAX_NASIDS + 7) / 8)
56
57/*
58 * Slot constants for SN0
59 */
Ralf Baechleaa9772e2006-06-12 00:55:14 +010060#ifdef CONFIG_SGI_SN_N_MODE
Linus Torvalds1da177e2005-04-16 15:20:36 -070061#define MAX_MEM_SLOTS 16 /* max slots per node */
Ralf Baechlef456aca2006-06-14 08:10:35 +010062#else /* !CONFIG_SGI_SN_N_MODE, assume CONFIG_SGI_SN_M_MODE */
Linus Torvalds1da177e2005-04-16 15:20:36 -070063#define MAX_MEM_SLOTS 32 /* max slots per node */
Ralf Baechlef456aca2006-06-14 08:10:35 +010064#endif /* CONFIG_SGI_SN_M_MODE */
Linus Torvalds1da177e2005-04-16 15:20:36 -070065
Linus Torvalds1da177e2005-04-16 15:20:36 -070066#define SLOT_SHIFT (27)
67#define SLOT_MIN_MEM_SIZE (32*1024*1024)
Linus Torvalds1da177e2005-04-16 15:20:36 -070068
69#define CPUS_PER_NODE 2 /* CPUs on a single hub */
70#define CPUS_PER_NODE_SHFT 1 /* Bits to shift in the node number */
71#define CPUS_PER_SUBNODE 2 /* CPUs on a single hub PI */
72
73#endif /* _ASM_SN_SN0_ARCH_H */