From patchwork Tue Feb 23 15:00:19 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ramalingam C X-Patchwork-Id: 8393611 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id AFDC89F52D for ; Tue, 23 Feb 2016 15:08:44 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id C7E4020306 for ; Tue, 23 Feb 2016 15:08:43 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id D020020274 for ; Tue, 23 Feb 2016 15:08:42 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 2E08A6E5EB; Tue, 23 Feb 2016 15:08:42 +0000 (UTC) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by gabe.freedesktop.org (Postfix) with ESMTP id 5E3276E5EB for ; Tue, 23 Feb 2016 15:08:39 +0000 (UTC) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga101.jf.intel.com with ESMTP; 23 Feb 2016 07:08:30 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.22,489,1449561600"; d="scan'208";a="892742430" Received: from ramaling-desktop.iind.intel.com ([10.223.26.95]) by orsmga001.jf.intel.com with ESMTP; 23 Feb 2016 07:08:25 -0800 From: Ramalingam C To: intel-gfx@lists.freedesktop.org Date: Tue, 23 Feb 2016 20:30:19 +0530 Message-Id: <1456239619-14808-1-git-send-email-ramalingam.c@intel.com> X-Mailer: git-send-email 1.7.9.5 Cc: jani.nikula@intel.com, ville.syrjala@intel.com Subject: [Intel-gfx] [PATCH] drm/i915: Updating the CPU_TRANSCODER for BXT DSI X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP In case of BXT DSI we are updating the CPU_TRANSCODER with appropriate value. We are defining the POWER DOMAIN bits for the MIPI transcoders. V2: Adding the power domain bits and mapping them to the corresponding Powerwell. Signed-off-by: Ramalingam C Signed-off-by: Uma Shankar --- Previous review link: https://lists.freedesktop.org/archives/intel-gfx/2016-February/088304.html drivers/gpu/drm/i915/i915_drv.h | 4 ++++ drivers/gpu/drm/i915/intel_display.c | 5 +++++ drivers/gpu/drm/i915/intel_runtime_pm.c | 6 ++++++ 3 files changed, 15 insertions(+) diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h index 6644c2e..7c177e9 100644 --- a/drivers/gpu/drm/i915/i915_drv.h +++ b/drivers/gpu/drm/i915/i915_drv.h @@ -122,6 +122,8 @@ enum transcoder { TRANSCODER_B, TRANSCODER_C, TRANSCODER_EDP, + TRANSCODER_MIPI_A, + TRANSCODER_MIPI_C, I915_MAX_TRANSCODERS }; #define transcoder_name(t) ((t) + 'A') @@ -176,6 +178,8 @@ enum intel_display_power_domain { POWER_DOMAIN_TRANSCODER_B, POWER_DOMAIN_TRANSCODER_C, POWER_DOMAIN_TRANSCODER_EDP, + POWER_DOMAIN_TRANSCODER_MIPI_A, + POWER_DOMAIN_TRANSCODER_MIPI_C, POWER_DOMAIN_PORT_DDI_A_LANES, POWER_DOMAIN_PORT_DDI_B_LANES, POWER_DOMAIN_PORT_DDI_C_LANES, diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index 86ed9fd..961a968 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c @@ -7825,6 +7825,11 @@ static void intel_get_dsi_pipe_timings(struct intel_crtc *crtc, enc_to_intel_dsi(&encoder->base); pipe_config->pipe_bpp = dsi_pixel_format_bpp(intel_dsi->pixel_format); + + if (intel_dsi->ports & (1 << PORT_A)) + pipe_config->cpu_transcoder = TRANSCODER_MIPI_A; + else + pipe_config->cpu_transcoder = TRANSCODER_MIPI_C; } } diff --git a/drivers/gpu/drm/i915/intel_runtime_pm.c b/drivers/gpu/drm/i915/intel_runtime_pm.c index a2e367c..1ed3f5e 100644 --- a/drivers/gpu/drm/i915/intel_runtime_pm.c +++ b/drivers/gpu/drm/i915/intel_runtime_pm.c @@ -89,6 +89,10 @@ intel_display_power_domain_str(enum intel_display_power_domain domain) return "TRANSCODER_C"; case POWER_DOMAIN_TRANSCODER_EDP: return "TRANSCODER_EDP"; + case POWER_DOMAIN_TRANSCODER_MIPI_A: + return "TRANSCODER_MIPI_A"; + case POWER_DOMAIN_TRANSCODER_MIPI_C: + return "TRANSCODER_MIPI_C"; case POWER_DOMAIN_PORT_DDI_A_LANES: return "PORT_DDI_A_LANES"; case POWER_DOMAIN_PORT_DDI_B_LANES: @@ -403,6 +407,8 @@ static void hsw_set_power_well(struct drm_i915_private *dev_priv, BXT_DISPLAY_POWERWELL_2_POWER_DOMAINS | \ BIT(POWER_DOMAIN_PIPE_A) | \ BIT(POWER_DOMAIN_TRANSCODER_EDP) | \ + BIT(POWER_DOMAIN_TRANSCODER_MIPI_A) | \ + BIT(POWER_DOMAIN_TRANSCODER_MIPI_C) | \ BIT(POWER_DOMAIN_PIPE_A_PANEL_FITTER) | \ BIT(POWER_DOMAIN_PORT_DDI_A_LANES) | \ BIT(POWER_DOMAIN_AUX_A) | \