Message ID | 20200422141215.1548544-8-vicamo.yang@canonical.com |
---|---|
State | New |
Headers | show
Return-Path: <kernel-team-bounces@lists.ubuntu.com> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=<UNKNOWN>) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=canonical.com Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 496j7n0nJ7z9sSw; Thu, 23 Apr 2020 00:12:53 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from <kernel-team-bounces@lists.ubuntu.com>) id 1jRG7M-0002Bv-3p; Wed, 22 Apr 2020 14:12:48 +0000 Received: from mail-pj1-f65.google.com ([209.85.216.65]) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from <vicamo@gmail.com>) id 1jRG7D-00024Z-8I for kernel-team@lists.ubuntu.com; Wed, 22 Apr 2020 14:12:39 +0000 Received: by mail-pj1-f65.google.com with SMTP id a7so1023601pju.2 for <kernel-team@lists.ubuntu.com>; Wed, 22 Apr 2020 07:12:39 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=4Ymmo4DCqsHJR2jkV3hhaQpoXOxcVCHKCwF9kK15lAk=; b=J8jFwZDMpNwVWsYuQMl9nplI/vSlVKq2XrmtH0egeQfAX1/CFTj5MVmYIVC0+4gyPU 6s24TezqfjTdMYKVz12WRD4hSbfwkQR9a3HvI9JWacPCF3eh37XvOS0DAVUieKsUQrvj 3JTKHTr9xKof/mynrNIZWYBGqZfApfRPBGw3IPRJYQMpac88tK+vmvlAuF31mGfbPwtu EUDzbEwrtBIjFmejj8RKT6GTEewXv87nQWYqrMeAVgTzNpZzMPA5Cw9C8Ql8d8SdtUme U8R/DASBgs1BSqk5s64KR4wWyL3H8hIDIzwG2mQpIxJA6mWmyoc0nAl2Z5+fLQc/Co/f 7afA== X-Gm-Message-State: AGi0Pubm7aDSU4nfLUfu1N5GopCPc2FjRrnhxUMr7mmPuYYDdmFvp2QQ uV5wIRL1n2I8sbCBkJUHCRYtfus5pro= X-Google-Smtp-Source: APiQypI4GP9l9awKAVvCT+lBY5iBBb/SH2RfBgkn2WRQ6TakqkjrCH8TV5Iw7AcjcnUpwRQTMQtovg== X-Received: by 2002:a17:90a:23a3:: with SMTP id g32mr12244098pje.78.1587564756420; Wed, 22 Apr 2020 07:12:36 -0700 (PDT) Received: from localhost (61-220-137-37.HINET-IP.hinet.net. [61.220.137.37]) by smtp.gmail.com with ESMTPSA id x13sm5128979pgh.63.2020.04.22.07.12.35 for <kernel-team@lists.ubuntu.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Apr 2020 07:12:35 -0700 (PDT) From: You-Sheng Yang <vicamo.yang@canonical.com> To: kernel-team@lists.ubuntu.com Subject: [SRU][E][PATCH 07/52] drm/i915/icl: Add support to read out the TBT PLL HW state Date: Wed, 22 Apr 2020 22:11:30 +0800 Message-Id: <20200422141215.1548544-8-vicamo.yang@canonical.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200422141215.1548544-1-vicamo.yang@canonical.com> References: <20200422141215.1548544-1-vicamo.yang@canonical.com> MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions <kernel-team.lists.ubuntu.com> List-Unsubscribe: <https://lists.ubuntu.com/mailman/options/kernel-team>, <mailto:kernel-team-request@lists.ubuntu.com?subject=unsubscribe> List-Archive: <https://lists.ubuntu.com/archives/kernel-team> List-Post: <mailto:kernel-team@lists.ubuntu.com> List-Help: <mailto:kernel-team-request@lists.ubuntu.com?subject=help> List-Subscribe: <https://lists.ubuntu.com/mailman/listinfo/kernel-team>, <mailto:kernel-team-request@lists.ubuntu.com?subject=subscribe> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" <kernel-team-bounces@lists.ubuntu.com> |
Series |
Fix TC port in legacy/static mode can't be detected due TCCOLD
|
expand
|
diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c index a7c08dc9409d..6b56345d199c 100644 --- a/drivers/gpu/drm/i915/display/intel_display.c +++ b/drivers/gpu/drm/i915/display/intel_display.c @@ -9949,13 +9949,20 @@ static void icelake_get_ddi_pll(struct drm_i915_private *dev_priv, enum intel_dpll_id id; u32 temp; - /* TODO: TBT pll not implemented. */ if (intel_port_is_combophy(dev_priv, port)) { temp = I915_READ(DPCLKA_CFGCR0_ICL) & DPCLKA_CFGCR0_DDI_CLK_SEL_MASK(port); id = temp >> DPCLKA_CFGCR0_DDI_CLK_SEL_SHIFT(port); } else if (intel_port_is_tc(dev_priv, port)) { - id = icl_tc_port_to_pll_id(intel_port_to_tc(dev_priv, port)); + u32 clk_sel = I915_READ(DDI_CLK_SEL(port)) & DDI_CLK_SEL_MASK; + + if (clk_sel == DDI_CLK_SEL_MG) { + id = icl_tc_port_to_pll_id(intel_port_to_tc(dev_priv, + port)); + } else { + WARN_ON(clk_sel < DDI_CLK_SEL_TBT_162); + id = DPLL_ID_ICL_TBTPLL; + } } else { WARN(1, "Invalid port %x\n", port); return;