xref: /titanic_41/usr/src/uts/sun4u/opl/Makefile.opl (revision 18c2aff776a775d34a4c9893a4c72e0434d68e36)
1#
2# CDDL HEADER START
3#
4# The contents of this file are subject to the terms of the
5# Common Development and Distribution License (the "License").
6# You may not use this file except in compliance with the License.
7#
8# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9# or http://www.opensolaris.org/os/licensing.
10# See the License for the specific language governing permissions
11# and limitations under the License.
12#
13# When distributing Covered Code, include this CDDL HEADER in each
14# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15# If applicable, add the following below this CDDL HEADER, with the
16# fields enclosed by brackets "[]" replaced with your own identifying
17# information: Portions Copyright [yyyy] [name of copyright owner]
18#
19# CDDL HEADER END
20#
21#
22# Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
23# Use is subject to license terms.
24#
25# ident	"%Z%%M%	%I%	%E% SMI"
26#
27#	Global definitions for sun4u opl implementation specific modules.
28#
29# uts/sun4u/opl/Makefile.opl
30#
31
32#
33#	Define directories.
34#
35#
36#
37ROOT_OPL_DIR	= $(ROOT_PLAT_DIR)/SUNW,SPARC-Enterprise
38ROOT_OPL_MOD_DIR	= $(ROOT_OPL_DIR)/kernel
39ROOT_OPL_KERN_DIR_32 = $(ROOT_OPL_MOD_DIR)
40ROOT_OPL_KERN_DIR_64 = $(ROOT_OPL_MOD_DIR)/$(SUBDIR64)
41ROOT_OPL_MISC_DIR_32 = $(ROOT_OPL_MOD_DIR)/misc
42ROOT_OPL_MISC_DIR_64 = $(ROOT_OPL_MOD_DIR)/misc/$(SUBDIR64)
43ROOT_OPL_DRV_DIR_32 = $(ROOT_OPL_MOD_DIR)/drv
44ROOT_OPL_DRV_DIR_64 = $(ROOT_OPL_MOD_DIR)/drv/$(SUBDIR64)
45ROOT_OPL_CPU_DIR_32 = $(ROOT_OPL_MOD_DIR)/cpu
46ROOT_OPL_CPU_DIR_64 = $(ROOT_OPL_MOD_DIR)/cpu/$(SUBDIR64)
47ROOT_OPL_CRYPTO_DIR_32 = $(ROOT_OPL_MOD_DIR)/crypto
48ROOT_OPL_CRYPTO_DIR_64 = $(ROOT_OPL_MOD_DIR)/crypto/$(SUBDIR64)
49
50ROOT_OPL_KERN_DIR	= $(ROOT_OPL_KERN_DIR_$(CLASS))
51ROOT_OPL_MISC_DIR	= $(ROOT_OPL_MISC_DIR_$(CLASS))
52ROOT_OPL_DRV_DIR	= $(ROOT_OPL_DRV_DIR_$(CLASS))
53ROOT_OPL_CPU_DIR	= $(ROOT_OPL_CPU_DIR_$(CLASS))
54ROOT_OPL_CRYPTO_DIR	= $(ROOT_OPL_CRYPTO_DIR_$(CLASS))
55
56ROOT_PLAT_MOD_DIRS	+= $(ROOT_OPL_MOD_DIR)
57ROOT_PLAT_MISC_DIRS_32	+= $(ROOT_OPL_MISC_DIR_32)
58
59USR_OPL_DIR		= $(USR_PLAT_DIR)/SUNW,SPARC-Enterprise
60USR_OPL_LIB_DIR		= $(USR_OPL_DIR)/lib
61USR_OPL_SBIN_DIR	= $(USR_OPL_DIR)/sbin
62USR_OPL_SBIN_EEPROM	= $(USR_OPL_SBIN_DIR)/eeprom
63USR_OPL_SBIN_PRTDIAG	= $(USR_OPL_SBIN_DIR)/prtdiag
64USR_OPL_SBIN_TRAPSTAT	= $(USR_OPL_SBIN_DIR)/trapstat
65USR_OPL_SBIN_FRUADM	= $(USR_OPL_SBIN_DIR)/fruadm
66USR_OPL_INC_DIR		= $(USR_OPL_DIR)/include
67USR_OPL_ISYS_DIR	= $(USR_OPL_INC_DIR)/sys
68
69OPL_LINT_LIB_DIR	= $(UTSBASE)/$(PLATFORM)/opl/lint-libs/$(OBJS_DIR)
70OPLMSU_OPTION		= options
71
72#
73#	Define modules.
74#
75OPL_KMODS	= platmod
76OPL_KMODS	+= dm2s
77OPL_KMODS	+= oplkmdrv
78OPL_KMODS	+= pcicmu
79OPL_KMODS	+= oplpanel
80OPL_KMODS	+= scfd
81OPL_KMODS	+= dr .WAIT drmach
82OPL_KMODS	+= oplmsu
83OPL_KMODS	+= mc-opl
84
85#
86#	CPU modules.
87#
88OPL_CPU_KMODS += olympus_c
89
90#	Links to OPL crypto modules
91#
92OPL_CRYPTO_LINKS	= aes
93
94#
95#	Include the makefiles which define build rule templates, the
96#	collection of files per module, and a few specific flags. Note
97#	that order is significant, just as with an include path. The
98#	first build rule template which matches the files name will be
99#	used. By including these in order from most machine dependent
100#	to most machine independent, we allow a machine dependent file
101#	to be used in preference over a machine independent version
102#	(Such as a machine specific optimization, which preserves the
103#	interfaces.)
104#
105include $(UTSBASE)/sun4u/ngdr/Makefile.files
106include $(UTSBASE)/sun4u/opl/Makefile.files
107
108#
109#	Include common rules.
110#
111include $(UTSBASE)/sun4u/Makefile.sun4u
112
113#
114#	Everybody needs to know how to build modstubs.o and to locate unix.o
115#
116UNIX_DIR	= $(UTSBASE)/$(PLATFORM)/opl/unix
117MODSTUBS_DIR	= $(UNIX_DIR)
118DSF_DIR		= $(UTSBASE)/$(PLATFORM)/opl/genassym
119LINTS_DIR	= $(OBJS_DIR)
120LINT_LIB_DIR	= $(UTSBASE)/$(PLATFORM)/opl/lint-libs/$(OBJS_DIR)
121
122UNIX_O		= $(UNIX_DIR)/$(OBJS_DIR)/unix.o
123
124LINT_LIB	= $(LINT_LIB_DIR)/llib-lunix.ln
125
126#
127#	Define the actual specific platforms
128#
129MACHINE_DEFS	= -D$(PLATFORM) -D_MACHDEP -DSFMMU -DMP
130MACHINE_DEFS	+= -D_CPU_SIGNATURE
131
132#
133# Maximum CPUID  =   01111 11 01 1 = 0x1FB (507)
134# Maximum CHIPID = 1 01111 11 00 0 = 0x5F8 (1528)
135#
136MACHINE_DEFS	+= -DNCPU=508
137MACHINE_DEFS	+= -DMAX_CPU_CHIPID=1529
138MACHINE_DEFS	+= -DMAX_UPA=256
139MACHINE_DEFS	+= -DIGN_SIZE=8
140MACHINE_DEFS	+= -DMAX_MEM_NODES=16
141#
142# UTSB_PHYS will enable user TSB physical access for TL>0
143#
144MACHINE_DEFS	+= -DUTSB_PHYS
145MACHINE_DEFS	+= -D_OPL
146MACHINE_DEFS    += -DOLYMPUS_SHARED_FTLB
147MACHINE_DEFS	+= -D_CMP_NO_ERROR_STEERING -D_HW_MEMSCRUB_SUPPORT
148MACHINE_DEFS	+= -DDO_CORELEVEL_LOADBAL
149MACHINE_DEFS	+= -DITLB_32M_256M_SUPPORT
150#
151# OLYMPUS C cross-call erratas.
152#  - revision A can only deliver one xcall at a time.
153#  - revision B can dispatch xcalls to 31 (IDSR_BN_SETS) CPUs at a time,
154#    but it can not send more xcalls until all the pending xcalls are
155#    dispatched. In other words, all previous 31 xcall slots must be
156#    in non-busy state before further xcalls can be issued.
157MACHINE_DEFS += -DOLYMPUS_C_REV_A_ERRATA_XCALL
158MACHINE_DEFS += -DOLYMPUS_C_REV_B_ERRATA_XCALL
159#
160# OLYMPUS C Spurious interrupts
161# - When an UE is detected in a interrupt packet,
162#   Olympus-C takes an interrupt_vector_trap (TT=0x60) while
163#   ASI_INTR_RECIEVE.BUSY is set to zero to indicate the existence
164#   of the error. Software will see this as a spurious interrupt since
165#   the interrupt busy bit is set to zero. SW will still need to
166#   explicitly clear the interrupt busy bit to reset the HW state.
167#   Failure to do so will result in the processor continuously taking
168#   an interrupt vector trap when PSTATE.IE is reset to one.
169#   Note that UE in interrupt packet is reported to the SP and handled
170#   accordingly. For the domain, the system should panic as it is not
171#   recoverable.
172MACHINE_DEFS += -DCLEAR_INTR_BUSYBIT_ON_SPURIOUS
173
174.KEEP_STATE:
175