Alex Deucher | d38ceaf | 2015-04-20 16:55:21 -0400 | [diff] [blame] | 1 | # |
| 2 | # Makefile for the drm device driver. This driver provides support for the |
| 3 | # Direct Rendering Infrastructure (DRI) in XFree86 4.1.0 and higher. |
| 4 | |
Jammy Zhou | 288912c | 2015-11-24 16:55:20 +0800 | [diff] [blame] | 5 | FULL_AMD_PATH=$(src)/.. |
| 6 | |
| 7 | ccflags-y := -Iinclude/drm -I$(FULL_AMD_PATH)/include/asic_reg \ |
| 8 | -I$(FULL_AMD_PATH)/include \ |
| 9 | -I$(FULL_AMD_PATH)/amdgpu \ |
Alex Deucher | 1f7371b | 2015-12-02 17:46:21 -0500 | [diff] [blame] | 10 | -I$(FULL_AMD_PATH)/scheduler \ |
| 11 | -I$(FULL_AMD_PATH)/powerplay/inc |
Alex Deucher | d38ceaf | 2015-04-20 16:55:21 -0400 | [diff] [blame] | 12 | |
| 13 | amdgpu-y := amdgpu_drv.o |
| 14 | |
| 15 | # add KMS driver |
| 16 | amdgpu-y += amdgpu_device.o amdgpu_kms.o \ |
| 17 | amdgpu_atombios.o atombios_crtc.o amdgpu_connectors.o \ |
| 18 | atom.o amdgpu_fence.o amdgpu_ttm.o amdgpu_object.o amdgpu_gart.o \ |
| 19 | amdgpu_encoders.o amdgpu_display.o amdgpu_i2c.o \ |
| 20 | amdgpu_fb.o amdgpu_gem.o amdgpu_ring.o \ |
| 21 | amdgpu_cs.o amdgpu_bios.o amdgpu_benchmark.o amdgpu_test.o \ |
| 22 | amdgpu_pm.o atombios_dp.o amdgpu_afmt.o amdgpu_trace_points.o \ |
| 23 | atombios_encoders.o amdgpu_semaphore.o amdgpu_sa.o atombios_i2c.o \ |
| 24 | amdgpu_prime.o amdgpu_vm.o amdgpu_ib.o amdgpu_pll.o \ |
| 25 | amdgpu_ucode.o amdgpu_bo_list.o amdgpu_ctx.o amdgpu_sync.o |
| 26 | |
Alex Deucher | aaa36a9 | 2015-04-20 17:31:14 -0400 | [diff] [blame] | 27 | # add asic specific block |
Alex Deucher | a2e73f5 | 2015-04-20 17:09:27 -0400 | [diff] [blame] | 28 | amdgpu-$(CONFIG_DRM_AMDGPU_CIK)+= cik.o gmc_v7_0.o cik_ih.o kv_smc.o kv_dpm.o \ |
Alex Deucher | 41548ef | 2015-07-31 17:20:14 -0400 | [diff] [blame] | 29 | 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 \ |
| 30 | amdgpu_amdkfd_gfx_v7.o |
Alex Deucher | a2e73f5 | 2015-04-20 17:09:27 -0400 | [diff] [blame] | 31 | |
Alex Deucher | aaa36a9 | 2015-04-20 17:31:14 -0400 | [diff] [blame] | 32 | amdgpu-y += \ |
| 33 | vi.o |
| 34 | |
| 35 | # add GMC block |
| 36 | amdgpu-y += \ |
| 37 | gmc_v8_0.o |
| 38 | |
Alex Deucher | d38ceaf | 2015-04-20 16:55:21 -0400 | [diff] [blame] | 39 | # add IH block |
| 40 | amdgpu-y += \ |
| 41 | amdgpu_irq.o \ |
Alex Deucher | aaa36a9 | 2015-04-20 17:31:14 -0400 | [diff] [blame] | 42 | amdgpu_ih.o \ |
| 43 | iceland_ih.o \ |
| 44 | tonga_ih.o \ |
| 45 | cz_ih.o |
Alex Deucher | d38ceaf | 2015-04-20 16:55:21 -0400 | [diff] [blame] | 46 | |
| 47 | # add SMC block |
| 48 | amdgpu-y += \ |
Alex Deucher | aaa36a9 | 2015-04-20 17:31:14 -0400 | [diff] [blame] | 49 | amdgpu_dpm.o \ |
Alex Deucher | 1f7371b | 2015-12-02 17:46:21 -0500 | [diff] [blame] | 50 | amdgpu_powerplay.o \ |
Alex Deucher | aaa36a9 | 2015-04-20 17:31:14 -0400 | [diff] [blame] | 51 | cz_smc.o cz_dpm.o \ |
| 52 | tonga_smc.o tonga_dpm.o \ |
David Zhang | 8e711e1a | 2015-07-08 01:23:25 +0800 | [diff] [blame] | 53 | fiji_smc.o fiji_dpm.o \ |
Alex Deucher | aaa36a9 | 2015-04-20 17:31:14 -0400 | [diff] [blame] | 54 | iceland_smc.o iceland_dpm.o |
| 55 | |
| 56 | # add DCE block |
| 57 | amdgpu-y += \ |
| 58 | dce_v10_0.o \ |
| 59 | dce_v11_0.o |
Alex Deucher | d38ceaf | 2015-04-20 16:55:21 -0400 | [diff] [blame] | 60 | |
| 61 | # add GFX block |
| 62 | amdgpu-y += \ |
Alex Deucher | aaa36a9 | 2015-04-20 17:31:14 -0400 | [diff] [blame] | 63 | amdgpu_gfx.o \ |
| 64 | gfx_v8_0.o |
| 65 | |
| 66 | # add async DMA block |
| 67 | amdgpu-y += \ |
| 68 | sdma_v2_4.o \ |
| 69 | sdma_v3_0.o |
Alex Deucher | d38ceaf | 2015-04-20 16:55:21 -0400 | [diff] [blame] | 70 | |
| 71 | # add UVD block |
| 72 | amdgpu-y += \ |
Alex Deucher | aaa36a9 | 2015-04-20 17:31:14 -0400 | [diff] [blame] | 73 | amdgpu_uvd.o \ |
| 74 | uvd_v5_0.o \ |
| 75 | uvd_v6_0.o |
Alex Deucher | d38ceaf | 2015-04-20 16:55:21 -0400 | [diff] [blame] | 76 | |
| 77 | # add VCE block |
| 78 | amdgpu-y += \ |
Alex Deucher | aaa36a9 | 2015-04-20 17:31:14 -0400 | [diff] [blame] | 79 | amdgpu_vce.o \ |
| 80 | vce_v3_0.o |
Alex Deucher | d38ceaf | 2015-04-20 16:55:21 -0400 | [diff] [blame] | 81 | |
Oded Gabbay | 130e037 | 2015-06-12 21:35:14 +0300 | [diff] [blame] | 82 | # add amdkfd interfaces |
| 83 | amdgpu-y += \ |
Oded Gabbay | 32c22e9 | 2015-06-12 21:38:22 +0300 | [diff] [blame] | 84 | amdgpu_amdkfd.o \ |
Ben Goz | ff758a1 | 2014-10-07 14:43:07 +0300 | [diff] [blame] | 85 | amdgpu_amdkfd_gfx_v8.o |
Oded Gabbay | 130e037 | 2015-06-12 21:35:14 +0300 | [diff] [blame] | 86 | |
Chunming Zhou | d03846a | 2015-07-28 14:20:03 -0400 | [diff] [blame] | 87 | # add cgs |
| 88 | amdgpu-y += amdgpu_cgs.o |
| 89 | |
Alex Deucher | b80d847 | 2015-08-16 22:55:02 -0400 | [diff] [blame] | 90 | # GPU scheduler |
| 91 | amdgpu-y += \ |
Chunming Zhou | c1b69ed | 2015-07-21 13:45:14 +0800 | [diff] [blame] | 92 | ../scheduler/gpu_scheduler.o \ |
Chunming Zhou | f556cb0c | 2015-08-02 11:18:04 +0800 | [diff] [blame] | 93 | ../scheduler/sched_fence.o \ |
Chunming Zhou | c1b69ed | 2015-07-21 13:45:14 +0800 | [diff] [blame] | 94 | amdgpu_sched.o |
Alex Deucher | b80d847 | 2015-08-16 22:55:02 -0400 | [diff] [blame] | 95 | |
Alex Deucher | d38ceaf | 2015-04-20 16:55:21 -0400 | [diff] [blame] | 96 | amdgpu-$(CONFIG_COMPAT) += amdgpu_ioc32.o |
| 97 | amdgpu-$(CONFIG_VGA_SWITCHEROO) += amdgpu_atpx_handler.o |
| 98 | amdgpu-$(CONFIG_ACPI) += amdgpu_acpi.o |
| 99 | amdgpu-$(CONFIG_MMU_NOTIFIER) += amdgpu_mn.o |
| 100 | |
Alex Deucher | 1f7371b | 2015-12-02 17:46:21 -0500 | [diff] [blame] | 101 | ifneq ($(CONFIG_DRM_AMD_POWERPLAY),) |
| 102 | |
Qiang Yu | bd90dd8 | 2015-12-02 10:56:57 +0800 | [diff] [blame] | 103 | include $(FULL_AMD_PATH)/powerplay/Makefile |
Alex Deucher | 1f7371b | 2015-12-02 17:46:21 -0500 | [diff] [blame] | 104 | |
| 105 | amdgpu-y += $(AMD_POWERPLAY_FILES) |
| 106 | |
| 107 | endif |
| 108 | |
Alex Deucher | d38ceaf | 2015-04-20 16:55:21 -0400 | [diff] [blame] | 109 | obj-$(CONFIG_DRM_AMDGPU)+= amdgpu.o |
| 110 | |
| 111 | CFLAGS_amdgpu_trace_points.o := -I$(src) |