From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 72734C433F5 for ; Tue, 1 Mar 2022 20:37:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237863AbiCAUi0 (ORCPT ); Tue, 1 Mar 2022 15:38:26 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55350 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234838AbiCAUiY (ORCPT ); Tue, 1 Mar 2022 15:38:24 -0500 Received: from mo4-p01-ob.smtp.rzone.de (mo4-p01-ob.smtp.rzone.de [85.215.255.52]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0067D29CB7; Tue, 1 Mar 2022 12:37:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1646167042; s=strato-dkim-0002; d=goldelico.com; h=To:References:Message-Id:Cc:Date:In-Reply-To:From:Subject:Cc:Date: From:Subject:Sender; bh=enUl4JsrLhrG2ZRTNPwk0f5xsufFIJ2pEEMEeqkBDQY=; b=qoaCbST4XMW18rHVYihdg0wovg73mOulySTYQqkRjiopnvLmPoosis+1Gg3HSdtCcA S1cwieVNCzK1I2O+vs9H4QScr74kBvXTWkbfZrMAa0zFNKh2PPfljv/ae2OFgpUPpTog svrIoTxdE3OvmtmTk+1Jf+4VT0CaKaS6nhsHuhExtVKoR2bYp0zXRmUU9mrOrVYpX/og QVk0mKsf5kTJrg9GN+W+Yz50jczFb+tGQf/qp7ikjbzSE7tXP5yoGoYiQpDP0vqmR3d/ 5QzM+vMh4xr0Vv05psmycwKdbwr5hqkjkyupeXerkL/zVAHLNPxHLPLY4CFOdlUkahSK OKCg== Authentication-Results: strato.com; dkim=none X-RZG-AUTH: ":JGIXVUS7cutRB/49FwqZ7WcJeFKiMgPgp8VKxflSZ1P34KBj4Qpw9iZeHWElw47sdXM=" X-RZG-CLASS-ID: mo00 Received: from imac.fritz.box by smtp.strato.de (RZmta 47.40.1 DYNA|AUTH) with ESMTPSA id V41e6fy21KbKQst (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (curve X9_62_prime256v1 with 256 ECDH bits, eq. 3072 bits RSA)) (Client did not present a certificate); Tue, 1 Mar 2022 21:37:20 +0100 (CET) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.21\)) Subject: Re: [PATCH v16 4/4] drm/bridge: dw-hdmi: fix bus formats negotiation for 8 bit modes From: "H. Nikolaus Schaller" In-Reply-To: <5da069b6-8a99-79c2-109c-c85715165857@baylibre.com> Date: Tue, 1 Mar 2022 21:37:20 +0100 Cc: Andrzej Hajda , Robert Foss , Paul Boddie , Laurent Pinchart , Jernej Skrabec , David Airlie , Daniel Vetter , Paul Cercueil , Maxime Ripard , Kieran Bingham , Discussions about the Letux Kernel , linux-mips , linux-kernel , dri-devel , Jonas Karlman Content-Transfer-Encoding: quoted-printable Message-Id: References: <169afe64b4985c3f420177cd6f4e1e72feeb2449.1645895582.git.hns@goldelico.com> <5da069b6-8a99-79c2-109c-c85715165857@baylibre.com> To: Neil Armstrong X-Mailer: Apple Mail (2.3445.104.21) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Neil, > Am 01.03.2022 um 10:18 schrieb Neil Armstrong = : >=20 > Hi, >=20 > On 26/02/2022 18:13, H. Nikolaus Schaller wrote: >> Commit 7cd70656d1285b ("drm/bridge: display-connector: implement bus = fmts callbacks") >> introduced a new mechanism to negotiate bus formats between hdmi = connectors >> and bridges which is to be used e.g. for the jz4780 based CI20 board. >> In this case dw-hdmi sets up a list of formats in >> dw_hdmi_bridge_atomic_get_output_bus_fmts(). >> This includes e.g. MEDIA_BUS_FMT_UYVY8_1X16 which is chosen for the = CI20 but >> only produces a black screen. >> Analysis revealed an omission in >> Commit 6c3c719936dafe ("drm/bridge: synopsys: dw-hdmi: add bus format = negociation") >> to check for 8 bit with when adding UYVY8 or YUV8 formats. >> This fix is based on the observation that max_bpc =3D 0 when running = this >> function while info->bpc =3D 8. >=20 > In fact if bpc =3D 0, it should be considered as 8, so the issue is = elsewhere. >=20 >> Adding the proposed patch makes the jz4780/CI20 panel work again with = default >> MEDIA_BUS_FMT_RGB888_1X24 mode. >> Fixes: 7cd70656d1285b ("drm/bridge: display-connector: implement bus = fmts callbacks") >> Fixes: 6c3c719936dafe ("drm/bridge: synopsys: dw-hdmi: add bus format = negociation") >> Signed-off-by: H. Nikolaus Schaller >> --- >> drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 10 ++++++---- >> 1 file changed, 6 insertions(+), 4 deletions(-) >> diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c = b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c >> index 43e375da131e8..c08e2cc96584c 100644 >> --- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c >> +++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c >> @@ -2621,11 +2621,13 @@ static u32 = *dw_hdmi_bridge_atomic_get_output_bus_fmts(struct drm_bridge *bridge, >> output_fmts[i++] =3D MEDIA_BUS_FMT_RGB101010_1X30; >> } >> - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR422) >> - output_fmts[i++] =3D MEDIA_BUS_FMT_UYVY8_1X16; >> + if (max_bpc >=3D 8 && info->bpc >=3D 8) { >> + if (info->color_formats & DRM_COLOR_FORMAT_YCBCR422) >> + output_fmts[i++] =3D MEDIA_BUS_FMT_UYVY8_1X16; >> - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR444) >> - output_fmts[i++] =3D MEDIA_BUS_FMT_YUV8_1X24; >> + if (info->color_formats & DRM_COLOR_FORMAT_YCBCR444) >> + output_fmts[i++] =3D MEDIA_BUS_FMT_YUV8_1X24; >> + } >=20 > It should not select YUV here if it's not possible, so something is = wrong. >=20 > Can you check if = https://lore.kernel.org/r/20220119123656.1456355-2-narmstrong@baylibre.com= fixes this issue instead ? Well, I had to manually fix it to be appliable to drm-misc/drm-misc-next and specifically: c03d0b52ff71 ("drm/connector: Fix typo in output format") My resulting patch is attached. Unfortunately it did not work. I added a printk for hdmi->sink_is_hdmi. This returns 1. Which IMHO is = to be expected since I am using a HDMI connector and panel... So your patch will still = add the UYVY formats. Either the synposys module inside the jz4780 or the panel does not = understand them. Here is the EDID. Unfortunately it does not pretty print the extended = descriptors for UYVY etc. so that I don't know the exact capabilities of the panel. And what I am = not sure is if the jz4780 SoC can convert to UYVY or how it can. root@letux:~# parse-edid = sink_is_hdmi=3D1 So please let me know which parameters I should try to printk()... BR and thanks, Nikolaus ------ =46rom c84a3c4a500684e57b1243fe5386696c48fa1e1b Mon Sep 17 00:00:00 2001 From: Neil Armstrong Date: Wed, 19 Jan 2022 13:36:56 +0100 Subject: [PATCH] drm/bridge: dw-hdmi: filter out YUV output formats when = DVI When the display is not an HDMI sink, only the RGB output format is valid. Thus stop returning YUV output formats when sink is not HDMI. Fixes: 6c3c719936da ("drm/bridge: synopsys: dw-hdmi: add bus format = negociation") Signed-off-by: Neil Armstrong --- drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c = b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c index 43e375da131e8..0ec0cbe448e05 100644 --- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c +++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c @@ -2538,6 +2538,7 @@ static u32 = *dw_hdmi_bridge_atomic_get_output_bus_fmts(struct drm_bridge *bridge, struct drm_connector *conn =3D conn_state->connector; struct drm_display_info *info =3D &conn->display_info; struct drm_display_mode *mode =3D &crtc_state->mode; + struct dw_hdmi *hdmi =3D bridge->driver_private; u8 max_bpc =3D conn_state->max_requested_bpc; bool is_hdmi2_sink =3D info->hdmi.scdc.supported || (info->color_formats & = DRM_COLOR_FORMAT_YCBCR420); @@ -2564,7 +2565,7 @@ static u32 = *dw_hdmi_bridge_atomic_get_output_bus_fmts(struct drm_bridge *bridge, * If the current mode enforces 4:2:0, force the output but = format * to 4:2:0 and do not add the YUV422/444/RGB formats */ - if (conn->ycbcr_420_allowed && + if (hdmi->sink_is_hdmi && conn->ycbcr_420_allowed && (drm_mode_is_420_only(info, mode) || (is_hdmi2_sink && drm_mode_is_420_also(info, mode)))) { =20 @@ -2595,36 +2596,36 @@ static u32 = *dw_hdmi_bridge_atomic_get_output_bus_fmts(struct drm_bridge *bridge, */ =20 if (max_bpc >=3D 16 && info->bpc =3D=3D 16) { - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR444) + if (hdmi->sink_is_hdmi && info->color_formats & = DRM_COLOR_FORMAT_YCBCR444) output_fmts[i++] =3D MEDIA_BUS_FMT_YUV16_1X48; =20 output_fmts[i++] =3D MEDIA_BUS_FMT_RGB161616_1X48; } =20 if (max_bpc >=3D 12 && info->bpc >=3D 12) { - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR422) + if (hdmi->sink_is_hdmi && info->color_formats & = DRM_COLOR_FORMAT_YCBCR422) output_fmts[i++] =3D MEDIA_BUS_FMT_UYVY12_1X24; =20 - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR444) + if (hdmi->sink_is_hdmi && info->color_formats & = DRM_COLOR_FORMAT_YCBCR444) output_fmts[i++] =3D MEDIA_BUS_FMT_YUV12_1X36; =20 output_fmts[i++] =3D MEDIA_BUS_FMT_RGB121212_1X36; } =20 if (max_bpc >=3D 10 && info->bpc >=3D 10) { - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR422) + if (hdmi->sink_is_hdmi && info->color_formats & = DRM_COLOR_FORMAT_YCBCR422) output_fmts[i++] =3D MEDIA_BUS_FMT_UYVY10_1X20; =20 - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR444) + if (hdmi->sink_is_hdmi && info->color_formats & = DRM_COLOR_FORMAT_YCBCR444) output_fmts[i++] =3D MEDIA_BUS_FMT_YUV10_1X30; =20 output_fmts[i++] =3D MEDIA_BUS_FMT_RGB101010_1X30; } =20 - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR422) + if (hdmi->sink_is_hdmi && info->color_formats & = DRM_COLOR_FORMAT_YCBCR422) output_fmts[i++] =3D MEDIA_BUS_FMT_UYVY8_1X16; =20 - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR444) + if (hdmi->sink_is_hdmi && info->color_formats & = DRM_COLOR_FORMAT_YCBCR444) output_fmts[i++] =3D MEDIA_BUS_FMT_YUV8_1X24; =20 /* Default 8bit RGB fallback */ --=20 2.33.0 From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id BEBB0C433F5 for ; Tue, 1 Mar 2022 20:37:39 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 3C04D10E15E; Tue, 1 Mar 2022 20:37:39 +0000 (UTC) Received: from mo4-p01-ob.smtp.rzone.de (mo4-p01-ob.smtp.rzone.de [85.215.255.50]) by gabe.freedesktop.org (Postfix) with ESMTPS id EDD3B10E15E for ; Tue, 1 Mar 2022 20:37:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1646167042; s=strato-dkim-0002; d=goldelico.com; h=To:References:Message-Id:Cc:Date:In-Reply-To:From:Subject:Cc:Date: From:Subject:Sender; bh=enUl4JsrLhrG2ZRTNPwk0f5xsufFIJ2pEEMEeqkBDQY=; b=qoaCbST4XMW18rHVYihdg0wovg73mOulySTYQqkRjiopnvLmPoosis+1Gg3HSdtCcA S1cwieVNCzK1I2O+vs9H4QScr74kBvXTWkbfZrMAa0zFNKh2PPfljv/ae2OFgpUPpTog svrIoTxdE3OvmtmTk+1Jf+4VT0CaKaS6nhsHuhExtVKoR2bYp0zXRmUU9mrOrVYpX/og QVk0mKsf5kTJrg9GN+W+Yz50jczFb+tGQf/qp7ikjbzSE7tXP5yoGoYiQpDP0vqmR3d/ 5QzM+vMh4xr0Vv05psmycwKdbwr5hqkjkyupeXerkL/zVAHLNPxHLPLY4CFOdlUkahSK OKCg== Authentication-Results: strato.com; dkim=none X-RZG-AUTH: ":JGIXVUS7cutRB/49FwqZ7WcJeFKiMgPgp8VKxflSZ1P34KBj4Qpw9iZeHWElw47sdXM=" X-RZG-CLASS-ID: mo00 Received: from imac.fritz.box by smtp.strato.de (RZmta 47.40.1 DYNA|AUTH) with ESMTPSA id V41e6fy21KbKQst (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (curve X9_62_prime256v1 with 256 ECDH bits, eq. 3072 bits RSA)) (Client did not present a certificate); Tue, 1 Mar 2022 21:37:20 +0100 (CET) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.21\)) Subject: Re: [PATCH v16 4/4] drm/bridge: dw-hdmi: fix bus formats negotiation for 8 bit modes From: "H. Nikolaus Schaller" In-Reply-To: <5da069b6-8a99-79c2-109c-c85715165857@baylibre.com> Date: Tue, 1 Mar 2022 21:37:20 +0100 Content-Transfer-Encoding: quoted-printable Message-Id: References: <169afe64b4985c3f420177cd6f4e1e72feeb2449.1645895582.git.hns@goldelico.com> <5da069b6-8a99-79c2-109c-c85715165857@baylibre.com> To: Neil Armstrong X-Mailer: Apple Mail (2.3445.104.21) 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: Paul Boddie , Maxime Ripard , Jonas Karlman , David Airlie , dri-devel , linux-mips , Jernej Skrabec , linux-kernel , Paul Cercueil , Kieran Bingham , Robert Foss , Andrzej Hajda , Discussions about the Letux Kernel , Laurent Pinchart Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Hi Neil, > Am 01.03.2022 um 10:18 schrieb Neil Armstrong = : >=20 > Hi, >=20 > On 26/02/2022 18:13, H. Nikolaus Schaller wrote: >> Commit 7cd70656d1285b ("drm/bridge: display-connector: implement bus = fmts callbacks") >> introduced a new mechanism to negotiate bus formats between hdmi = connectors >> and bridges which is to be used e.g. for the jz4780 based CI20 board. >> In this case dw-hdmi sets up a list of formats in >> dw_hdmi_bridge_atomic_get_output_bus_fmts(). >> This includes e.g. MEDIA_BUS_FMT_UYVY8_1X16 which is chosen for the = CI20 but >> only produces a black screen. >> Analysis revealed an omission in >> Commit 6c3c719936dafe ("drm/bridge: synopsys: dw-hdmi: add bus format = negociation") >> to check for 8 bit with when adding UYVY8 or YUV8 formats. >> This fix is based on the observation that max_bpc =3D 0 when running = this >> function while info->bpc =3D 8. >=20 > In fact if bpc =3D 0, it should be considered as 8, so the issue is = elsewhere. >=20 >> Adding the proposed patch makes the jz4780/CI20 panel work again with = default >> MEDIA_BUS_FMT_RGB888_1X24 mode. >> Fixes: 7cd70656d1285b ("drm/bridge: display-connector: implement bus = fmts callbacks") >> Fixes: 6c3c719936dafe ("drm/bridge: synopsys: dw-hdmi: add bus format = negociation") >> Signed-off-by: H. Nikolaus Schaller >> --- >> drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 10 ++++++---- >> 1 file changed, 6 insertions(+), 4 deletions(-) >> diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c = b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c >> index 43e375da131e8..c08e2cc96584c 100644 >> --- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c >> +++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c >> @@ -2621,11 +2621,13 @@ static u32 = *dw_hdmi_bridge_atomic_get_output_bus_fmts(struct drm_bridge *bridge, >> output_fmts[i++] =3D MEDIA_BUS_FMT_RGB101010_1X30; >> } >> - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR422) >> - output_fmts[i++] =3D MEDIA_BUS_FMT_UYVY8_1X16; >> + if (max_bpc >=3D 8 && info->bpc >=3D 8) { >> + if (info->color_formats & DRM_COLOR_FORMAT_YCBCR422) >> + output_fmts[i++] =3D MEDIA_BUS_FMT_UYVY8_1X16; >> - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR444) >> - output_fmts[i++] =3D MEDIA_BUS_FMT_YUV8_1X24; >> + if (info->color_formats & DRM_COLOR_FORMAT_YCBCR444) >> + output_fmts[i++] =3D MEDIA_BUS_FMT_YUV8_1X24; >> + } >=20 > It should not select YUV here if it's not possible, so something is = wrong. >=20 > Can you check if = https://lore.kernel.org/r/20220119123656.1456355-2-narmstrong@baylibre.com= fixes this issue instead ? Well, I had to manually fix it to be appliable to drm-misc/drm-misc-next and specifically: c03d0b52ff71 ("drm/connector: Fix typo in output format") My resulting patch is attached. Unfortunately it did not work. I added a printk for hdmi->sink_is_hdmi. This returns 1. Which IMHO is = to be expected since I am using a HDMI connector and panel... So your patch will still = add the UYVY formats. Either the synposys module inside the jz4780 or the panel does not = understand them. Here is the EDID. Unfortunately it does not pretty print the extended = descriptors for UYVY etc. so that I don't know the exact capabilities of the panel. And what I am = not sure is if the jz4780 SoC can convert to UYVY or how it can. root@letux:~# parse-edid = sink_is_hdmi=3D1 So please let me know which parameters I should try to printk()... BR and thanks, Nikolaus ------ =46rom c84a3c4a500684e57b1243fe5386696c48fa1e1b Mon Sep 17 00:00:00 2001 From: Neil Armstrong Date: Wed, 19 Jan 2022 13:36:56 +0100 Subject: [PATCH] drm/bridge: dw-hdmi: filter out YUV output formats when = DVI When the display is not an HDMI sink, only the RGB output format is valid. Thus stop returning YUV output formats when sink is not HDMI. Fixes: 6c3c719936da ("drm/bridge: synopsys: dw-hdmi: add bus format = negociation") Signed-off-by: Neil Armstrong --- drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c = b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c index 43e375da131e8..0ec0cbe448e05 100644 --- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c +++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c @@ -2538,6 +2538,7 @@ static u32 = *dw_hdmi_bridge_atomic_get_output_bus_fmts(struct drm_bridge *bridge, struct drm_connector *conn =3D conn_state->connector; struct drm_display_info *info =3D &conn->display_info; struct drm_display_mode *mode =3D &crtc_state->mode; + struct dw_hdmi *hdmi =3D bridge->driver_private; u8 max_bpc =3D conn_state->max_requested_bpc; bool is_hdmi2_sink =3D info->hdmi.scdc.supported || (info->color_formats & = DRM_COLOR_FORMAT_YCBCR420); @@ -2564,7 +2565,7 @@ static u32 = *dw_hdmi_bridge_atomic_get_output_bus_fmts(struct drm_bridge *bridge, * If the current mode enforces 4:2:0, force the output but = format * to 4:2:0 and do not add the YUV422/444/RGB formats */ - if (conn->ycbcr_420_allowed && + if (hdmi->sink_is_hdmi && conn->ycbcr_420_allowed && (drm_mode_is_420_only(info, mode) || (is_hdmi2_sink && drm_mode_is_420_also(info, mode)))) { =20 @@ -2595,36 +2596,36 @@ static u32 = *dw_hdmi_bridge_atomic_get_output_bus_fmts(struct drm_bridge *bridge, */ =20 if (max_bpc >=3D 16 && info->bpc =3D=3D 16) { - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR444) + if (hdmi->sink_is_hdmi && info->color_formats & = DRM_COLOR_FORMAT_YCBCR444) output_fmts[i++] =3D MEDIA_BUS_FMT_YUV16_1X48; =20 output_fmts[i++] =3D MEDIA_BUS_FMT_RGB161616_1X48; } =20 if (max_bpc >=3D 12 && info->bpc >=3D 12) { - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR422) + if (hdmi->sink_is_hdmi && info->color_formats & = DRM_COLOR_FORMAT_YCBCR422) output_fmts[i++] =3D MEDIA_BUS_FMT_UYVY12_1X24; =20 - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR444) + if (hdmi->sink_is_hdmi && info->color_formats & = DRM_COLOR_FORMAT_YCBCR444) output_fmts[i++] =3D MEDIA_BUS_FMT_YUV12_1X36; =20 output_fmts[i++] =3D MEDIA_BUS_FMT_RGB121212_1X36; } =20 if (max_bpc >=3D 10 && info->bpc >=3D 10) { - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR422) + if (hdmi->sink_is_hdmi && info->color_formats & = DRM_COLOR_FORMAT_YCBCR422) output_fmts[i++] =3D MEDIA_BUS_FMT_UYVY10_1X20; =20 - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR444) + if (hdmi->sink_is_hdmi && info->color_formats & = DRM_COLOR_FORMAT_YCBCR444) output_fmts[i++] =3D MEDIA_BUS_FMT_YUV10_1X30; =20 output_fmts[i++] =3D MEDIA_BUS_FMT_RGB101010_1X30; } =20 - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR422) + if (hdmi->sink_is_hdmi && info->color_formats & = DRM_COLOR_FORMAT_YCBCR422) output_fmts[i++] =3D MEDIA_BUS_FMT_UYVY8_1X16; =20 - if (info->color_formats & DRM_COLOR_FORMAT_YCBCR444) + if (hdmi->sink_is_hdmi && info->color_formats & = DRM_COLOR_FORMAT_YCBCR444) output_fmts[i++] =3D MEDIA_BUS_FMT_YUV8_1X24; =20 /* Default 8bit RGB fallback */ --=20 2.33.0