Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp2239968pxb; Thu, 11 Feb 2021 07:43:09 -0800 (PST) X-Google-Smtp-Source: ABdhPJw/lcNOJnf6duuNO1azEnoU++Y/WwpHOdOK170QYL6MXsIMBDnXkQOtZyiTFNTV5CTjkJCD X-Received: by 2002:a17:907:d86:: with SMTP id go6mr8708820ejc.337.1613058189703; Thu, 11 Feb 2021 07:43:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1613058189; cv=none; d=google.com; s=arc-20160816; b=NOQmtkZQskBzlK6F88DWB+6cLBGje88p+cC4PNNIINQ/w0HgOqzto39T6N4zHDjJ0M Cp7bJN5pACtNBhMaa5ivD9OLoFDP9ZMkzpukl1MOCyc8R3ZiE++Up6ydmvuVBjvPk5+p C+4rog+Wr0uUfEfKAYTsiCXOz3G+fdv3o65UXGr2yrZDZr3N30/QhZYWGLN3h+AafEqv dE9avrP9BqOwePvj6JIANuhibrYyHea0Lgps/byA7DIrfIHlB32w9BRL6VtRZ6bL6soK pCuBaTpEXAFXa7dhb7UDPLdGrc2PqBIp8gzcDF1Jqw97hs5B6aIg1LsGTQzWW1oC7FZg N0hA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=yAbS9l+s28dEatQ02TlCOK/d4zAI+JZws4W6nHwSncc=; b=DnV2Pz/Tr+5/EuHWW7MIlspIGY5tpsHxRQLNfTUKqyHzPRdKD5ptuJO51mCYOHZ6oE 7VzAaN7qeCXmagS14fDc3acGi83PYWbLETxlLzrySkGV0P4XzzGSt5WrpVNHbInqpor+ sccJ4pwMOb2Dr/G+zBFAUJouqcWnkhqeuwRfNOuONubdBgWT4uicU0UMfginHbwxOMSw ewY8ue/Ly9tUcRFVtamNF+wXhlSmYPKo8r6v+XB+Vd4XKPlb2s1nrOINoBga0mRo/yC2 CHsrc0o1gJNMhRYfBRlIUvt9cROmDzCHKIo2saxIv/B+CF2T1sVxQgVF+qK0OQrBOZha /dWg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=tEbSjnI+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y11si4000183edr.575.2021.02.11.07.42.32; Thu, 11 Feb 2021 07:43:09 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=tEbSjnI+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231314AbhBKPlG (ORCPT + 99 others); Thu, 11 Feb 2021 10:41:06 -0500 Received: from mail.kernel.org ([198.145.29.99]:51712 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229908AbhBKPNT (ORCPT ); Thu, 11 Feb 2021 10:13:19 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 7D83E64EF6; Thu, 11 Feb 2021 15:04:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1613055890; bh=tgG5ZuzJMSSY7xXkHOE2YZTZXgxpiFihf6Aiob7jUp8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=tEbSjnI+kaZklhLbd6CVL71mEXXufU7mgnhZsxDPKDl0QQlvZ8EvobTYKVt+wo/Q7 bdGrVduZPL0sIRqBRVuqRy0xjr9DCRRj8bzH2HL1h7ywd7cn0pb2iS7Dv3GMdcugNX L4QKxAu5V/0zb8mUbEazHtgjbRnO/9SgUXI0/gvc= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, =?UTF-8?q?Ville=20Syrj=C3=A4l=C3=A4?= , Imre Deak , Jani Nikula Subject: [PATCH 5.10 48/54] drm/i915: Skip vswing programming for TBT Date: Thu, 11 Feb 2021 16:02:32 +0100 Message-Id: <20210211150154.962908516@linuxfoundation.org> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210211150152.885701259@linuxfoundation.org> References: <20210211150152.885701259@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Ville Syrjälä commit eaf5bfe37db871031232d2bf2535b6ca92afbad8 upstream. In thunderbolt mode the PHY is owned by the thunderbolt controller. We are not supposed to touch it. So skip the vswing programming as well (we already skipped the other steps not applicable to TBT). Touching this stuff could supposedly interfere with the PHY programming done by the thunderbolt controller. Cc: stable@vger.kernel.org Signed-off-by: Ville Syrjälä Link: https://patchwork.freedesktop.org/patch/msgid/20210128155948.13678-1-ville.syrjala@linux.intel.com Reviewed-by: Imre Deak (cherry picked from commit f8c6b615b921d8a1bcd74870f9105e62b0bceff3) Signed-off-by: Jani Nikula Signed-off-by: Greg Kroah-Hartman --- drivers/gpu/drm/i915/display/intel_ddi.c | 6 ++++++ 1 file changed, 6 insertions(+) --- a/drivers/gpu/drm/i915/display/intel_ddi.c +++ b/drivers/gpu/drm/i915/display/intel_ddi.c @@ -2597,6 +2597,9 @@ static void icl_mg_phy_ddi_vswing_sequen u32 n_entries, val; int ln, rate = 0; + if (enc_to_dig_port(encoder)->tc_mode == TC_PORT_TBT_ALT) + return; + if (type != INTEL_OUTPUT_HDMI) { struct intel_dp *intel_dp = enc_to_intel_dp(encoder); @@ -2741,6 +2744,9 @@ tgl_dkl_phy_ddi_vswing_sequence(struct i u32 n_entries, val, ln, dpcnt_mask, dpcnt_val; int rate = 0; + if (enc_to_dig_port(encoder)->tc_mode == TC_PORT_TBT_ALT) + return; + if (type != INTEL_OUTPUT_HDMI) { struct intel_dp *intel_dp = enc_to_intel_dp(encoder);