xref: /titanic_44/usr/src/uts/i86pc/Makefile.files (revision f2f3bb8f7847d39569aee5885302672c8396952b)
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#
23# Copyright (c) 1992, 2010, Oracle and/or its affiliates. All rights reserved.
24#
25# Copyright (c) 2010, Intel Corporation.
26# Copyright 2016 Joyent, Inc.
27#
28#	This Makefile defines file modules in the directory uts/i86pc
29#	and its children. These are the source files which are i86pc
30#	"implementation architecture" dependent.
31#
32
33#
34#	object lists
35#
36CORE_OBJS +=			\
37	acpi_stubs.o		\
38	biosdisk.o		\
39	bios_call.o		\
40	cbe.o			\
41	cmi.o			\
42	cmi_hw.o		\
43	cms.o			\
44	comm_page.o		\
45	confunix.o		\
46	cpu_idle.o		\
47	cpuid.o			\
48	cpuid_subr.o		\
49	cpupm.o			\
50	cpupm_mach.o		\
51	cpupm_amd.o		\
52	cpupm_intel.o		\
53	cpupm_throttle.o	\
54	cpu_acpi.o		\
55	dis_tables.o		\
56	ddi_impl.o		\
57	dtrace_subr.o		\
58	dvma.o			\
59	fpu_subr.o		\
60	fakebop.o		\
61	fastboot.o		\
62	fb_swtch.o		\
63	graphics.o		\
64	hardclk.o		\
65	hat_i86.o		\
66	hat_kdi.o		\
67	hment.o			\
68	hold_page.o		\
69	hrtimers.o		\
70	htable.o		\
71	hypercall.o		\
72	hypersubr.o		\
73	i86_mmu.o		\
74	ibft.o			\
75	instr_size.o		\
76	intr.o			\
77	kboot_mmu.o		\
78	kdi_subr.o		\
79	kdi_idt.o		\
80	kdi_idthdl.o		\
81	kdi_asm.o		\
82	lgrpplat.o		\
83	mach_kdi.o		\
84	mach_sysconfig.o	\
85	machdep.o		\
86	mem_config.o		\
87	mem_config_stubs.o	\
88	mem_config_arch.o	\
89	memlist_new.o		\
90	memnode.o		\
91	microcode.o		\
92	microfind.o		\
93	mlsetup.o		\
94	mp_call.o		\
95	mp_implfuncs.o		\
96	mp_machdep.o		\
97	mp_pc.o			\
98	mp_startup.o		\
99	memscrub.o		\
100	mpcore.o		\
101	notes.o			\
102	pci_bios.o		\
103	pci_cfgacc.o		\
104	pci_cfgacc_x86.o	\
105	pci_cfgspace.o		\
106	pci_mech1.o		\
107	pci_mech1_amd.o		\
108	pci_mech2.o		\
109	pci_neptune.o		\
110	pci_orion.o		\
111	pmem.o			\
112	ppage.o			\
113	pwrnow.o		\
114	speedstep.o		\
115	startup.o		\
116	timestamp.o		\
117	todpc_subr.o		\
118	trap.o			\
119	turbo.o			\
120	vm_machdep.o		\
121	xpv_platform.o		\
122	x_call.o
123
124#
125#	Add the SMBIOS subsystem object files directly to the list of objects
126#	built into unix itself; this is all common code except for smb_dev.c.
127#
128CORE_OBJS += $(SMBIOS_OBJS)
129
130#
131# These get compiled twice:
132# - once in the dboot (direct boot) identity mapped code
133# - once for use during early startup in unix
134#
135BOOT_DRIVER_OBJS =		\
136	boot_console.o		\
137	boot_keyboard.o		\
138	boot_keyboard_table.o	\
139	boot_vga.o		\
140	boot_mmu.o
141
142CORE_OBJS += $(BOOT_DRIVER_OBJS)
143
144#
145#	locore.o is special. It must be the first file relocated so that it
146#	it is relocated just where its name implies.
147#
148SPECIAL_OBJS_32 +=		\
149	locore.o		\
150	fast_trap_asm.o		\
151	interrupt.o		\
152	syscall_asm.o
153
154SPECIAL_OBJS_64 +=		\
155	locore.o		\
156	fast_trap_asm.o		\
157	interrupt.o		\
158	syscall_asm_amd64.o
159
160SPECIAL_OBJS += $(SPECIAL_OBJS_$(CLASS))
161
162#
163# Objects that get compiled into the identity mapped PT_LOAD section of unix
164# to handle the earliest part of booting.
165#
166DBOOT_OBJS_32 =
167
168DBOOT_OBJS_64 += dboot_elfload.o
169
170DBOOT_OBJS +=			\
171	dboot_asm.o		\
172	dboot_grub.o		\
173	dboot_printf.o		\
174	dboot_startkern.o	\
175	memcpy.o		\
176	memset.o		\
177	muldiv.o		\
178	sha1.o			\
179	string.o		\
180	$(BOOT_DRIVER_OBJS)	\
181	$(DBOOT_OBJS_$(CLASS))
182
183#
184#			driver and misc modules
185#
186GFX_PRIVATE_OBJS	+= gfx_private.o gfxp_pci.o gfxp_segmap.o \
187			   gfxp_devmap.o gfxp_vgatext.o gfxp_vm.o vgasubr.o
188FIPE_OBJS += fipe_drv.o fipe_pm.o
189IOAT_OBJS += ioat.o ioat_rs.o ioat_ioctl.o ioat_chan.o
190ISANEXUS_OBJS += isa.o dma_engine.o i8237A.o
191PCIE_MISC_OBJS += pcie_acpi.o pciehpc_acpi.o pcie_x86.o
192PCI_E_NEXUS_OBJS += npe.o npe_misc.o
193PCI_E_NEXUS_OBJS += pci_common.o pci_kstats.o pci_tools.o
194PCINEXUS_OBJS += pci.o pci_common.o pci_kstats.o pci_tools.o
195PCPLUSMP_OBJS += apic.o apic_regops.o psm_common.o apic_introp.o	\
196			mp_platform_common.o mp_platform_misc.o		\
197			hpet_acpi.o apic_common.o apic_timer.o
198APIX_OBJS += apix.o apic_regops.o psm_common.o apix_intr.o apix_utils.o \
199		apix_irm.o mp_platform_common.o hpet_acpi.o apic_common.o \
200		apic_timer.o
201
202
203ACPI_DRV_OBJS	+= acpi_drv.o acpi_video.o
204ACPINEX_OBJS	+= acpinex_drv.o acpinex_event.o
205
206CPUDRV_OBJS	+= \
207	cpudrv.o \
208	cpudrv_mach.o
209
210PPM_OBJS	+= ppm_subr.o ppm.o ppm_plat.o
211
212ACPIPPM_OBJS	+= acpippm.o acpisleep.o
213ACPIDEV_OBJS += acpidev_drv.o \
214	acpidev_scope.o acpidev_device.o \
215	acpidev_container.o \
216	acpidev_cpu.o \
217	acpidev_dr.o \
218	acpidev_memory.o \
219	acpidev_pci.o \
220	acpidev_resource.o \
221	acpidev_util.o
222
223DRMACH_ACPI_OBJS += drmach_acpi.o dr_util.o drmach_err.o
224
225DR_OBJS	+= dr.o dr_cpu.o dr_err.o dr_io.o dr_mem_acpi.o dr_quiesce.o dr_util.o
226
227ROOTNEX_OBJS += rootnex.o immu.o immu_dmar.o immu_dvma.o \
228		immu_intrmap.o immu_qinv.o immu_regs.o
229
230TZMON_OBJS	+= tzmon.o
231UPPC_OBJS += uppc.o psm_common.o
232XSVC_OBJS += xsvc.o
233AMD_IOMMU_OBJS +=	amd_iommu.o amd_iommu_impl.o amd_iommu_acpi.o \
234			amd_iommu_cmd.o amd_iommu_log.o amd_iommu_page_tables.o
235
236#
237#	Build up defines and paths.
238#
239ALL_DEFS	+= -Di86pc
240INC_PATH	+= -I$(UTSBASE)/i86pc -I$(SRC)/common
241INC_PATH	+= -I$(UTSBASE)/i86xpv -I$(UTSBASE)/common/xen
242
243#
244# Since the assym files are derived, the dependencies must be explicit for
245# all files including this file. (This is only actually required in the
246# instance when the .nse_depinfo file does not exist.) It may seem that
247# the lint targets should also have a similar dependency, but they don't
248# since only C headers are included when #defined(__lint) is true.
249#
250
251ASSYM_DEPS      += 		\
252	copy.o			\
253	desctbls_asm.o		\
254	ddi_i86_asm.o		\
255	exception.o		\
256	fast_trap_asm.o		\
257	float.o			\
258	i86_subr.o		\
259	interrupt.o		\
260	lock_prim.o		\
261	locore.o		\
262	mpcore.o		\
263	sseblk.o		\
264	swtch.o			\
265	syscall_asm.o		\
266	syscall_asm_amd64.o	\
267	cpr_wakecode.o
268
269CPR_IMPL_OBJS	= cpr_impl.o	cpr_wakecode.o
270
271$(KDI_ASSYM_DEPS:%=$(OBJS_DIR)/%):	$(DSF_DIR)/$(OBJS_DIR)/kdi_assym.h
272
273ASSYM_DEPS += kdi_asm.o
274