xref: /illumos-gate/usr/src/uts/i86xpv/Makefile.files (revision dd72704bd9e794056c558153663c739e2012d721)
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) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
24#
25# Copyright 2019 Joyent, Inc.
26# Copyright 2022 Oxide Computer Company
27#
28
29#	This Makefile defines file modules in the directory uts/i86xpv
30#	and its children. These are the source files which are i86xpv
31#	"implementation architecture" dependent.
32#
33
34#
35#	object lists
36#
37CORE_OBJS +=			\
38	acpi_stubs.o		\
39	balloon.o		\
40	biosdisk.o		\
41	cbe.o			\
42	cmi.o			\
43	cmi_hw.o		\
44	cms.o			\
45	confunix.o		\
46	cpuid.o			\
47	cpuid_subr.o		\
48	cpupm.o			\
49	cpupm_mach.o		\
50	dis_tables.o		\
51	ddi_impl.o		\
52	dtrace_subr.o		\
53	dvma.o			\
54	fakebop.o		\
55	fpu_subr.o		\
56	fastboot.o		\
57	fb_swtch.o		\
58	graphics.o		\
59	hardclk.o		\
60	hat_i86.o		\
61	hat_kdi.o		\
62	hment.o			\
63	hold_page.o		\
64	hrtimers.o		\
65	htable.o		\
66	i86_mmu.o		\
67	ibft.o			\
68	instr_size.o		\
69	intr.o			\
70	kboot_mmu.o		\
71	kdi_idt.o		\
72	kdi_idthdl.o		\
73	kdi_asm.o		\
74	lgrpplat.o		\
75	mach_kdi.o		\
76	mach_sysconfig.o	\
77	machdep.o		\
78	md_clear.o		\
79	mem_config_stubs.o	\
80	memnode.o		\
81	microcode.o		\
82	mlsetup.o		\
83	mp_call.o		\
84	mp_implfuncs.o		\
85	mp_machdep.o		\
86	mp_startup.o		\
87	memscrub.o		\
88	notes.o			\
89	pci_bios.o		\
90	pci_cfgacc.o		\
91	pci_cfgacc_x86.o	\
92	pci_cfgspace.o		\
93	pci_mech1.o		\
94	pci_mech2.o		\
95	pci_neptune.o		\
96	pci_orion.o		\
97	pmem.o			\
98	ppage.o			\
99	prom_reboot.o		\
100	prom_panic.o		\
101	startup.o		\
102	ssp.o			\
103	xpv_timestamp.o		\
104	todpc_subr.o		\
105	trap.o			\
106	vm_machdep.o		\
107	x_call.o
108
109#
110#	Add the SMBIOS subsystem object files directly to the list of objects
111#	built into unix itself; this is all common code except for smb_dev.c.
112#
113CORE_OBJS += $(SMBIOS_OBJS)
114
115#
116# These get compiled twice:
117# - once in the dboot (direct boot) identity mapped code
118# - once for use during early startup in unix
119#
120BOOT_DRIVER_OBJS =		\
121	boot_console.o		\
122	boot_keyboard.o		\
123	boot_keyboard_table.o	\
124	boot_mmu.o		\
125	boot_vga.o		\
126	boot_fb.o		\
127	boot_xconsole.o		\
128	dboot_multiboot2.o	\
129	$(FONT_OBJS)
130
131CORE_OBJS += $(BOOT_DRIVER_OBJS)
132
133#
134# Extra XEN files separated out for now.
135#
136CORE_OBJS +=			\
137	cpr_driver.o		\
138	evtchn.o		\
139	gnttab.o		\
140	hypercall.o		\
141	hyperevent.o		\
142	hypersubr.o		\
143	mp_xen.o		\
144	panic_asm.o		\
145	xenguest.o		\
146	xenbus_client.o		\
147	xenbus_comms.o		\
148	xenbus_probe.o		\
149	xenbus_xs.o		\
150	xen_machdep.o		\
151	xen_mmu.o		\
152	xpv_panic.o		\
153	xvdi.o
154
155#
156#	locore.o is special. It must be the first file relocated so that it
157#	it is relocated just where its name implies.
158#
159SPECIAL_OBJS +=			\
160	locore.o		\
161	fast_trap_asm.o		\
162	interrupt.o		\
163	syscall_asm_amd64.o	\
164	kpti_trampolines.o
165
166#
167# object files used to boot into full kernel
168#
169DBOOT_OBJS_32 =	muldiv.o
170
171DBOOT_OBJS_64 =
172
173DBOOT_OBJS +=			\
174	dboot_asm.o		\
175	dboot_printf.o		\
176	dboot_startkern.o	\
177	dboot_xen.o		\
178	hypercall.o		\
179	hypersubr.o		\
180	memcpy.o		\
181	memset.o		\
182	string.o		\
183	$(BOOT_DRIVER_OBJS)	\
184	$(DBOOT_OBJS_$(CLASS))
185
186#
187#			driver & misc modules
188#
189BALLOON_OBJS += balloon_drv.o
190DOMCAPS_OBJS += domcaps.o
191EVTCHN_OBJS += evtchn_dev.o
192GFX_PRIVATE_OBJS += gfx_private.o gfxp_pci.o gfxp_segmap.o \
193		    gfxp_devmap.o gfxp_vgatext.o gfxp_vm.o vgasubr.o \
194		    gfxp_fb.o gfxp_bitmap.o
195IOAT_OBJS += ioat.o ioat_rs.o ioat_ioctl.o ioat_chan.o
196ISANEXUS_OBJS += isa.o dma_engine.o i8237A.o
197PCI_E_NEXUS_OBJS += npe.o npe_misc.o
198PCI_E_NEXUS_OBJS += pci_common.o pci_kstats.o pci_tools.o
199PCINEXUS_OBJS += pci.o pci_common.o pci_kstats.o pci_tools.o
200PRIVCMD_OBJS += seg_mf.o privcmd.o privcmd_hcall.o
201ROOTNEX_OBJS += rootnex.o
202XPVTOD_OBJS += xpvtod.o
203XPV_AUTOCONFIG_OBJS += xpv_autoconfig.o
204XPV_PSM_OBJS += xpv_psm.o mp_platform_common.o mp_platform_xpv.o \
205		apic_regops.o psm_common.o xpv_intr.o
206XPV_UPPC_OBJS += xpv_uppc.o psm_common.o
207XENBUS_OBJS += xenbus_dev.o
208XENCONS_OBJS += xencons.o
209XPVD_OBJS += xpvd.o
210XPVTAP_OBJS += xpvtap.o blk_common.o seg_mf.o
211XNB_OBJS += xnb.o
212XNBE_OBJS += xnbe.o
213XNBO_OBJS += xnbo.o
214XNBU_OBJS += xnbu.o
215XNF_OBJS += xnf.o
216XSVC_OBJS += xsvc.o
217XDF_OBJS += xdf.o
218XDB_OBJS += xdb.o
219XDT_OBJS += xdt.o
220
221#
222#	Build up defines and paths.
223#
224INC_PATH	+= -I$(UTSBASE)/i86xpv -I$(UTSBASE)/i86pc -I$(SRC)/common \
225	-I$(UTSBASE)/common/xen
226
227#
228# Since the assym files are derived, the dependencies must be explicit for
229# all files including this file.
230#
231
232ASSYM_DEPS      +=		\
233	copy.o			\
234	desctbls_asm.o		\
235	ddi_i86_asm.o		\
236	exception.o		\
237	fast_trap_asm.o		\
238	float.o			\
239	hyperevent.o		\
240	i86_subr.o		\
241	kdi_asm.o		\
242	interrupt.o		\
243	lock_prim.o		\
244	locore.o		\
245	panic_asm.o		\
246	sseblk.o		\
247	swtch.o			\
248	syscall_asm_amd64.o
249
250$(KDI_ASSYM_DEPS:%=$(OBJS_DIR)/%):	$(DSF_DIR)/$(OBJS_DIR)/kdi_assym.h
251