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 9B305CD6E67 for ; Mon, 1 Jun 2026 22:45:25 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 2A386113768; Mon, 1 Jun 2026 22:45:20 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=collabora.com header.i=@collabora.com header.b="d0XnKuj3"; dkim-atps=neutral Received: from bali.collaboradmins.com (bali.collaboradmins.com [148.251.105.195]) by gabe.freedesktop.org (Postfix) with ESMTPS id 9940010FA6F for ; Mon, 1 Jun 2026 22:45:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1780353916; bh=rkG/NccXaoj6+7q2G/t0c8xMi4deZ8qzhUuGLVQWl5Q=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=d0XnKuj3c+/bq3TfoRP+um/OqXLU/PoIHK9LsHo1lWiAqrmAbTRXXISHQAq1cPggu okXB/g+bPunyACSV9M0gkkNvQuIJGfVKC2kwV8XvBo8UdpNn5rLE0dPyxE0bXvJPIW ScWp/GJK7fgJMYxYe+k3fLfYWMppncVu/K6ALt38ezCRrkKcp8pcEC7wq47LBA2i4K JUCMK1ONHEj71ETy/ZFbcKuKL72/A0uw93L9Lv9gFetNvRTB2HGI4X6HfHNiZ9NS5D F8cVwx2mNoizrzdoreu3BWFhFCzliXoSiN4ipk1aHUTv1oofGdT0BWb2L6Bh/kBwEJ cgzzhbOOA4XjA== Received: from localhost (unknown [100.64.0.241]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (prime256v1) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: cristicc) by bali.collaboradmins.com (Postfix) with ESMTPSA id 464B017E0C93; Tue, 2 Jun 2026 00:45:16 +0200 (CEST) From: Cristian Ciocaltea Date: Tue, 02 Jun 2026 01:44:08 +0300 Subject: [PATCH v7 08/30] drm/bridge: Add HDMI 2.0 scrambler bridge operation and callbacks MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20260602-dw-hdmi-qp-scramb-v7-8-445eb54ee1ed@collabora.com> References: <20260602-dw-hdmi-qp-scramb-v7-0-445eb54ee1ed@collabora.com> In-Reply-To: <20260602-dw-hdmi-qp-scramb-v7-0-445eb54ee1ed@collabora.com> To: Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter , Andrzej Hajda , Neil Armstrong , Robert Foss , Laurent Pinchart , Jonas Karlman , Jernej Skrabec , Luca Ceresoli , Sandy Huang , =?utf-8?q?Heiko_St=C3=BCbner?= , Andy Yan , Daniel Stone , Dave Stevenson , =?utf-8?q?Ma=C3=ADra_Canal?= , Raspberry Pi Kernel Maintenance Cc: kernel@collabora.com, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org X-Mailer: b4 0.15.2 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: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Add DRM_BRIDGE_OP_HDMI_SCRAMBLER bridge operation flag and the corresponding .hdmi_scrambler_{enable|disable}() bridge funcs callbacks. Bridge drivers are expected to set DRM_BRIDGE_OP_HDMI_SCRAMBLER to advertise that they implement source-side scrambling control, which the bridge connector layer uses to wire up the connector's scrambler callbacks. Signed-off-by: Cristian Ciocaltea --- include/drm/drm_bridge.h | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/include/drm/drm_bridge.h b/include/drm/drm_bridge.h index 4ba3a5deef9a..f36e1e71aa86 100644 --- a/include/drm/drm_bridge.h +++ b/include/drm/drm_bridge.h @@ -667,6 +667,26 @@ struct drm_bridge_funcs { const struct drm_display_mode *mode, unsigned long long tmds_rate); + /** + * @hdmi_scrambler_enable: + * + * Enable source-side HDMI 2.0 scrambling and high TMDS clock ratio. + * + * This callback is optional but it must be implemented by bridges that + * set the DRM_BRIDGE_OP_HDMI_SCRAMBLER flag in their &drm_bridge->ops. + */ + int (*hdmi_scrambler_enable)(struct drm_bridge *bridge); + + /** + * @hdmi_scrambler_disable: + * + * Disable source-side HDMI 2.0 scrambling and high TMDS clock ratio. + * + * This callback is optional but it must be implemented by bridges that + * set the DRM_BRIDGE_OP_HDMI_SCRAMBLER flag in their &drm_bridge->ops. + */ + int (*hdmi_scrambler_disable)(struct drm_bridge *bridge); + /** * @hdmi_clear_avi_infoframe: * @@ -1092,6 +1112,12 @@ enum drm_bridge_ops { * &drm_bridge_funcs->hdmi_clear_spd_infoframe callbacks. */ DRM_BRIDGE_OP_HDMI_SPD_INFOFRAME = BIT(10), + /** + * @DRM_BRIDGE_OP_HDMI_SCRAMBLER: The bridge supports + * &drm_bridge_funcs->hdmi_scrambler_enable and + * &drm_bridge_funcs->hdmi_scrambler_disable callbacks. + */ + DRM_BRIDGE_OP_HDMI_SCRAMBLER = BIT(11), }; /** -- 2.54.0