From patchwork Fri Jan 17 16:46:58 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Detlev Casanova X-Patchwork-Id: 13943610 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 32B84C02183 for ; Fri, 17 Jan 2025 16:52:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=QeCQTSN4fSV0RGbtFRy0YPmB6Wi1wN2HDocGaTuD++g=; b=bLJ6b5K7hAh4kX QabEG6P/6YQl+M2T10jlUd95plSgA0f2vYmh80nc4QZYN7/+iSgk+pQ3KPf/krOdytAIC29OsrNKE rU/J0Zz78RHRmbt29EHCbf8+ayi3V54rfYytld0Xh6dCN8E/AhSvATpKO91L3E5maiWODGZSVy8dA k63p8Sz53DEskWpHqYSJpL9pe+r8CF77dD9dxMi5FyVsJarxIeWF5YeScSzoW4zJPpA1xcQhmbbIG UiLvkK7ANOkcuFF2bQyJwQhBQGzFv9p0TUrim5lyREB2AEPbPDFLgHRPTPg08tnCzso54EGj7jwk1 Wc6Ah8qhzQYgoooH3faA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1tYpZq-00000000rEm-3O5l; Fri, 17 Jan 2025 16:52:10 +0000 Received: from bali.collaboradmins.com ([148.251.105.195]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1tYpWL-00000000qKD-2RFv; Fri, 17 Jan 2025 16:48:34 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1737132511; bh=chwved6+F4e8V86Eu0th416VVGnscEUzoZkPxQP7yrQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=TOfT/hdefZ+yu5C8jsTKkivpVTcchZCbGtKERCDzKzp6rjodS4lDAgu+JMSPYublV aY/lbopcnD/pLNGokRTC3YP/6zW+CLYDnL7qS9J5m9nBlNFMzx6JxiC6/I4Z2puvIr w/axS6ux3GAl7pS6ROBHirgXmgxQ+U+41ggcocZW2S3I8VmYZ4Igb5b82QWBJozOEP oVFpyM9zpI/s1tH4uk0+/UiICDT7rGi0eEs/RitBY70nhXCtqdbcsow0kSdXbiFsr+ 7JO5sNiZrQ/Fz/pkDxun0V2GZ22ix2CsnHvHLPR+zSNL0WeKfKpF7gLfGBSnhLHu4h fLD40e7iyoNnw== Received: from earth.mtl.collabora.ca (mtl.collabora.ca [66.171.169.34]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: detlev) by bali.collaboradmins.com (Postfix) with ESMTPSA id 2276F17E1073; Fri, 17 Jan 2025 17:48:28 +0100 (CET) From: Detlev Casanova To: linux-kernel@vger.kernel.org Subject: [PATCH v1 2/2] arm64: dts: rockchip: Add HDMI0 audio output on rock-5b Date: Fri, 17 Jan 2025 11:46:58 -0500 Message-ID: <20250117164815.67253-3-detlev.casanova@collabora.com> X-Mailer: git-send-email 2.48.1 In-Reply-To: <20250117164815.67253-1-detlev.casanova@collabora.com> References: <20250117164815.67253-1-detlev.casanova@collabora.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20250117_084833_780579_ED38BA0E X-CRM114-Status: GOOD ( 12.45 ) X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Algea Cao , Heiko Stuebner , Geert Uytterhoeven , Kever Yang , dri-devel@lists.freedesktop.org, Laurent Pinchart , Andrzej Hajda , kernel@collabora.com, David Airlie , Dragan Simic , Simona Vetter , Rob Herring , Detlev Casanova , Robert Foss , Sebastian Reichel , Jernej Skrabec , Sugar Zhang , linux-rockchip@lists.infradead.org, FUKAUMI Naoki , devicetree@vger.kernel.org, Conor Dooley , Jonas Karlman , Maarten Lankhorst , Maxime Ripard , Dmitry Baryshkov , Johan Jonker , linux-arm-kernel@lists.infradead.org, Neil Armstrong , Jianfeng Liu , Alexey Charkov , Thomas Zimmermann , Krzysztof Kozlowski Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+linux-rockchip=archiver.kernel.org@lists.infradead.org Use the simple-audio-card driver with the hdmi0 QP node as CODEC and the i2s5 device as CPU. The simple-audio-card,mclk-fs value is set to 128 as it is done in the downstream driver. The #sound-dai-cells value is set to 0 in the hdmi0 node so that it can be used as an audio codec node. Signed-off-by: Detlev Casanova --- arch/arm64/boot/dts/rockchip/rk3588-base.dtsi | 1 + .../boot/dts/rockchip/rk3588-rock-5b.dts | 19 +++++++++++++++++++ 2 files changed, 20 insertions(+) diff --git a/arch/arm64/boot/dts/rockchip/rk3588-base.dtsi b/arch/arm64/boot/dts/rockchip/rk3588-base.dtsi index a337f3fb8377..fcd1c85e6ce8 100644 --- a/arch/arm64/boot/dts/rockchip/rk3588-base.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3588-base.dtsi @@ -1395,6 +1395,7 @@ hdmi0: hdmi@fde80000 { reset-names = "ref", "hdp"; rockchip,grf = <&sys_grf>; rockchip,vo-grf = <&vo1_grf>; + #sound-dai-cells = <0>; status = "disabled"; ports { diff --git a/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dts b/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dts index c44d001da169..50e13216ff28 100644 --- a/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dts +++ b/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dts @@ -49,6 +49,21 @@ hdmi0_con_in: endpoint { }; }; + hdmi0-sound { + compatible = "simple-audio-card"; + simple-audio-card,format = "i2s"; + simple-audio-card,mclk-fs = <128>; + simple-audio-card,name = "hdmi0"; + + simple-audio-card,codec { + sound-dai = <&hdmi0>; + }; + + simple-audio-card,cpu { + sound-dai = <&i2s5_8ch>; + }; + }; + leds { compatible = "gpio-leds"; pinctrl-names = "default"; @@ -318,6 +333,10 @@ i2s0_8ch_p0_0: endpoint { }; }; +&i2s5_8ch { + status = "okay"; +}; + &package_thermal { polling-delay = <1000>;