aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/intel_dsi.c
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2014-07-08 20:38:42 -0400
committerDave Airlie <airlied@redhat.com>2014-07-08 20:38:42 -0400
commitca5a1b9ba0fb5291b555a23b76dbe5f6c30bfd7a (patch)
tree9a012a2a610ad4e9500c8e4f0aa68ecdc23c4dba /drivers/gpu/drm/i915/intel_dsi.c
parentc7dbc6c9ae5c3baa3be755a228a349374d043b5b (diff)
parent34882298b93e998d5fccde852b860e8fbe6c8f6b (diff)
Merge tag 'drm-intel-next-2014-06-20' of git://anongit.freedesktop.org/drm-intel into drm-next
- Accurate frontbuffer tracking and frontbuffer rendering invalidate, flush and flip events. This is prep work for proper PSR support and should also be useful for DRRS&fbc. - Runtime suspend hardware on system suspend to support the new SOix sleep states, from Jesse. - PSR updates for broadwell (Rodrigo) - Universal plane support for cursors (Matt Roper), including core drm patches. - Prefault gtt mappings (Chris) - baytrail write-enable pte bit support (Akash Goel) - mmio based flips (Sourab Gupta) instead of blitter ring flips - interrupt handling race fixes (Oscar Mateo) And old, not yet merged features from the previous round: - rps/turbo support for chv (Deepak) - some other straggling chv patches (Ville) - proper universal plane conversion for the primary plane (Matt Roper) - ppgtt on vlv from Jesse - pile of cleanups, little fixes for insane corner cases and improved debug support all over * tag 'drm-intel-next-2014-06-20' of git://anongit.freedesktop.org/drm-intel: (99 commits) drm/i915: Update DRIVER_DATE to 20140620 drivers/i915: Fix unnoticed failure of init_ring_common() drm/i915: Track frontbuffer invalidation/flushing drm/i915: Use new frontbuffer bits to increase pll clock drm/i915: don't take runtime PM reference around freeze/thaw drm/i915: use runtime irq suspend/resume in freeze/thaw drm/i915: Properly track domain of the fbcon fb drm/i915: Print obj->frontbuffer_bits in debugfs output drm/i915: Introduce accurate frontbuffer tracking drm/i915: Drop schedule_back from psr_exit drm/i915: Ditch intel_edp_psr_update drm/i915: Drop unecessary complexity from psr_inactivate drm/i915: Remove ctx->last_ring drm/i915/chv: Ack interrupts before handling them (CHV) drm/i915/bdw: Ack interrupts before handling them (GEN8) drm/i915/vlv: Ack interrupts before handling them (VLV) drm/i915: Ack interrupts before handling them (GEN5 - GEN7) drm/i915: Don't BUG_ON in i915_gem_obj_offset drm/i915: Grab dev->struct_mutex in i915_gem_pageflip_info drm/i915: Add some L3 registers to the parser whitelist ... Conflicts: drivers/gpu/drm/i915/i915_drv.c
Diffstat (limited to 'drivers/gpu/drm/i915/intel_dsi.c')
-rw-r--r--drivers/gpu/drm/i915/intel_dsi.c26
1 files changed, 12 insertions, 14 deletions
diff --git a/drivers/gpu/drm/i915/intel_dsi.c b/drivers/gpu/drm/i915/intel_dsi.c
index 7c07ee07a8ee..2ee1722c0af4 100644
--- a/drivers/gpu/drm/i915/intel_dsi.c
+++ b/drivers/gpu/drm/i915/intel_dsi.c
@@ -657,7 +657,7 @@ static const struct drm_connector_funcs intel_dsi_connector_funcs = {
657 .fill_modes = drm_helper_probe_single_connector_modes, 657 .fill_modes = drm_helper_probe_single_connector_modes,
658}; 658};
659 659
660bool intel_dsi_init(struct drm_device *dev) 660void intel_dsi_init(struct drm_device *dev)
661{ 661{
662 struct intel_dsi *intel_dsi; 662 struct intel_dsi *intel_dsi;
663 struct intel_encoder *intel_encoder; 663 struct intel_encoder *intel_encoder;
@@ -673,29 +673,29 @@ bool intel_dsi_init(struct drm_device *dev)
673 673
674 /* There is no detection method for MIPI so rely on VBT */ 674 /* There is no detection method for MIPI so rely on VBT */
675 if (!dev_priv->vbt.has_mipi) 675 if (!dev_priv->vbt.has_mipi)
676 return false; 676 return;
677
678 if (IS_VALLEYVIEW(dev)) {
679 dev_priv->mipi_mmio_base = VLV_MIPI_BASE;
680 } else {
681 DRM_ERROR("Unsupported Mipi device to reg base");
682 return;
683 }
677 684
678 intel_dsi = kzalloc(sizeof(*intel_dsi), GFP_KERNEL); 685 intel_dsi = kzalloc(sizeof(*intel_dsi), GFP_KERNEL);
679 if (!intel_dsi) 686 if (!intel_dsi)
680 return false; 687 return;
681 688
682 intel_connector = kzalloc(sizeof(*intel_connector), GFP_KERNEL); 689 intel_connector = kzalloc(sizeof(*intel_connector), GFP_KERNEL);
683 if (!intel_connector) { 690 if (!intel_connector) {
684 kfree(intel_dsi); 691 kfree(intel_dsi);
685 return false; 692 return;
686 } 693 }
687 694
688 intel_encoder = &intel_dsi->base; 695 intel_encoder = &intel_dsi->base;
689 encoder = &intel_encoder->base; 696 encoder = &intel_encoder->base;
690 intel_dsi->attached_connector = intel_connector; 697 intel_dsi->attached_connector = intel_connector;
691 698
692 if (IS_VALLEYVIEW(dev)) {
693 dev_priv->mipi_mmio_base = VLV_MIPI_BASE;
694 } else {
695 DRM_ERROR("Unsupported Mipi device to reg base");
696 return false;
697 }
698
699 connector = &intel_connector->base; 699 connector = &intel_connector->base;
700 700
701 drm_encoder_init(dev, encoder, &intel_dsi_funcs, DRM_MODE_ENCODER_DSI); 701 drm_encoder_init(dev, encoder, &intel_dsi_funcs, DRM_MODE_ENCODER_DSI);
@@ -753,12 +753,10 @@ bool intel_dsi_init(struct drm_device *dev)
753 fixed_mode->type |= DRM_MODE_TYPE_PREFERRED; 753 fixed_mode->type |= DRM_MODE_TYPE_PREFERRED;
754 intel_panel_init(&intel_connector->panel, fixed_mode, NULL); 754 intel_panel_init(&intel_connector->panel, fixed_mode, NULL);
755 755
756 return true; 756 return;
757 757
758err: 758err:
759 drm_encoder_cleanup(&intel_encoder->base); 759 drm_encoder_cleanup(&intel_encoder->base);
760 kfree(intel_dsi); 760 kfree(intel_dsi);
761 kfree(intel_connector); 761 kfree(intel_connector);
762
763 return false;
764} 762}