From patchwork Wed Mar 4 10:40:46 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 11419813 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 1FBCD921 for ; Wed, 4 Mar 2020 10:41:13 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id F266D2072D for ; Wed, 4 Mar 2020 10:41:12 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=baylibre-com.20150623.gappssmtp.com header.i=@baylibre-com.20150623.gappssmtp.com header.b="mx3iwudl" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org F266D2072D Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0E5266E136; Wed, 4 Mar 2020 10:41:06 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wr1-x441.google.com (mail-wr1-x441.google.com [IPv6:2a00:1450:4864:20::441]) by gabe.freedesktop.org (Postfix) with ESMTPS id 97ADF6E136 for ; Wed, 4 Mar 2020 10:41:05 +0000 (UTC) Received: by mail-wr1-x441.google.com with SMTP id q8so1763434wrm.4 for ; Wed, 04 Mar 2020 02:41:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=zBV+Mcykh4jSy5LpMQRzAqt2z+ZaR095g4MjbXShAoU=; b=mx3iwudlVrvCSNzwqeOyAiR9iitVlgrIa99spLuUe7EBWEDzGsbfPJwUu/KChoErXv h+x7mYH4pOYQK/gcuqO2/KiRhpkfhw4SqJ+ijRydXIHTihh3jCfnuwVFvE7/bBsRpjSo YBHe8jApAPWuwbuR3E6ulkOBVLLeYNlIb8z2sfscv+9NWVBDWb1jw1FEGVbfaZdb3S2G SqE3edSCmjs3PY4oDy47OO6WbgnP7lbPYdcRzSmj6RbirUvScmGhMBpnIZh++HUN1Igk AQmQx91AAzSSK13TZy1OAfbzdS5FaHA0ymybCPHhkIPN9URKH7R/mvUd1wqOfe8t2Fs2 GFEg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=zBV+Mcykh4jSy5LpMQRzAqt2z+ZaR095g4MjbXShAoU=; b=jiaj8WkFs49z0KIrEamlXVWiTxZp+gk6HDEOr6hiXz8Hlx6KrhZY2nvaDBZA17X7e4 E3MXHjYdmdSaCnNF8sUBmClsLSTBpxUHqIY38Pf9U49V6IMBgmWm5NzNJMMK5bCsRLOj AV3Vi0QtFMySZPok4/1eApHDo3+BqmtmOsYbmxGf5AIuyeGxAGAOI9MpVfIYMYOcABez D7wIjet6APbUMo8mtgXjdDxQurxnYebKH4IBLOmPiXjTDIPKhWf0PnnP0s6dn9GB+nCH DBekE80iU3f5cv0HxHqHIu+EjUE7Hipr0tZsjEYxPFi0N7Wl1HJjs+QIq8D4yTWpXLs7 wl6A== X-Gm-Message-State: ANhLgQ2knhvPWhG4cdh817I4F74H8s2RqFtN+OPPjLSpQ1rNNH/FoZqi 2Cs8DQSV8tp43GKLxz2W/kblhg== X-Google-Smtp-Source: ADFU+vsAiBhy5hUXNqkS6IUhDPu3/5igsqNw0fPqWtjcAmSwSaZaQwxoNYwzPB6lgmNIuSlWEmlnGA== X-Received: by 2002:adf:e74e:: with SMTP id c14mr3643854wrn.128.1583318464154; Wed, 04 Mar 2020 02:41:04 -0800 (PST) Received: from bender.baylibre.local (laubervilliers-658-1-213-31.w90-63.abo.wanadoo.fr. [90.63.244.31]) by smtp.gmail.com with ESMTPSA id c14sm24006398wro.36.2020.03.04.02.41.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 04 Mar 2020 02:41:03 -0800 (PST) From: Neil Armstrong To: p.zabel@pengutronix.de, heiko@sntech.de, a.hajda@samsung.com, Laurent.pinchart@ideasonboard.com, jonas@kwiboo.se, jernej.skrabec@siol.net, boris.brezillon@collabora.com Subject: [PATCH v5 05/11] drm/bridge: synopsys: dw-hdmi: allow ycbcr420 modes for >= 0x200a Date: Wed, 4 Mar 2020 11:40:46 +0100 Message-Id: <20200304104052.17196-6-narmstrong@baylibre.com> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20200304104052.17196-1-narmstrong@baylibre.com> References: <20200304104052.17196-1-narmstrong@baylibre.com> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-amlogic@lists.infradead.org, Laurent Pinchart , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Neil Armstrong Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Now the DW-HDMI Controller supports the HDMI2.0 modes, enable support for these modes in the connector if the platform supports them. We limit these modes to DW-HDMI IP version >= 0x200a which are designed to support HDMI2.0 display modes. Signed-off-by: Neil Armstrong Reviewed-by: Andrzej Hajda Reviewed-by: Laurent Pinchart Reviewed-by: Jernej Škrabec --- drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 6 ++++++ include/drm/bridge/dw_hdmi.h | 1 + 2 files changed, 7 insertions(+) diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c index de19e8993e1d..f85c15ad8486 100644 --- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c +++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c @@ -3252,6 +3252,12 @@ __dw_hdmi_probe(struct platform_device *pdev, hdmi->bridge.of_node = pdev->dev.of_node; #endif + if (hdmi->version >= 0x200a) + hdmi->connector.ycbcr_420_allowed = + hdmi->plat_data->ycbcr_420_allowed; + else + hdmi->connector.ycbcr_420_allowed = false; + memset(&pdevinfo, 0, sizeof(pdevinfo)); pdevinfo.parent = dev; pdevinfo.id = PLATFORM_DEVID_AUTO; diff --git a/include/drm/bridge/dw_hdmi.h b/include/drm/bridge/dw_hdmi.h index 9d4d5cc47969..0b34a12c4a1c 100644 --- a/include/drm/bridge/dw_hdmi.h +++ b/include/drm/bridge/dw_hdmi.h @@ -129,6 +129,7 @@ struct dw_hdmi_plat_data { unsigned long input_bus_format; unsigned long input_bus_encoding; bool use_drm_infoframe; + bool ycbcr_420_allowed; /* Vendor PHY support */ const struct dw_hdmi_phy_ops *phy_ops;