diff options
author | Carlos Santa <carlos.santa@intel.com> | 2016-08-17 15:30:55 -0400 |
---|---|---|
committer | Rodrigo Vivi <rodrigo.vivi@intel.com> | 2016-09-07 19:07:09 -0400 |
commit | 804b87125e3ce49b20d9e8f39a70280e9adc5de1 (patch) | |
tree | 12fa0dc38844a58a875fa781a10ae8f5611df5ee /drivers/gpu/drm | |
parent | ca9c4523882bb0ce86b4adb2b5ee4f29d2f0fc5b (diff) |
drm/i915: Move HAS_GMCH_DISPLAY definition to platform
Moving all GPU features to the platform definition allows for
- standard place when adding new features from new platforms
- possible to see supported features when dumping struct
definitions
Signed-off-by: Carlos Santa <carlos.santa@intel.com>
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r-- | drivers/gpu/drm/i915/i915_drv.h | 4 | ||||
-rw-r--r-- | drivers/gpu/drm/i915/i915_pci.c | 5 |
2 files changed, 7 insertions, 2 deletions
diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h index 112e378d1937..fcba6fe3caaf 100644 --- a/drivers/gpu/drm/i915/i915_drv.h +++ b/drivers/gpu/drm/i915/i915_drv.h | |||
@@ -665,6 +665,7 @@ struct intel_csr { | |||
665 | func(has_hw_contexts) sep \ | 665 | func(has_hw_contexts) sep \ |
666 | func(has_logical_ring_contexts) sep \ | 666 | func(has_logical_ring_contexts) sep \ |
667 | func(has_l3_dpf) sep \ | 667 | func(has_l3_dpf) sep \ |
668 | func(has_gmch_display) sep \ | ||
668 | func(has_pipe_cxsr) sep \ | 669 | func(has_pipe_cxsr) sep \ |
669 | func(has_hotplug) sep \ | 670 | func(has_hotplug) sep \ |
670 | func(cursor_needs_physical) sep \ | 671 | func(cursor_needs_physical) sep \ |
@@ -2838,8 +2839,7 @@ struct drm_i915_cmd_table { | |||
2838 | #define HAS_PCH_NOP(dev) (INTEL_PCH_TYPE(dev) == PCH_NOP) | 2839 | #define HAS_PCH_NOP(dev) (INTEL_PCH_TYPE(dev) == PCH_NOP) |
2839 | #define HAS_PCH_SPLIT(dev) (INTEL_PCH_TYPE(dev) != PCH_NONE) | 2840 | #define HAS_PCH_SPLIT(dev) (INTEL_PCH_TYPE(dev) != PCH_NONE) |
2840 | 2841 | ||
2841 | #define HAS_GMCH_DISPLAY(dev) (INTEL_INFO(dev)->gen < 5 || \ | 2842 | #define HAS_GMCH_DISPLAY(dev) (INTEL_INFO(dev)->has_gmch_display) |
2842 | IS_VALLEYVIEW(dev) || IS_CHERRYVIEW(dev)) | ||
2843 | 2843 | ||
2844 | /* DPF == dynamic parity feature */ | 2844 | /* DPF == dynamic parity feature */ |
2845 | #define HAS_L3_DPF(dev) (INTEL_INFO(dev)->has_l3_dpf) | 2845 | #define HAS_L3_DPF(dev) (INTEL_INFO(dev)->has_l3_dpf) |
diff --git a/drivers/gpu/drm/i915/i915_pci.c b/drivers/gpu/drm/i915/i915_pci.c index e192df929dde..0f1eb4a5153d 100644 --- a/drivers/gpu/drm/i915/i915_pci.c +++ b/drivers/gpu/drm/i915/i915_pci.c | |||
@@ -57,6 +57,7 @@ | |||
57 | #define GEN2_FEATURES \ | 57 | #define GEN2_FEATURES \ |
58 | .gen = 2, .num_pipes = 1, \ | 58 | .gen = 2, .num_pipes = 1, \ |
59 | .has_overlay = 1, .overlay_needs_physical = 1, \ | 59 | .has_overlay = 1, .overlay_needs_physical = 1, \ |
60 | .has_gmch_display = 1, \ | ||
60 | .ring_mask = RENDER_RING, \ | 61 | .ring_mask = RENDER_RING, \ |
61 | GEN_DEFAULT_PIPEOFFSETS, \ | 62 | GEN_DEFAULT_PIPEOFFSETS, \ |
62 | CURSOR_OFFSETS | 63 | CURSOR_OFFSETS |
@@ -85,6 +86,7 @@ static const struct intel_device_info intel_i865g_info = { | |||
85 | 86 | ||
86 | #define GEN3_FEATURES \ | 87 | #define GEN3_FEATURES \ |
87 | .gen = 3, .num_pipes = 2, \ | 88 | .gen = 3, .num_pipes = 2, \ |
89 | .has_gmch_display = 1, \ | ||
88 | .ring_mask = RENDER_RING, \ | 90 | .ring_mask = RENDER_RING, \ |
89 | GEN_DEFAULT_PIPEOFFSETS, \ | 91 | GEN_DEFAULT_PIPEOFFSETS, \ |
90 | CURSOR_OFFSETS | 92 | CURSOR_OFFSETS |
@@ -119,6 +121,7 @@ static const struct intel_device_info intel_i945gm_info = { | |||
119 | #define GEN4_FEATURES \ | 121 | #define GEN4_FEATURES \ |
120 | .gen = 4, .num_pipes = 2, \ | 122 | .gen = 4, .num_pipes = 2, \ |
121 | .has_hotplug = 1, \ | 123 | .has_hotplug = 1, \ |
124 | .has_gmch_display = 1, \ | ||
122 | .ring_mask = RENDER_RING, \ | 125 | .ring_mask = RENDER_RING, \ |
123 | GEN_DEFAULT_PIPEOFFSETS, \ | 126 | GEN_DEFAULT_PIPEOFFSETS, \ |
124 | CURSOR_OFFSETS | 127 | CURSOR_OFFSETS |
@@ -246,6 +249,7 @@ static const struct intel_device_info intel_ivybridge_q_info = { | |||
246 | .has_rc6 = 1, \ | 249 | .has_rc6 = 1, \ |
247 | .has_gmbus_irq = 1, \ | 250 | .has_gmbus_irq = 1, \ |
248 | .has_hw_contexts = 1, \ | 251 | .has_hw_contexts = 1, \ |
252 | .has_gmch_display = 1, \ | ||
249 | .need_gfx_hws = 1, .has_hotplug = 1, \ | 253 | .need_gfx_hws = 1, .has_hotplug = 1, \ |
250 | .ring_mask = RENDER_RING | BSD_RING | BLT_RING, \ | 254 | .ring_mask = RENDER_RING | BSD_RING | BLT_RING, \ |
251 | .display_mmio_offset = VLV_DISPLAY_BASE, \ | 255 | .display_mmio_offset = VLV_DISPLAY_BASE, \ |
@@ -304,6 +308,7 @@ static const struct intel_device_info intel_cherryview_info = { | |||
304 | .has_gmbus_irq = 1, | 308 | .has_gmbus_irq = 1, |
305 | .has_hw_contexts = 1, | 309 | .has_hw_contexts = 1, |
306 | .has_logical_ring_contexts = 1, | 310 | .has_logical_ring_contexts = 1, |
311 | .has_gmch_display = 1, | ||
307 | .display_mmio_offset = VLV_DISPLAY_BASE, | 312 | .display_mmio_offset = VLV_DISPLAY_BASE, |
308 | GEN_CHV_PIPEOFFSETS, | 313 | GEN_CHV_PIPEOFFSETS, |
309 | CURSOR_OFFSETS, | 314 | CURSOR_OFFSETS, |