diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-11-15 00:19:54 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-11-15 00:19:54 -0500 |
commit | 049ffa8ab33a63b3bff672d1a0ee6a35ad253fe8 (patch) | |
tree | 70f4c684818b1c9871fa800088427e40d260592e /drivers/gpu/drm/i915/intel_crt.c | |
parent | c681427e5ca22925fcc1be76a2e260a11e0a8498 (diff) | |
parent | 0846c728e20a0cd1e43fb75a3015f3b176a26466 (diff) |
Merge branch 'drm-next' of git://people.freedesktop.org/~airlied/linux
Pull drm updates from Dave Airlie:
"This is a combo of -next and some -fixes that came in in the
intervening time.
Highlights:
New drivers:
ARM Armada driver for Marvell Armada 510 SOCs
Intel:
Broadwell initial support under a default off switch,
Stereo/3D HDMI mode support
Valleyview improvements
Displayport improvements
Haswell fixes
initial mipi dsi panel support
CRC support for debugging
build with CONFIG_FB=n
Radeon:
enable DPM on a number of GPUs by default
secondary GPU powerdown support
enable HDMI audio by default
Hawaii support
Nouveau:
dynamic pm code infrastructure reworked, does nothing major yet
GK208 modesetting support
MSI fixes, on by default again
PMPEG improvements
pageflipping fixes
GMA500:
minnowboard SDVO support
VMware:
misc fixes
MSM:
prime, plane and rendernodes support
Tegra:
rearchitected to put the drm driver into the drm subsystem.
HDMI and gr2d support for tegra 114 SoC
QXL:
oops fix, and multi-head fixes
DRM core:
sysfs lifetime fixes
client capability ioctl
further cleanups to device midlayer
more vblank timestamp fixes"
* 'drm-next' of git://people.freedesktop.org/~airlied/linux: (789 commits)
drm/nouveau: do not map evicted vram buffers in nouveau_bo_vma_add
drm/nvc0-/gr: shift wrapping bug in nvc0_grctx_generate_r406800
drm/nouveau/pwr: fix missing mutex unlock in a failure path
drm/nv40/therm: fix slowing down fan when pstate undefined
drm/nv11-: synchronise flips to vblank, unless async flip requested
drm/nvc0-: remove nasty fifo swmthd hack for flip completion method
drm/nv10-: we no longer need to create nvsw object on user channels
drm/nouveau: always queue flips relative to kernel channel activity
drm/nouveau: there is no need to reserve/fence the new fb when flipping
drm/nouveau: when bailing out of a pushbuf ioctl, do not remove previous fence
drm/nouveau: allow nouveau_fence_ref() to be a noop
drm/nvc8/mc: msi rearm is via the nvc0 method
drm/ttm: Fix vma page_prot bit manipulation
drm/vmwgfx: Fix a couple of compile / sparse warnings and errors
drm/vmwgfx: Resource evict fixes
drm/edid: compare actual vrefresh for all modes for quirks
drm: shmob_drm: Convert to clk_prepare/unprepare
drm/nouveau: fix 32-bit build
drm/i915/opregion: fix build error on CONFIG_ACPI=n
Revert "drm/radeon/audio: don't set speaker allocation on DCE4+"
...
Diffstat (limited to 'drivers/gpu/drm/i915/intel_crt.c')
-rw-r--r-- | drivers/gpu/drm/i915/intel_crt.c | 29 |
1 files changed, 17 insertions, 12 deletions
diff --git a/drivers/gpu/drm/i915/intel_crt.c b/drivers/gpu/drm/i915/intel_crt.c index 10d1de5bce6f..b5b1b9b23adf 100644 --- a/drivers/gpu/drm/i915/intel_crt.c +++ b/drivers/gpu/drm/i915/intel_crt.c | |||
@@ -107,7 +107,17 @@ static unsigned int intel_crt_get_flags(struct intel_encoder *encoder) | |||
107 | static void intel_crt_get_config(struct intel_encoder *encoder, | 107 | static void intel_crt_get_config(struct intel_encoder *encoder, |
108 | struct intel_crtc_config *pipe_config) | 108 | struct intel_crtc_config *pipe_config) |
109 | { | 109 | { |
110 | struct drm_device *dev = encoder->base.dev; | ||
111 | int dotclock; | ||
112 | |||
110 | pipe_config->adjusted_mode.flags |= intel_crt_get_flags(encoder); | 113 | pipe_config->adjusted_mode.flags |= intel_crt_get_flags(encoder); |
114 | |||
115 | dotclock = pipe_config->port_clock; | ||
116 | |||
117 | if (HAS_PCH_SPLIT(dev)) | ||
118 | ironlake_check_encoder_dotclock(pipe_config, dotclock); | ||
119 | |||
120 | pipe_config->adjusted_mode.crtc_clock = dotclock; | ||
111 | } | 121 | } |
112 | 122 | ||
113 | static void hsw_crt_get_config(struct intel_encoder *encoder, | 123 | static void hsw_crt_get_config(struct intel_encoder *encoder, |
@@ -264,7 +274,7 @@ static void intel_crt_mode_set(struct intel_encoder *encoder) | |||
264 | struct drm_display_mode *adjusted_mode = &crtc->config.adjusted_mode; | 274 | struct drm_display_mode *adjusted_mode = &crtc->config.adjusted_mode; |
265 | u32 adpa; | 275 | u32 adpa; |
266 | 276 | ||
267 | if (HAS_PCH_SPLIT(dev)) | 277 | if (INTEL_INFO(dev)->gen >= 5) |
268 | adpa = ADPA_HOTPLUG_BITS; | 278 | adpa = ADPA_HOTPLUG_BITS; |
269 | else | 279 | else |
270 | adpa = 0; | 280 | adpa = 0; |
@@ -366,9 +376,6 @@ static bool valleyview_crt_detect_hotplug(struct drm_connector *connector) | |||
366 | 376 | ||
367 | DRM_DEBUG_KMS("valleyview hotplug adpa=0x%x, result %d\n", adpa, ret); | 377 | DRM_DEBUG_KMS("valleyview hotplug adpa=0x%x, result %d\n", adpa, ret); |
368 | 378 | ||
369 | /* FIXME: debug force function and remove */ | ||
370 | ret = true; | ||
371 | |||
372 | return ret; | 379 | return ret; |
373 | } | 380 | } |
374 | 381 | ||
@@ -670,7 +677,6 @@ intel_crt_detect(struct drm_connector *connector, bool force) | |||
670 | 677 | ||
671 | static void intel_crt_destroy(struct drm_connector *connector) | 678 | static void intel_crt_destroy(struct drm_connector *connector) |
672 | { | 679 | { |
673 | drm_sysfs_connector_remove(connector); | ||
674 | drm_connector_cleanup(connector); | 680 | drm_connector_cleanup(connector); |
675 | kfree(connector); | 681 | kfree(connector); |
676 | } | 682 | } |
@@ -776,7 +782,7 @@ void intel_crt_init(struct drm_device *dev) | |||
776 | if (!crt) | 782 | if (!crt) |
777 | return; | 783 | return; |
778 | 784 | ||
779 | intel_connector = kzalloc(sizeof(struct intel_connector), GFP_KERNEL); | 785 | intel_connector = kzalloc(sizeof(*intel_connector), GFP_KERNEL); |
780 | if (!intel_connector) { | 786 | if (!intel_connector) { |
781 | kfree(crt); | 787 | kfree(crt); |
782 | return; | 788 | return; |
@@ -816,16 +822,15 @@ void intel_crt_init(struct drm_device *dev) | |||
816 | crt->base.mode_set = intel_crt_mode_set; | 822 | crt->base.mode_set = intel_crt_mode_set; |
817 | crt->base.disable = intel_disable_crt; | 823 | crt->base.disable = intel_disable_crt; |
818 | crt->base.enable = intel_enable_crt; | 824 | crt->base.enable = intel_enable_crt; |
819 | if (IS_HASWELL(dev)) | ||
820 | crt->base.get_config = hsw_crt_get_config; | ||
821 | else | ||
822 | crt->base.get_config = intel_crt_get_config; | ||
823 | if (I915_HAS_HOTPLUG(dev)) | 825 | if (I915_HAS_HOTPLUG(dev)) |
824 | crt->base.hpd_pin = HPD_CRT; | 826 | crt->base.hpd_pin = HPD_CRT; |
825 | if (HAS_DDI(dev)) | 827 | if (HAS_DDI(dev)) { |
828 | crt->base.get_config = hsw_crt_get_config; | ||
826 | crt->base.get_hw_state = intel_ddi_get_hw_state; | 829 | crt->base.get_hw_state = intel_ddi_get_hw_state; |
827 | else | 830 | } else { |
831 | crt->base.get_config = intel_crt_get_config; | ||
828 | crt->base.get_hw_state = intel_crt_get_hw_state; | 832 | crt->base.get_hw_state = intel_crt_get_hw_state; |
833 | } | ||
829 | intel_connector->get_hw_state = intel_connector_get_hw_state; | 834 | intel_connector->get_hw_state = intel_connector_get_hw_state; |
830 | 835 | ||
831 | drm_connector_helper_add(connector, &intel_crt_connector_helper_funcs); | 836 | drm_connector_helper_add(connector, &intel_crt_connector_helper_funcs); |