]>
Commit | Line | Data |
---|---|---|
1a09120f AD |
1 | # |
2 | # Copyright 2017 Advanced Micro Devices, Inc. | |
3 | # | |
4 | # Permission is hereby granted, free of charge, to any person obtaining a | |
5 | # copy of this software and associated documentation files (the "Software"), | |
6 | # to deal in the Software without restriction, including without limitation | |
7 | # the rights to use, copy, modify, merge, publish, distribute, sublicense, | |
8 | # and/or sell copies of the Software, and to permit persons to whom the | |
9 | # Software is furnished to do so, subject to the following conditions: | |
10 | # | |
11 | # The above copyright notice and this permission notice shall be included in | |
12 | # all copies or substantial portions of the Software. | |
13 | # | |
14 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | |
15 | # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | |
16 | # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL | |
17 | # THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR | |
18 | # OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, | |
19 | # ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR | |
20 | # OTHER DEALINGS IN THE SOFTWARE. | |
21 | # | |
d38ceaf9 AD |
22 | # |
23 | # Makefile for the drm device driver. This driver provides support for the | |
24 | # Direct Rendering Infrastructure (DRI) in XFree86 4.1.0 and higher. | |
25 | ||
288912cb | 26 | FULL_AMD_PATH=$(src)/.. |
4562236b HW |
27 | DISPLAY_FOLDER_NAME=display |
28 | FULL_AMD_DISPLAY_PATH = $(FULL_AMD_PATH)/$(DISPLAY_FOLDER_NAME) | |
288912cb | 29 | |
248a1d6f | 30 | ccflags-y := -I$(FULL_AMD_PATH)/include/asic_reg \ |
288912cb JZ |
31 | -I$(FULL_AMD_PATH)/include \ |
32 | -I$(FULL_AMD_PATH)/amdgpu \ | |
a8fe58ce | 33 | -I$(FULL_AMD_PATH)/powerplay/inc \ |
4562236b HW |
34 | -I$(FULL_AMD_PATH)/acp/include \ |
35 | -I$(FULL_AMD_DISPLAY_PATH) \ | |
36 | -I$(FULL_AMD_DISPLAY_PATH)/include \ | |
37 | -I$(FULL_AMD_DISPLAY_PATH)/dc \ | |
04d5e276 AL |
38 | -I$(FULL_AMD_DISPLAY_PATH)/amdgpu_dm \ |
39 | -I$(FULL_AMD_PATH)/amdkfd | |
d38ceaf9 AD |
40 | |
41 | amdgpu-y := amdgpu_drv.o | |
42 | ||
43 | # add KMS driver | |
44 | amdgpu-y += amdgpu_device.o amdgpu_kms.o \ | |
45 | amdgpu_atombios.o atombios_crtc.o amdgpu_connectors.o \ | |
46 | atom.o amdgpu_fence.o amdgpu_ttm.o amdgpu_object.o amdgpu_gart.o \ | |
47 | amdgpu_encoders.o amdgpu_display.o amdgpu_i2c.o \ | |
48 | amdgpu_fb.o amdgpu_gem.o amdgpu_ring.o \ | |
49 | amdgpu_cs.o amdgpu_bios.o amdgpu_benchmark.o amdgpu_test.o \ | |
50 | amdgpu_pm.o atombios_dp.o amdgpu_afmt.o amdgpu_trace_points.o \ | |
2f4b9400 | 51 | atombios_encoders.o amdgpu_sa.o atombios_i2c.o \ |
d38ceaf9 | 52 | amdgpu_prime.o amdgpu_vm.o amdgpu_ib.o amdgpu_pll.o \ |
bb990bb0 | 53 | amdgpu_ucode.o amdgpu_bo_list.o amdgpu_ctx.o amdgpu_sync.o \ |
effd924d | 54 | amdgpu_gtt_mgr.o amdgpu_vram_mgr.o amdgpu_virt.o amdgpu_atomfirmware.o \ |
11c3a249 | 55 | amdgpu_vf_error.o amdgpu_sched.o amdgpu_debugfs.o amdgpu_ids.o \ |
fb30fc59 | 56 | amdgpu_gmc.o amdgpu_xgmi.o |
d38ceaf9 | 57 | |
aaa36a97 | 58 | # add asic specific block |
e42d8526 | 59 | amdgpu-$(CONFIG_DRM_AMDGPU_CIK)+= cik.o cik_ih.o kv_smc.o kv_dpm.o \ |
fcdfa432 | 60 | ci_smc.o ci_dpm.o dce_v8_0.o gfx_v7_0.o cik_sdma.o uvd_v4_2.o vce_v2_0.o |
a2e73f56 | 61 | |
1919696e | 62 | amdgpu-$(CONFIG_DRM_AMDGPU_SI)+= si.o gmc_v6_0.o gfx_v6_0.o si_ih.o si_dma.o dce_v6_0.o si_dpm.o si_smc.o |
a036db18 | 63 | |
aaa36a97 | 64 | amdgpu-y += \ |
8ee273e5 | 65 | vi.o mxgpu_vi.o nbio_v6_1.o soc15.o emu_soc.o mxgpu_ai.o nbio_v7_0.o vega10_reg_init.o \ |
fe3c9489 | 66 | vega20_reg_init.o nbio_v7_4.o |
aaa36a97 | 67 | |
d99605ea HZ |
68 | # add DF block |
69 | amdgpu-y += \ | |
13b58150 FX |
70 | df_v1_7.o \ |
71 | df_v3_6.o | |
d99605ea | 72 | |
aaa36a97 AD |
73 | # add GMC block |
74 | amdgpu-y += \ | |
e42d8526 | 75 | gmc_v7_0.o \ |
e60f8db5 | 76 | gmc_v8_0.o \ |
bf0a60b7 | 77 | gfxhub_v1_0.o mmhub_v1_0.o gmc_v9_0.o gfxhub_v1_1.o |
aaa36a97 | 78 | |
d38ceaf9 AD |
79 | # add IH block |
80 | amdgpu-y += \ | |
81 | amdgpu_irq.o \ | |
aaa36a97 AD |
82 | amdgpu_ih.o \ |
83 | iceland_ih.o \ | |
84 | tonga_ih.o \ | |
282aae55 KW |
85 | cz_ih.o \ |
86 | vega10_ih.o | |
d38ceaf9 | 87 | |
0e5ca0d1 HR |
88 | # add PSP block |
89 | amdgpu-y += \ | |
90 | amdgpu_psp.o \ | |
fd341dc5 | 91 | psp_v3_1.o \ |
654f761c FX |
92 | psp_v10_0.o \ |
93 | psp_v11_0.o | |
0e5ca0d1 | 94 | |
d38ceaf9 AD |
95 | # add SMC block |
96 | amdgpu-y += \ | |
b905090d | 97 | amdgpu_dpm.o |
aaa36a97 AD |
98 | |
99 | # add DCE block | |
100 | amdgpu-y += \ | |
101 | dce_v10_0.o \ | |
c6e14f40 ED |
102 | dce_v11_0.o \ |
103 | dce_virtual.o | |
d38ceaf9 AD |
104 | |
105 | # add GFX block | |
106 | amdgpu-y += \ | |
aaa36a97 | 107 | amdgpu_gfx.o \ |
b1023571 KW |
108 | gfx_v8_0.o \ |
109 | gfx_v9_0.o | |
aaa36a97 AD |
110 | |
111 | # add async DMA block | |
112 | amdgpu-y += \ | |
bb7743bc | 113 | amdgpu_sdma.o \ |
aaa36a97 | 114 | sdma_v2_4.o \ |
2130f89c KW |
115 | sdma_v3_0.o \ |
116 | sdma_v4_0.o | |
d38ceaf9 AD |
117 | |
118 | # add UVD block | |
119 | amdgpu-y += \ | |
aaa36a97 AD |
120 | amdgpu_uvd.o \ |
121 | uvd_v5_0.o \ | |
09bfb891 LL |
122 | uvd_v6_0.o \ |
123 | uvd_v7_0.o | |
d38ceaf9 AD |
124 | |
125 | # add VCE block | |
126 | amdgpu-y += \ | |
aaa36a97 | 127 | amdgpu_vce.o \ |
c1dc356a LL |
128 | vce_v3_0.o \ |
129 | vce_v4_0.o | |
d38ceaf9 | 130 | |
95d0906f LL |
131 | # add VCN block |
132 | amdgpu-y += \ | |
88b5af70 LL |
133 | amdgpu_vcn.o \ |
134 | vcn_v1_0.o | |
95d0906f | 135 | |
130e0371 | 136 | # add amdkfd interfaces |
fcdfa432 OG |
137 | amdgpu-y += amdgpu_amdkfd.o |
138 | ||
139 | ifneq ($(CONFIG_HSA_AMD),) | |
04d5e276 AL |
140 | AMDKFD_PATH := ../amdkfd |
141 | include $(FULL_AMD_PATH)/amdkfd/Makefile | |
142 | amdgpu-y += $(AMDKFD_FILES) | |
130e0371 | 143 | amdgpu-y += \ |
d8d019cc | 144 | amdgpu_amdkfd_fence.o \ |
a46a2cd1 | 145 | amdgpu_amdkfd_gpuvm.o \ |
d5a114a6 FK |
146 | amdgpu_amdkfd_gfx_v8.o \ |
147 | amdgpu_amdkfd_gfx_v9.o | |
130e0371 | 148 | |
fcdfa432 OG |
149 | ifneq ($(CONFIG_DRM_AMDGPU_CIK),) |
150 | amdgpu-y += amdgpu_amdkfd_gfx_v7.o | |
151 | endif | |
152 | ||
153 | endif | |
154 | ||
d03846af CZ |
155 | # add cgs |
156 | amdgpu-y += amdgpu_cgs.o | |
157 | ||
b80d8475 | 158 | # GPU scheduler |
1b1f42d8 | 159 | amdgpu-y += amdgpu_job.o |
b80d8475 | 160 | |
a8fe58ce MB |
161 | # ACP componet |
162 | ifneq ($(CONFIG_DRM_AMD_ACP),) | |
163 | amdgpu-y += amdgpu_acp.o | |
164 | ||
165 | AMDACPPATH := ../acp | |
166 | include $(FULL_AMD_PATH)/acp/Makefile | |
167 | ||
168 | amdgpu-y += $(AMD_ACP_FILES) | |
169 | endif | |
170 | ||
d38ceaf9 AD |
171 | amdgpu-$(CONFIG_COMPAT) += amdgpu_ioc32.o |
172 | amdgpu-$(CONFIG_VGA_SWITCHEROO) += amdgpu_atpx_handler.o | |
173 | amdgpu-$(CONFIG_ACPI) += amdgpu_acpi.o | |
174 | amdgpu-$(CONFIG_MMU_NOTIFIER) += amdgpu_mn.o | |
175 | ||
bd90dd89 | 176 | include $(FULL_AMD_PATH)/powerplay/Makefile |
1f7371b2 AD |
177 | |
178 | amdgpu-y += $(AMD_POWERPLAY_FILES) | |
179 | ||
4562236b HW |
180 | ifneq ($(CONFIG_DRM_AMD_DC),) |
181 | ||
182 | RELATIVE_AMD_DISPLAY_PATH = ../$(DISPLAY_FOLDER_NAME) | |
183 | include $(FULL_AMD_DISPLAY_PATH)/Makefile | |
184 | ||
185 | amdgpu-y += $(AMD_DISPLAY_FILES) | |
186 | ||
187 | endif | |
188 | ||
d38ceaf9 | 189 | obj-$(CONFIG_DRM_AMDGPU)+= amdgpu.o |