Greg Kroah-Hartman | b244131 | 2017-11-01 15:07:57 +0100 | [diff] [blame] | 1 | # SPDX-License-Identifier: GPL-2.0 |
Dave Airlie | c0e0920 | 2008-05-29 10:09:59 +1000 | [diff] [blame] | 2 | # |
| 3 | # Makefile for the drm device driver. This driver provides support for the |
| 4 | # Direct Rendering Infrastructure (DRI) in XFree86 4.1.0 and higher. |
| 5 | |
Chris Wilson | 39bf4de | 2017-10-24 19:15:47 +0100 | [diff] [blame] | 6 | # Add a set of useful warning flags and enable -Werror for CI to prevent |
| 7 | # trivial mistakes from creeping in. We have to do this piecemeal as we reject |
| 8 | # any patch that isn't warning clean, so turning on -Wall -Wextra (or W=1) we |
| 9 | # need to filter out dubious warnings. Still it is our interest |
| 10 | # to keep running locally with W=1 C=1 until we are completely clean. |
| 11 | # |
| 12 | # Note the danger in using -Wall -Wextra is that when CI updates gcc we |
| 13 | # will most likely get a sudden build breakage... Hopefully we will fix |
| 14 | # new warnings before CI updates! |
Chris Wilson | c5c2b11 | 2018-03-13 00:40:55 +0000 | [diff] [blame] | 15 | subdir-ccflags-y := -Wall -Wextra -Wvla |
Chris Wilson | 4ab09d0 | 2017-10-30 17:29:27 +0000 | [diff] [blame] | 16 | subdir-ccflags-y += $(call cc-disable-warning, unused-parameter) |
| 17 | subdir-ccflags-y += $(call cc-disable-warning, type-limits) |
| 18 | subdir-ccflags-y += $(call cc-disable-warning, missing-field-initializers) |
| 19 | subdir-ccflags-y += $(call cc-disable-warning, implicit-fallthrough) |
Chris Wilson | 6a05d29 | 2018-02-08 16:16:39 +0000 | [diff] [blame] | 20 | subdir-ccflags-y += $(call cc-disable-warning, unused-but-set-variable) |
Chris Wilson | 39bf4de | 2017-10-24 19:15:47 +0100 | [diff] [blame] | 21 | subdir-ccflags-$(CONFIG_DRM_I915_WERROR) += -Werror |
| 22 | |
| 23 | # Fine grained warnings disable |
Chris Wilson | 4ab09d0 | 2017-10-30 17:29:27 +0000 | [diff] [blame] | 24 | CFLAGS_i915_pci.o = $(call cc-disable-warning, override-init) |
| 25 | CFLAGS_intel_fbdev.o = $(call cc-disable-warning, override-init) |
Chris Wilson | 39bf4de | 2017-10-24 19:15:47 +0100 | [diff] [blame] | 26 | |
Chris Wilson | 0b1de5d | 2016-08-12 12:39:59 +0100 | [diff] [blame] | 27 | subdir-ccflags-y += \ |
| 28 | $(call as-instr,movntdqa (%eax)$(comma)%xmm0,-DCONFIG_AS_MOVNTDQA) |
Chris Wilson | 0a793ad | 2016-04-13 17:35:00 +0100 | [diff] [blame] | 29 | |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 30 | # Please keep these build lists sorted! |
| 31 | |
| 32 | # core driver code |
| 33 | i915-y := i915_drv.o \ |
Daniel Vetter | 042794b | 2015-07-24 13:55:10 +0200 | [diff] [blame] | 34 | i915_irq.o \ |
Chris Wilson | 0b1de5d | 2016-08-12 12:39:59 +0100 | [diff] [blame] | 35 | i915_memcpy.o \ |
Chris Wilson | c58305a | 2016-08-19 16:54:28 +0100 | [diff] [blame] | 36 | i915_mm.o \ |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 37 | i915_params.o \ |
Chris Wilson | 42f5551 | 2016-06-24 14:00:26 +0100 | [diff] [blame] | 38 | i915_pci.o \ |
Eric Anholt | 673a394 | 2008-07-30 12:06:12 -0700 | [diff] [blame] | 39 | i915_suspend.o \ |
Chris Wilson | 4797948 | 2017-05-03 10:39:21 +0100 | [diff] [blame] | 40 | i915_syncmap.o \ |
Chris Wilson | e68a139 | 2016-09-09 14:11:41 +0100 | [diff] [blame] | 41 | i915_sw_fence.o \ |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 42 | i915_sysfs.o \ |
Daniel Vetter | 042794b | 2015-07-24 13:55:10 +0200 | [diff] [blame] | 43 | intel_csr.o \ |
Chris Wilson | 94b4f3b | 2016-07-05 10:40:20 +0100 | [diff] [blame] | 44 | intel_device_info.o \ |
Daniel Vetter | 9c065a7 | 2014-09-30 10:56:38 +0200 | [diff] [blame] | 45 | intel_pm.o \ |
Oscar Mateo | 7d3c425 | 2018-04-10 09:12:46 -0700 | [diff] [blame^] | 46 | intel_runtime_pm.o \ |
| 47 | intel_workarounds.o |
Daniel Vetter | 9c065a7 | 2014-09-30 10:56:38 +0200 | [diff] [blame] | 48 | |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 49 | i915-$(CONFIG_COMPAT) += i915_ioc32.o |
Tomeu Vizoso | 731035f | 2016-12-12 13:29:48 +0100 | [diff] [blame] | 50 | i915-$(CONFIG_DEBUG_FS) += i915_debugfs.o intel_pipe_crc.o |
Tvrtko Ursulin | b46a33e | 2017-11-21 18:18:45 +0000 | [diff] [blame] | 51 | i915-$(CONFIG_PERF_EVENTS) += i915_pmu.o |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 52 | |
| 53 | # GEM code |
| 54 | i915-y += i915_cmd_parser.o \ |
Brad Volkin | 493018d | 2014-12-11 12:13:08 -0800 | [diff] [blame] | 55 | i915_gem_batch_pool.o \ |
Chris Wilson | 57822dc | 2017-02-22 11:40:48 +0000 | [diff] [blame] | 56 | i915_gem_clflush.o \ |
Ben Widawsky | 254f965 | 2012-06-04 14:42:42 -0700 | [diff] [blame] | 57 | i915_gem_context.o \ |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 58 | i915_gem_dmabuf.o \ |
Chris Wilson | b47eb4a | 2010-08-07 11:01:23 +0100 | [diff] [blame] | 59 | i915_gem_evict.o \ |
Chris Wilson | 54cf91d | 2010-11-25 18:00:26 +0000 | [diff] [blame] | 60 | i915_gem_execbuffer.o \ |
Joonas Lahtinen | b42fe9c | 2016-11-11 12:43:54 +0200 | [diff] [blame] | 61 | i915_gem_fence_reg.o \ |
Chris Wilson | 54cf91d | 2010-11-25 18:00:26 +0000 | [diff] [blame] | 62 | i915_gem_gtt.o \ |
Chris Wilson | 920cf41 | 2016-10-28 13:58:30 +0100 | [diff] [blame] | 63 | i915_gem_internal.o \ |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 64 | i915_gem.o \ |
Chris Wilson | b8f55be | 2017-08-11 12:11:16 +0100 | [diff] [blame] | 65 | i915_gem_object.o \ |
Daniel Vetter | 042794b | 2015-07-24 13:55:10 +0200 | [diff] [blame] | 66 | i915_gem_render_state.o \ |
Daniel Vetter | be6a037 | 2015-03-18 10:46:04 +0100 | [diff] [blame] | 67 | i915_gem_shrinker.o \ |
Chris Wilson | 9797fbf | 2012-04-24 15:47:39 +0100 | [diff] [blame] | 68 | i915_gem_stolen.o \ |
Jesse Barnes | 79e5394 | 2008-11-07 14:24:08 -0800 | [diff] [blame] | 69 | i915_gem_tiling.o \ |
Chris Wilson | 73cb970 | 2016-10-28 13:58:46 +0100 | [diff] [blame] | 70 | i915_gem_timeline.o \ |
Chris Wilson | 5cc9ed4 | 2014-05-16 14:22:37 +0100 | [diff] [blame] | 71 | i915_gem_userptr.o \ |
Matthew Auld | 465c403 | 2017-10-06 23:18:14 +0100 | [diff] [blame] | 72 | i915_gemfs.o \ |
Lionel Landwerlin | a446ae2 | 2018-03-06 12:28:56 +0000 | [diff] [blame] | 73 | i915_query.o \ |
Chris Wilson | e61e0f5 | 2018-02-21 09:56:36 +0000 | [diff] [blame] | 74 | i915_request.o \ |
Chris Wilson | 1c5d22f | 2009-08-25 11:15:50 +0100 | [diff] [blame] | 75 | i915_trace_points.o \ |
Joonas Lahtinen | b42fe9c | 2016-11-11 12:43:54 +0200 | [diff] [blame] | 76 | i915_vma.o \ |
Chris Wilson | 688e6c7 | 2016-07-01 17:23:15 +0100 | [diff] [blame] | 77 | intel_breadcrumbs.o \ |
Tvrtko Ursulin | 88d2ba2 | 2016-07-13 16:03:40 +0100 | [diff] [blame] | 78 | intel_engine_cs.o \ |
Mika Kuoppala | 3ac168a | 2016-11-01 18:43:03 +0200 | [diff] [blame] | 79 | intel_hangcheck.o \ |
Oscar Mateo | b20385f | 2014-07-24 17:04:10 +0100 | [diff] [blame] | 80 | intel_lrc.o \ |
Peter Antoine | 3bbaba0 | 2015-07-10 20:13:11 +0300 | [diff] [blame] | 81 | intel_mocs.o \ |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 82 | intel_ringbuffer.o \ |
Jackie Li | 6b0478f | 2018-03-13 17:32:50 -0700 | [diff] [blame] | 83 | intel_uncore.o \ |
| 84 | intel_wopcm.o |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 85 | |
Alex Dai | 33a732f | 2015-08-12 15:43:36 +0100 | [diff] [blame] | 86 | # general-purpose microcontroller (GuC) support |
Arkadiusz Hiler | 2d803c2 | 2016-11-25 18:59:35 +0100 | [diff] [blame] | 87 | i915-y += intel_uc.o \ |
Michal Wajdeczko | a16b431 | 2017-10-04 15:33:25 +0000 | [diff] [blame] | 88 | intel_uc_fw.o \ |
Michal Wajdeczko | 9bf384c | 2017-10-04 18:13:41 +0000 | [diff] [blame] | 89 | intel_guc.o \ |
Sujaritha Sundaresan | c24f0c1 | 2018-01-02 13:20:24 -0800 | [diff] [blame] | 90 | intel_guc_ads.o \ |
Michal Wajdeczko | f8a58d6 | 2017-05-26 11:13:25 +0000 | [diff] [blame] | 91 | intel_guc_ct.o \ |
Michal Wajdeczko | e8668bb | 2017-10-16 14:47:14 +0000 | [diff] [blame] | 92 | intel_guc_fw.o \ |
Sagar Arun Kamble | a269574 | 2017-11-16 19:02:41 +0530 | [diff] [blame] | 93 | intel_guc_log.o \ |
| 94 | intel_guc_submission.o \ |
Sagar Arun Kamble | 57312ea | 2018-03-01 22:15:45 +0530 | [diff] [blame] | 95 | intel_huc.o \ |
| 96 | intel_huc_fw.o |
Alex Dai | 33a732f | 2015-08-12 15:43:36 +0100 | [diff] [blame] | 97 | |
Mika Kuoppala | 9d0a6fa | 2014-05-14 17:02:16 +0300 | [diff] [blame] | 98 | # autogenerated null render state |
| 99 | i915-y += intel_renderstate_gen6.o \ |
| 100 | intel_renderstate_gen7.o \ |
Armin Reese | ff7a60f | 2014-10-23 08:34:28 -0700 | [diff] [blame] | 101 | intel_renderstate_gen8.o \ |
| 102 | intel_renderstate_gen9.o |
Mika Kuoppala | 9d0a6fa | 2014-05-14 17:02:16 +0300 | [diff] [blame] | 103 | |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 104 | # modesetting core code |
Jani Nikula | 7c10a2b | 2014-10-27 16:26:43 +0200 | [diff] [blame] | 105 | i915-y += intel_audio.o \ |
Daniel Vetter | 042794b | 2015-07-24 13:55:10 +0200 | [diff] [blame] | 106 | intel_atomic.o \ |
| 107 | intel_atomic_plane.o \ |
Jani Nikula | 7c10a2b | 2014-10-27 16:26:43 +0200 | [diff] [blame] | 108 | intel_bios.o \ |
Ville Syrjälä | 7ff89ca | 2017-02-07 20:33:05 +0200 | [diff] [blame] | 109 | intel_cdclk.o \ |
Lionel Landwerlin | 8563b1e | 2016-03-16 10:57:14 +0000 | [diff] [blame] | 110 | intel_color.o \ |
Jesse Barnes | 79e5394 | 2008-11-07 14:24:08 -0800 | [diff] [blame] | 111 | intel_display.o \ |
Ander Conselvan de Oliveira | b7fa22d | 2016-04-27 15:44:17 +0300 | [diff] [blame] | 112 | intel_dpio_phy.o \ |
Ander Conselvan de Oliveira | 7abd4b3 | 2016-03-08 17:46:15 +0200 | [diff] [blame] | 113 | intel_dpll_mgr.o \ |
Rodrigo Vivi | 7ff0ebc | 2014-12-08 14:09:10 -0200 | [diff] [blame] | 114 | intel_fbc.o \ |
Daniel Vetter | 47339cd | 2014-09-30 10:56:46 +0200 | [diff] [blame] | 115 | intel_fifo_underrun.o \ |
Daniel Vetter | b680c37 | 2014-09-19 18:27:27 +0200 | [diff] [blame] | 116 | intel_frontbuffer.o \ |
Sean Paul | ee5e5e7 | 2018-01-08 14:55:39 -0500 | [diff] [blame] | 117 | intel_hdcp.o \ |
Daniel Vetter | 042794b | 2015-07-24 13:55:10 +0200 | [diff] [blame] | 118 | intel_hotplug.o \ |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 119 | intel_modes.o \ |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 120 | intel_overlay.o \ |
Rodrigo Vivi | 0bc12bc | 2014-11-14 08:52:28 -0800 | [diff] [blame] | 121 | intel_psr.o \ |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 122 | intel_sideband.o \ |
| 123 | intel_sprite.o |
Daniel Vetter | e19b913 | 2014-03-18 09:43:56 +0100 | [diff] [blame] | 124 | i915-$(CONFIG_ACPI) += intel_acpi.o intel_opregion.o |
Daniel Vetter | 0695726 | 2015-08-10 13:34:08 +0200 | [diff] [blame] | 125 | i915-$(CONFIG_DRM_FBDEV_EMULATION) += intel_fbdev.o |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 126 | |
| 127 | # modesetting output/encoder code |
| 128 | i915-y += dvo_ch7017.o \ |
| 129 | dvo_ch7xxx.o \ |
| 130 | dvo_ivch.o \ |
| 131 | dvo_ns2501.o \ |
| 132 | dvo_sil164.o \ |
| 133 | dvo_tfp410.o \ |
Jesse Barnes | 79e5394 | 2008-11-07 14:24:08 -0800 | [diff] [blame] | 134 | intel_crt.o \ |
Eugeni Dodonov | 45244b8 | 2012-05-09 15:37:20 -0300 | [diff] [blame] | 135 | intel_ddi.o \ |
Yetunde Adebisi | e7156c8 | 2016-04-05 15:10:52 +0100 | [diff] [blame] | 136 | intel_dp_aux_backlight.o \ |
Ander Conselvan de Oliveira | 94223d0 | 2015-10-23 13:01:48 +0300 | [diff] [blame] | 137 | intel_dp_link_training.o \ |
Dave Airlie | 0e32b39 | 2014-05-02 14:02:48 +1000 | [diff] [blame] | 138 | intel_dp_mst.o \ |
Daniel Vetter | 042794b | 2015-07-24 13:55:10 +0200 | [diff] [blame] | 139 | intel_dp.o \ |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 140 | intel_dsi.o \ |
Jani Nikula | 9019835 | 2016-04-26 16:14:25 +0300 | [diff] [blame] | 141 | intel_dsi_dcs_backlight.o \ |
Daniel Vetter | 042794b | 2015-07-24 13:55:10 +0200 | [diff] [blame] | 142 | intel_dsi_pll.o \ |
Jani Nikula | 5431fc0 | 2017-03-06 16:31:29 +0200 | [diff] [blame] | 143 | intel_dsi_vbt.o \ |
Jesse Barnes | 79e5394 | 2008-11-07 14:24:08 -0800 | [diff] [blame] | 144 | intel_dvo.o \ |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 145 | intel_hdmi.o \ |
| 146 | intel_i2c.o \ |
Shashank Sharma | dbe9e61 | 2016-10-14 19:56:49 +0530 | [diff] [blame] | 147 | intel_lspcon.o \ |
Daniel Vetter | 2fae6a8 | 2014-03-07 09:17:21 +0100 | [diff] [blame] | 148 | intel_lvds.o \ |
| 149 | intel_panel.o \ |
| 150 | intel_sdvo.o \ |
| 151 | intel_tv.o |
Dave Airlie | c0e0920 | 2008-05-29 10:09:59 +1000 | [diff] [blame] | 152 | |
Chris Wilson | 98a2f41 | 2016-10-12 10:05:18 +0100 | [diff] [blame] | 153 | # Post-mortem debug and GPU hang state capture |
| 154 | i915-$(CONFIG_DRM_I915_CAPTURE_ERROR) += i915_gpu_error.o |
Chris Wilson | 953c7f8 | 2017-02-13 17:15:12 +0000 | [diff] [blame] | 155 | i915-$(CONFIG_DRM_I915_SELFTEST) += \ |
| 156 | selftests/i915_random.o \ |
| 157 | selftests/i915_selftest.o |
Chris Wilson | 98a2f41 | 2016-10-12 10:05:18 +0100 | [diff] [blame] | 158 | |
Yu Zhang | cf9d289 | 2015-02-10 19:05:47 +0800 | [diff] [blame] | 159 | # virtual gpu code |
| 160 | i915-y += i915_vgpu.o |
| 161 | |
Robert Bragg | eec688e | 2016-11-07 19:49:47 +0000 | [diff] [blame] | 162 | # perf code |
Robert Bragg | 8a3003d | 2016-11-07 19:49:51 +0000 | [diff] [blame] | 163 | i915-y += i915_perf.o \ |
Robert Bragg | 5182f64 | 2017-06-13 12:23:02 +0100 | [diff] [blame] | 164 | i915_oa_hsw.o \ |
| 165 | i915_oa_bdw.o \ |
| 166 | i915_oa_chv.o \ |
| 167 | i915_oa_sklgt2.o \ |
| 168 | i915_oa_sklgt3.o \ |
| 169 | i915_oa_sklgt4.o \ |
Lionel Landwerlin | 6c5c1d8 | 2017-06-13 12:23:08 +0100 | [diff] [blame] | 170 | i915_oa_bxt.o \ |
| 171 | i915_oa_kblgt2.o \ |
Lionel Landwerlin | 28c7ef9 | 2017-06-13 12:23:09 +0100 | [diff] [blame] | 172 | i915_oa_kblgt3.o \ |
Lionel Landwerlin | 22ea4f3 | 2017-09-18 12:21:24 +0100 | [diff] [blame] | 173 | i915_oa_glk.o \ |
Lionel Landwerlin | 4407eaa | 2017-11-10 19:08:40 +0000 | [diff] [blame] | 174 | i915_oa_cflgt2.o \ |
Lionel Landwerlin | 95690a0 | 2017-11-10 19:08:43 +0000 | [diff] [blame] | 175 | i915_oa_cflgt3.o \ |
Lionel Landwerlin | 1de401c | 2018-03-26 14:39:48 +0100 | [diff] [blame] | 176 | i915_oa_cnl.o \ |
| 177 | i915_oa_icl.o |
Robert Bragg | eec688e | 2016-11-07 19:49:47 +0000 | [diff] [blame] | 178 | |
Zhi Wang | 0ad35fe | 2016-06-16 08:07:00 -0400 | [diff] [blame] | 179 | ifeq ($(CONFIG_DRM_I915_GVT),y) |
| 180 | i915-y += intel_gvt.o |
| 181 | include $(src)/gvt/Makefile |
| 182 | endif |
| 183 | |
Jerome Anand | eef5732 | 2017-01-25 04:27:49 +0530 | [diff] [blame] | 184 | # LPE Audio for VLV and CHT |
| 185 | i915-y += intel_lpe_audio.o |
| 186 | |
Chris Wilson | c58305a | 2016-08-19 16:54:28 +0100 | [diff] [blame] | 187 | obj-$(CONFIG_DRM_I915) += i915.o |