Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp3696909imu; Mon, 28 Jan 2019 09:12:48 -0800 (PST) X-Google-Smtp-Source: ALg8bN4hVj0D0uslSeXY5GbTpfsak4ZiWqcLDZZA0mhqjJz5FPQrMl2CnH7lDSwgiOapKcHmcBGl X-Received: by 2002:a62:3adc:: with SMTP id v89mr22263689pfj.109.1548695568066; Mon, 28 Jan 2019 09:12:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548695568; cv=none; d=google.com; s=arc-20160816; b=aVMnymMj7rg51sfxwkyif54S0qEw95CIhDLezk7V3mbi/0nwju9RXulFca4YHGIyXm 8IQCZLwfasmDKajcnX2GWvS2HUrkWppvNRWOssKBWezT8Zfuwf4PXswPM7grI82T0/Bt J/Ehdoqk9S0dz9v6KDnTOtp3I5wMqdffySo3iV5P+pfLV7Dl2FYsoPkcJn+7IQQErGw7 AAzt+PCGIDm98Gyyij2fUK0jYLMc315UNhdOPvIZY7wWYzuJ4MRrcAOgk2XY1eVBxEqT bc5ySfQGdolXJFyLxYlEF6aAbdKq72C4ycuZDjMvoTBnX83jZjwFGXCugM6Z9u4xz//7 yEYA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=KnzkHJVK/XbVguzHLXBM5G9fcEytgq6kGllxwQJvCGo=; b=VyTGCpYO/2suSFRZ7Rf1e6u53EfcyvRd9uEsjqzxOwQ4PilUNkPcgnA25SXRmE6ZsM ZTKMjx45JNw016n0Hf4FSU8ojFCpRvsOLuVVBmZyzwnAnlE6+27/buiOcRIPgw6Q2MmE kLiTWbjOYkA49v0tZnowYKurTpq3aRO8RNNvqMdhRREeH27+Yzq6i10A2IG+SRs+LhVI ch004qdjHpwbzr5yDoT254BqoA1jqwUNhrTOfa+H2CIIWrQZCXa+ulc+g01Rccn1YpVZ 3Ot8nM7mmZv39MTG9/3p1iYyKk4o4Mi3XaV9NEUreKcwkZ7K1dMjnfl3Lwd3dSpe0qvF Rl1A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=YeYBLqLm; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 124si34197865pgg.397.2019.01.28.09.12.32; Mon, 28 Jan 2019 09:12:48 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=YeYBLqLm; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731895AbfA1QJH (ORCPT + 99 others); Mon, 28 Jan 2019 11:09:07 -0500 Received: from mail.kernel.org ([198.145.29.99]:33274 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732536AbfA1QJE (ORCPT ); Mon, 28 Jan 2019 11:09:04 -0500 Received: from sasha-vm.mshome.net (c-73-47-72-35.hsd1.nh.comcast.net [73.47.72.35]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 4F4F12084A; Mon, 28 Jan 2019 16:09:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1548691743; bh=s94euxNWC6HlDDQgcnJrIZwNuaOfdkLMdIHtf3K5oOY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=YeYBLqLm9TnIdCqJd+FE6SsVGwXO9MHiWTl2LrqYsWI1yKxkuLww66NPrSAjLL/SC KgkhQ0GB2ELR3UyDoIrEHwELe2/uHdggdHuU8F0JG1SHmGA7lAZTZD6Ezlys0QdL/Z 9bIEyDBCfIhbJTeepJ9lnEz8rXkTTP1BBostBQgc= From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Wenjing Liu , Alex Deucher , Sasha Levin , amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org Subject: [PATCH AUTOSEL 4.19 203/258] drm/amd/display: validate extended dongle caps Date: Mon, 28 Jan 2019 10:58:29 -0500 Message-Id: <20190128155924.51521-203-sashal@kernel.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190128155924.51521-1-sashal@kernel.org> References: <20190128155924.51521-1-sashal@kernel.org> MIME-Version: 1.0 X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Wenjing Liu [ Upstream commit 99b922f9ed6a6313c0d2247cde8aa1e4a0bd67e4 ] [why] Some dongle doesn't have a valid extended dongle caps, but we still set the extended dongle caps to be valid. This causes validation fails for all timing. [how] If no dp_hdmi_max_pixel_clk is provided, don't use extended dongle caps. Signed-off-by: Wenjing Liu Reviewed-by: Aric Cyr Reviewed-by: Jun Lei Acked-by: Abdoulaye Berthe Acked-by: Leo Li Signed-off-by: Alex Deucher Signed-off-by: Sasha Levin --- drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c b/drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c index a7553b6d59c2..05840f5bddd5 100644 --- a/drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c +++ b/drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c @@ -2240,7 +2240,8 @@ static void get_active_converter_info( translate_dpcd_max_bpc( hdmi_color_caps.bits.MAX_BITS_PER_COLOR_COMPONENT); - link->dpcd_caps.dongle_caps.extendedCapValid = true; + if (link->dpcd_caps.dongle_caps.dp_hdmi_max_pixel_clk != 0) + link->dpcd_caps.dongle_caps.extendedCapValid = true; } break; -- 2.19.1