From nobody Sun Feb 8 01:33:54 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E961B330D23; Mon, 20 Oct 2025 17:11:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980281; cv=none; b=jbSBPfYEmoT1sG6azbcYjUvq9i5LpG86Gw6RauhWhT1FiuZeH4l9cey0QBlEhuPNLqDpswJY6plgmJYgyNSgleKFwOTGb6A5gSeqBQQGvHwBSpWi6KAE36xs+XMuZJ20Q0C+QN4MohfPxOpHeGm6HATPXlHV4mM30Uhi/72m9hw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980281; c=relaxed/simple; bh=YIPTcjtisaZ5yPU39cB2poEgXiC9oxSbvqACMF7guZQ=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=cMYPkc8qn/C0hPHdcBJCJtwWg5srwNTNkh4MG5ctObFWz3rk8uZf1V0szjchGN3Cj4WQVwv0AOBhiPt1v4QB9z1gp20QE42vxxA1tU8Fz7gBkvYq3GLrq1nyvEXlD39di1EdJ0Ns7Bj6xBm+U5SOeDRURnap5M5UVVhv7joxNA4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Z2j2ylcR; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Z2j2ylcR" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6B660C19423; Mon, 20 Oct 2025 17:11:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760980280; bh=YIPTcjtisaZ5yPU39cB2poEgXiC9oxSbvqACMF7guZQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Z2j2ylcRsPrmU7y/m750/X9+1N5xr2bBqx9A+QSEXxwY+9gtT7A7NnP65B/pv7Gn2 u32eHV6WYAZBxdpfKfLs35SfOdk3Wv9F8TsqxGm9fH+BLPjt+p1s5DsWYNAgGV0oA9 H/pbvK/CWheUeHx85405QQn3q74qyJnxQ53LmlTERDER2xQPN8QL+gwM02SYpOGo7o qejrhZmMP2FvP/q1BoHm0e8Gl8vcyBeCn1B36empLQOoaTzT3RKdaYIcTj47HG1Qg9 xKps1E7fosHAK1eIRSRdvqPkQzp+JGquO8hVdjmbmO6pxwbW90dZBx5kpfTNYW/dYP mQ2aiX9+YFJ4A== Received: by wens.tw (Postfix, from userid 1000) id 2A8285F952; Tue, 21 Oct 2025 01:11:18 +0800 (CST) From: Chen-Yu Tsai To: Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Mark Brown , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Vinod Koul Cc: Chen-Yu Tsai , linux-sunxi@lists.linux.dev, linux-sound@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 01/11] dt-bindings: dma: allwinner,sun50i-a64-dma: Add compatibles for A523 Date: Tue, 21 Oct 2025 01:10:47 +0800 Message-ID: <20251020171059.2786070-2-wens@kernel.org> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20251020171059.2786070-1-wens@kernel.org> References: <20251020171059.2786070-1-wens@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" From: Chen-Yu Tsai There are two DMA controllers on the A523, one in the main system area and the other for the MCU. These are the same as the one found on the A100. The only difference is the DMA endpoint (DRQ) layout. Since the number of channels and endpoints are described with additional generic properties, just add new A523-specific compatible strings and fallback to the A100 one. Signed-off-by: Chen-Yu Tsai Acked-by: Conor Dooley --- I could probably take this through the soc tree if Vinod gives an ack. .../devicetree/bindings/dma/allwinner,sun50i-a64-dma.yaml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma= .yaml b/Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma.yaml index 0f2501f72cca..c3e14eb6cfff 100644 --- a/Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma.yaml +++ b/Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma.yaml @@ -29,7 +29,10 @@ properties: - const: allwinner,sun8i-r40-dma - const: allwinner,sun50i-a64-dma - items: - - const: allwinner,sun50i-h616-dma + - enum: + - allwinner,sun50i-h616-dma + - allwinner,sun55i-a523-dma + - allwinner,sun55i-a523-mcu-dma - const: allwinner,sun50i-a100-dma =20 reg: --=20 2.47.3 From nobody Sun Feb 8 01:33:54 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C0D952D1F44; Mon, 20 Oct 2025 17:11:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980280; cv=none; b=aElnK2fiSE50XDhFWTfYs4La9TKdqfGoCEthFmQKywdhab6E05CzcMJy0RpXIea1Fx2j53X5EDuJLohwGwIf5Z34peimWHjpcsaRy8mGV5tS9cgS+6ZYUSNTZ17pG79uE3p0bVcii/9qW8zZCL7J6LPYSwy55T3GF5CJdYkgPyk= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980280; c=relaxed/simple; bh=scg+/vO8bFxkmmzsBeRqdeZzJ1dGRrmJ/AeHk9Ng2s0=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=LqgvjlYkJ0vf+Vvbh3pTI7sf4pptuFH/IvdUAMBbVobDnq3MZVff1kCjluifU4jienBiVI7nPf3gf4aKN7FcMXp2aoWqigWEzizj5TPCWzjrzFMQqCksbKM5c0KCF9AdNt59bwepoVf/EgC4XiP2HEaEyQSzruN7xwEwL7cfVms= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Gy4iVDXJ; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Gy4iVDXJ" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 482EEC113D0; Mon, 20 Oct 2025 17:11:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760980280; bh=scg+/vO8bFxkmmzsBeRqdeZzJ1dGRrmJ/AeHk9Ng2s0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Gy4iVDXJWPC5L6y6UGyZNPo1lTkIFG+bSMJ3dmQuCn4YSDVdoZO6n7pLVV7CmH4RA K2IdzWv4HUJdz6a7QyNz6Fkz3s5IEm22PF1bQQo+GXfG6rW2u6ADBT9Kd5tEPIyA9I SAqqzGT62WZfYIC8H87SqEnyyJT7Qep5vR9wvouCiHE6gJqodbcrY/OpOlMCInb5G6 PNW9S6EsKppFRgFGqBHMMN4dT/HmB8AjB9bWiufu+0VZJj2QatzvL2TlHqtN2DvAo+ zcxZK5zdadGd2C6f75ZqiasnwzAwdr7mNjrqcUJJqHkXOB/QTFmFy821qOGMn/v3TW lriRxPotYO48g== Received: by wens.tw (Postfix, from userid 1000) id 344895FE2C; Tue, 21 Oct 2025 01:11:18 +0800 (CST) From: Chen-Yu Tsai To: Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Mark Brown , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Vinod Koul Cc: linux-sunxi@lists.linux.dev, linux-sound@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 02/11] ASoC: dt-bindings: allwinner,sun4i-a10-i2s: Add compatible for A523 Date: Tue, 21 Oct 2025 01:10:48 +0800 Message-ID: <20251020171059.2786070-3-wens@kernel.org> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20251020171059.2786070-1-wens@kernel.org> References: <20251020171059.2786070-1-wens@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" As far as the author can tell, based on their respective manuals, the I2S interface controllers found in the Allwinner A523 SoC is the same as ones in the R329 SoC. Add a SoC-specific compatible for it, with a fallback to the R329's compatible. Signed-off-by: Chen-Yu Tsai Acked-by: Conor Dooley --- .../devicetree/bindings/sound/allwinner,sun4i-a10-i2s.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/sound/allwinner,sun4i-a10-i2= s.yaml b/Documentation/devicetree/bindings/sound/allwinner,sun4i-a10-i2s.ya= ml index 739114fb6549..ae86cb5f0a74 100644 --- a/Documentation/devicetree/bindings/sound/allwinner,sun4i-a10-i2s.yaml +++ b/Documentation/devicetree/bindings/sound/allwinner,sun4i-a10-i2s.yaml @@ -33,7 +33,9 @@ properties: - const: allwinner,sun50i-h6-i2s - const: allwinner,sun50i-r329-i2s - items: - - const: allwinner,sun20i-d1-i2s + - enum: + - allwinner,sun20i-d1-i2s + - allwinner,sun55i-a523-i2s - const: allwinner,sun50i-r329-i2s =20 reg: --=20 2.47.3 From nobody Sun Feb 8 01:33:54 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C0E6C32F74C; Mon, 20 Oct 2025 17:11:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980280; cv=none; b=YcxDaNwm7BnrvRUq1055xXkUl/ikSlmKQIumQWc/G0PnBy2LAuFFARXWABqahKP4FAUnd6OScVBEHso2bufMLMV8hFQmK5b/baW8sY+XNr07uodmVoCwA8mmkexq4KasTvAsO++IXylJlaH8yI4ljjABwUsuRaq3rjcthEF1x7I= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980280; c=relaxed/simple; bh=bfZTvPbJKxHOKhlO78loZoETiX7+tlInaGSPp76tZcE=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=ZQxYVtUue5TmW127URkGui2kilRCfRLf/ftY3GzLxRDfffLmLrkvLAq7MN+lFhKQ8YBfx1UF3XUVb4L7qy1lWDo0/luqtg5eeqT/mncJ4OFPeEvZzua7Pr2O/dhYJ9myUNtwGbWAcypJWSctzJAP+UKTd5WoxXIG/P9BxBlZEGg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=CLckVGJ5; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="CLckVGJ5" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4614BC4CEFE; Mon, 20 Oct 2025 17:11:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760980280; bh=bfZTvPbJKxHOKhlO78loZoETiX7+tlInaGSPp76tZcE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=CLckVGJ5tDHhW7IotJ9DZCXI7B/SYprw7XvmrT3wvjQCMu7z2uoptGX1kX4mFqP37 KIyemA8gOhpgtNjQhxd3daeWK16mFZVDorTEaUIn4TeH0q/CQWwo2r7g6wxUSf1ST0 TZetVf80aXNAUs+KzDujeHQDCjh6htC53i1jTP8YTTYF8EhHiBXZUpO/ITebx6xlUz WRDYSatVJoUnYWPnFbJp+bnWryZLOfJC2YlrLR+luGgothpRNSDng9Naig3NUme0jP DaQqe7aQ48s8oePQg21kcrkBCzYfQvRAY0DpD/k4JgGKHB6/0i06+rElKB/TdlOyAf dEPcVO6kC5b0w== Received: by wens.tw (Postfix, from userid 1000) id 3BFAC5FE31; Tue, 21 Oct 2025 01:11:18 +0800 (CST) From: Chen-Yu Tsai To: Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Mark Brown , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Vinod Koul Cc: linux-sunxi@lists.linux.dev, linux-sound@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 03/11] ASoC: dt-bindings: allwinner,sun4i-a10-spdif: Add compatible for A523 Date: Tue, 21 Oct 2025 01:10:49 +0800 Message-ID: <20251020171059.2786070-4-wens@kernel.org> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20251020171059.2786070-1-wens@kernel.org> References: <20251020171059.2786070-1-wens@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The SPDIF hardware block in the A523 SoC has the same layout as the H616 for the transmitter side. However unlike previous generations, the hardware block now takes separate module clocks for the TX and RX sides. This presumably allows the hardware to send and receive audio streams at different sample rates. The new hardware also gained RX insertion detection, and some extra information registers. Add a new compatible for it without any fallbacks. Signed-off-by: Chen-Yu Tsai Acked-by: Conor Dooley --- .../sound/allwinner,sun4i-a10-spdif.yaml | 44 ++++++++++++++++--- 1 file changed, 38 insertions(+), 6 deletions(-) diff --git a/Documentation/devicetree/bindings/sound/allwinner,sun4i-a10-sp= dif.yaml b/Documentation/devicetree/bindings/sound/allwinner,sun4i-a10-spdi= f.yaml index aa32dc950e72..1d089ba70f45 100644 --- a/Documentation/devicetree/bindings/sound/allwinner,sun4i-a10-spdif.yaml +++ b/Documentation/devicetree/bindings/sound/allwinner,sun4i-a10-spdif.yaml @@ -23,6 +23,7 @@ properties: - const: allwinner,sun8i-h3-spdif - const: allwinner,sun50i-h6-spdif - const: allwinner,sun50i-h616-spdif + - const: allwinner,sun55i-a523-spdif - items: - const: allwinner,sun8i-a83t-spdif - const: allwinner,sun8i-h3-spdif @@ -37,14 +38,12 @@ properties: maxItems: 1 =20 clocks: - items: - - description: Bus Clock - - description: Module Clock + minItems: 2 + maxItems: 3 =20 clock-names: - items: - - const: apb - - const: spdif + minItems: 2 + maxItems: 3 =20 # Even though it only applies to subschemas under the conditionals, # not listing them here will trigger a warning because of the @@ -65,6 +64,7 @@ allOf: - allwinner,sun8i-h3-spdif - allwinner,sun50i-h6-spdif - allwinner,sun50i-h616-spdif + - allwinner,sun55i-a523-spdif =20 then: required: @@ -98,6 +98,38 @@ allOf: - const: rx - const: tx =20 + - if: + properties: + compatible: + contains: + enum: + - allwinner,sun55i-a523-spdif + + then: + properties: + clocks: + items: + - description: Bus Clock + - description: TX Clock + - description: RX Clock + + clock-names: + items: + - const: apb + - const: tx + - const: rx + else: + properties: + clocks: + items: + - description: Bus Clock + - description: Module Clock + + clock-names: + items: + - const: apb + - const: spdif + required: - "#sound-dai-cells" - compatible --=20 2.47.3 From nobody Sun Feb 8 01:33:54 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E1635330320; Mon, 20 Oct 2025 17:11:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980281; cv=none; b=HFfiIqaK388dSC0WuUDPtSDN6V5Lhx2RCUjmg/lXd4/uNflsYzb5yxXAjRj9JGtmkumuvNzDyf7pyIE9NZ1oM+5RGPWl+xTLu8eGNBn83sNpc8U1bBnSB5Fdp1rmMEjv4keCYy0s3zS8Hxndz1YBeff7dWbt8colXNEQy4n6dCI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980281; c=relaxed/simple; bh=y56EJjskppbR+/rkKdNbFUjyY8BC1025ZtXtMgp99fA=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=WVhYnOUy88xn2INzFk3vwTmY9/4M+Wlz3VQJlUrxOTOSzwhwS4BjbRU1I163B9HTCx/0kpU4/bYGlDzD/Xjayu8HYaKq3Gj2JqtGOXw9p2pzWmLpYkUzQYsfGYzOn+zfOdsa08vUXirLDIplNkio5W8voyKDdp6cxaZZ2u4R56g= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=AWdrNuSx; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="AWdrNuSx" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4B601C4AF0B; Mon, 20 Oct 2025 17:11:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760980280; bh=y56EJjskppbR+/rkKdNbFUjyY8BC1025ZtXtMgp99fA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=AWdrNuSx2oo2kKoNLDRwFOI+ta0fWeipsRkJtycyKAs8R6VgZTE+U+gAuq4mRQGVb 4MuZPrA8qZQOL+YkkaM/nMEbjhnAJh+kTEOProDZY5Eb8rTuy2NM80bBzhzKPYOwwi bnsXxRTbX7UFNdOgN80sf0ZPoGvkILMO2TYcXRhcFFWR28+KOd8iyOabAd/10iiGrt 6r/DLmIlcFvSSzf0j/3sBUcQobSAzwhDlIkY/kuoTR6WLEh1rXl7PSAeADFChD/CgR +NWmHgob6V3MPJfv8cuJl8uhKYwxS02j+CbjAR83SlmUYnTTi+mKfxPymhnIq0laGP OWS1xwwnN2wXQ== Received: by wens.tw (Postfix, from userid 1000) id 431FD5FE78; Tue, 21 Oct 2025 01:11:18 +0800 (CST) From: Chen-Yu Tsai To: Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Mark Brown , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Vinod Koul Cc: linux-sunxi@lists.linux.dev, linux-sound@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 04/11] ASoC: sun4i-spdif: Support SPDIF output on A523 family Date: Tue, 21 Oct 2025 01:10:50 +0800 Message-ID: <20251020171059.2786070-5-wens@kernel.org> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20251020171059.2786070-1-wens@kernel.org> References: <20251020171059.2786070-1-wens@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The TX side of the SPDIF block on the A523 is almost the same the previous generations, the only difference being that it has separate module clock inputs for the TX and RX side. Since this driver currently only supports TX, add support for a different clock name so that TX and RX clocks can be separated if RX support is ever added. Then add support for the A523. Signed-off-by: Chen-Yu Tsai --- sound/soc/sunxi/sun4i-spdif.c | 28 +++++++++++++++++++++++++--- 1 file changed, 25 insertions(+), 3 deletions(-) diff --git a/sound/soc/sunxi/sun4i-spdif.c b/sound/soc/sunxi/sun4i-spdif.c index 34e5bd94e9af..6a58dc4311de 100644 --- a/sound/soc/sunxi/sun4i-spdif.c +++ b/sound/soc/sunxi/sun4i-spdif.c @@ -177,6 +177,7 @@ struct sun4i_spdif_quirks { bool has_reset; unsigned int val_fctl_ftx; unsigned int mclk_multiplier; + const char *tx_clk_name; }; =20 struct sun4i_spdif_dev { @@ -323,6 +324,7 @@ static int sun4i_spdif_hw_params(struct snd_pcm_substre= am *substream, } mclk *=3D host->quirks->mclk_multiplier; =20 + dev_info(&pdev->dev, "Setting SPDIF clock rate to %u\n", mclk); ret =3D clk_set_rate(host->spdif_clk, mclk); if (ret < 0) { dev_err(&pdev->dev, @@ -542,7 +544,6 @@ static struct snd_soc_dai_driver sun4i_spdif_dai =3D { .formats =3D SUN4I_FORMATS, }, .ops =3D &sun4i_spdif_dai_ops, - .name =3D "spdif", }; =20 static const struct sun4i_spdif_quirks sun4i_a10_spdif_quirks =3D { @@ -572,6 +573,14 @@ static const struct sun4i_spdif_quirks sun50i_h6_spdif= _quirks =3D { .mclk_multiplier =3D 1, }; =20 +static const struct sun4i_spdif_quirks sun55i_a523_spdif_quirks =3D { + .reg_dac_txdata =3D SUN8I_SPDIF_TXFIFO, + .val_fctl_ftx =3D SUN50I_H6_SPDIF_FCTL_FTX, + .has_reset =3D true, + .mclk_multiplier =3D 1, + .tx_clk_name =3D "tx", +}; + static const struct of_device_id sun4i_spdif_of_match[] =3D { { .compatible =3D "allwinner,sun4i-a10-spdif", @@ -594,6 +603,15 @@ static const struct of_device_id sun4i_spdif_of_match[= ] =3D { /* Essentially the same as the H6, but without RX */ .data =3D &sun50i_h6_spdif_quirks, }, + { + .compatible =3D "allwinner,sun55i-a523-spdif", + /* + * Almost the same as H6, but has split the TX and RX clocks, + * has a separate reset bit for the RX side, and has some + * expanded features for the RX side. + */ + .data =3D &sun55i_a523_spdif_quirks, + }, { /* sentinel */ } }; MODULE_DEVICE_TABLE(of, sun4i_spdif_of_match); @@ -635,6 +653,7 @@ static int sun4i_spdif_probe(struct platform_device *pd= ev) const struct sun4i_spdif_quirks *quirks; int ret; void __iomem *base; + const char *tx_clk_name =3D "spdif"; =20 dev_dbg(&pdev->dev, "Entered %s\n", __func__); =20 @@ -671,9 +690,12 @@ static int sun4i_spdif_probe(struct platform_device *p= dev) return PTR_ERR(host->apb_clk); } =20 - host->spdif_clk =3D devm_clk_get(&pdev->dev, "spdif"); + if (quirks->tx_clk_name) + tx_clk_name =3D quirks->tx_clk_name; + host->spdif_clk =3D devm_clk_get(&pdev->dev, tx_clk_name); if (IS_ERR(host->spdif_clk)) { - dev_err(&pdev->dev, "failed to get a spdif clock.\n"); + dev_err(&pdev->dev, "failed to get the \"%s\" clock.\n", + tx_clk_name); return PTR_ERR(host->spdif_clk); } =20 --=20 2.47.3 From nobody Sun Feb 8 01:33:54 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A3DEB332EA1; Mon, 20 Oct 2025 17:11:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980282; cv=none; b=kcm3wAkd+XEOKdN8L8nYs8q8tFJQ0wuTybQ6o8nLQZR4CIMBEQo/c5CU87A7RsOZJnIK0LSftFunsJWhcBFYQmL16+x/FESgzb163LrRILGnmMFAVs6CTbk8912z/xYFSNPClpHLs15ceIKgyEWsVNXT+B81oVe9S+SO8ExmNmQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980282; c=relaxed/simple; bh=qJlYlCdLicsk3Qg+mKxU+NISEK1JvSSkuCl6A572eG4=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=akhiSYiXQJ5Qn44t/A2lMpLlqeWdS9S/NuS8i81pKWDlJwtO44TnyfIY6UIrXU9hjG1BW1hr4lBwbYzJIaptuvx8dfXvJbNGCBf0L0WvRvOpUOVWqlmtJlM4NIoHSOP1rPgrDH4EtdLNOrjJqEIQeAcok/nPzafT9LHFClyK0w4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=BCvy6s5f; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="BCvy6s5f" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5EC18C19421; Mon, 20 Oct 2025 17:11:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760980282; bh=qJlYlCdLicsk3Qg+mKxU+NISEK1JvSSkuCl6A572eG4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=BCvy6s5fuw+OQYHnGwF2kNwuSXGkZ9hKH3PWBHPFC7S3XeMeVN0cRdly0W5bSUDhb RO0kfd1ZCJJBB+L3kHSFqP4hi0W5zDMB+H1QkBHrQcufHuCv2H2Sx5IQm59Xs47c+v 3m92pOgPjxML37+9DRFI096dxL/esFy85urgSV1M1ON3kcgWPOB9jW1wL3x2QQd4Zn r087FlRGBv+wMUvcr0GzUiDEEpZonvClaznrMU3KMtxAOj94zdvfKiIPm7FXSoLL4v 2Uzhkb70r7FJN7vW28nHLxcRiLjUB4NNMwIG/oZTJcscTDnfJga+Y4cE2ABC3L77QY kxVBwDt1xsQpw== Received: by wens.tw (Postfix, from userid 1000) id 4B4EC5FDC7; Tue, 21 Oct 2025 01:11:18 +0800 (CST) From: Chen-Yu Tsai To: Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Mark Brown , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Vinod Koul Cc: linux-sunxi@lists.linux.dev, linux-sound@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 05/11] clk: sunxi-ng: sun55i-a523-r-ccu: Mark bus-r-dma as critical Date: Tue, 21 Oct 2025 01:10:51 +0800 Message-ID: <20251020171059.2786070-6-wens@kernel.org> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20251020171059.2786070-1-wens@kernel.org> References: <20251020171059.2786070-1-wens@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The "bus-r-dma" clock in the A523's PRCM clock controller is also referred to as "DMA_CLKEN_SW" or "DMA ADB400 gating". It is unclear how this ties into the DMA controller MBUS clock gate; however if the clock is not enabled, the DMA controller in the MCU block will fail to access DRAM, even failing to retrieve the DMA descriptors. Mark this clock as critical. This sort of mirrors what is done for the main DMA controller's MBUS clock, which has a separate toggle that is currently left out of the main clock controller driver. Fixes: 8cea339cfb81 ("clk: sunxi-ng: add support for the A523/T527 PRCM CCU= ") Signed-off-by: Chen-Yu Tsai Acked-by: Jernej Skrabec --- drivers/clk/sunxi-ng/ccu-sun55i-a523-r.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/clk/sunxi-ng/ccu-sun55i-a523-r.c b/drivers/clk/sunxi-n= g/ccu-sun55i-a523-r.c index 70ce0ca0cb7d..fdcdcccd0939 100644 --- a/drivers/clk/sunxi-ng/ccu-sun55i-a523-r.c +++ b/drivers/clk/sunxi-ng/ccu-sun55i-a523-r.c @@ -121,7 +121,7 @@ static SUNXI_CCU_GATE_HW(bus_r_ir_rx_clk, "bus-r-ir-rx", &r_apb0_clk.common.hw, 0x1cc, BIT(0), 0); =20 static SUNXI_CCU_GATE_HW(bus_r_dma_clk, "bus-r-dma", - &r_apb0_clk.common.hw, 0x1dc, BIT(0), 0); + &r_apb0_clk.common.hw, 0x1dc, BIT(0), CLK_IS_CRITICAL); static SUNXI_CCU_GATE_HW(bus_r_rtc_clk, "bus-r-rtc", &r_apb0_clk.common.hw, 0x20c, BIT(0), 0); static SUNXI_CCU_GATE_HW(bus_r_cpucfg_clk, "bus-r-cpucfg", --=20 2.47.3 From nobody Sun Feb 8 01:33:54 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D441A332EBA; Mon, 20 Oct 2025 17:11:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980282; cv=none; b=etSkMv4uN4gYTqOmFCRH1IA+/JiPWYi1uEc7hSc9q9IUJgntxl5F2TbjA9sU+6nRcgrp9MAvb/cznt405FZRjaC90WvkxoDl5oCZXEoeakWhCmXI5yFbPH0/UbejFtQu2WtSnBqp6VZ9tIprfRLzIaQSs+3o0/lEiKh2HmrD9lE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980282; c=relaxed/simple; bh=IrJnFSl0vpD3jGCn+oBa7YlslutdYfojddkzQZM95dk=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=HzYWJjjZqT3I0RNdRnpf0X6yfb8E+TeUYA7Fpt1awzjwF0obQROxbyRsmb5nHyLAFuVKxX2P61b6aAAIAKjS7YZ1yNQZypEE38DN1jn0fBgGhEc/Uu+QAGv7Ds3Xqf7qw6T9gdRj7cvL8wfqE0DWBLX71gqZDb6UQJpt7KA5gLI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=ll1u0K+4; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="ll1u0K+4" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5AD3FC113D0; Mon, 20 Oct 2025 17:11:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760980282; bh=IrJnFSl0vpD3jGCn+oBa7YlslutdYfojddkzQZM95dk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ll1u0K+4eP+gsGLcebeYiSuIsCSyF8lilj4gby7yHw+6Xm3n7BC9FS3+kiL4RKIr8 G9aTXWih4Z4rHUEHbA1WtbrlC1svYG/6DBSJHXtC3rf01P2OcNLgo1BOrzMjxzb6Jq 0omSqngr32C9EmsA/OmpFuXddT91xBpOPlD8ayQYbi/k4TEt6scLSZy1KYhepV/Gl4 7ActQB0DDucoi9b7qvg3ndo1UDigjgpj6ksXdVIuOO32YllCwPDoqWPO3TJiMdh2te hiFUGH0YEV9gU5YArLPP+4CmX+3nOdB8ITc84yPdyMUo5xc95YJ6yli0E38DqmOy08 Q35J/32vbmsPQ== Received: by wens.tw (Postfix, from userid 1000) id 524AA5FEC0; Tue, 21 Oct 2025 01:11:18 +0800 (CST) From: Chen-Yu Tsai To: Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Mark Brown , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Vinod Koul Cc: linux-sunxi@lists.linux.dev, linux-sound@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 06/11] clk: sunxi-ng: sun55i-a523-ccu: Lower audio0 pll minimum rate Date: Tue, 21 Oct 2025 01:10:52 +0800 Message-ID: <20251020171059.2786070-7-wens@kernel.org> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20251020171059.2786070-1-wens@kernel.org> References: <20251020171059.2786070-1-wens@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" While the user manual states that the PLL's rate should be between 180 MHz and 3 GHz in the register defninition section, it also says the actual operating frequency is 22.5792*4 MHz in the PLL features table. 22.5792*4 MHz is one of the actual clock rates that we want and is is available in the SDM table. Lower the minimum clock rate to 90 MHz so that both rates in the SDM table can be used. Fixes: 7cae1e2b5544 ("clk: sunxi-ng: Add support for the A523/T527 CCU PLLs= ") Signed-off-by: Chen-Yu Tsai Reviewed-by: Jernej Skrabec --- drivers/clk/sunxi-ng/ccu-sun55i-a523.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/clk/sunxi-ng/ccu-sun55i-a523.c b/drivers/clk/sunxi-ng/= ccu-sun55i-a523.c index acb532f8361b..20dad06b37ca 100644 --- a/drivers/clk/sunxi-ng/ccu-sun55i-a523.c +++ b/drivers/clk/sunxi-ng/ccu-sun55i-a523.c @@ -300,7 +300,7 @@ static struct ccu_nm pll_audio0_4x_clk =3D { .m =3D _SUNXI_CCU_DIV(16, 6), .sdm =3D _SUNXI_CCU_SDM(pll_audio0_sdm_table, BIT(24), 0x178, BIT(31)), - .min_rate =3D 180000000U, + .min_rate =3D 90000000U, .max_rate =3D 3000000000U, .common =3D { .reg =3D 0x078, --=20 2.47.3 From nobody Sun Feb 8 01:33:54 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D43AB332EB6; Mon, 20 Oct 2025 17:11:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980282; cv=none; b=ed2hLHKBdTjTgpid7K1vIUw7REvM8erMOWrmNW2rjuK0gaYWlD3syOU/MUl3rvgsZ/xIXF13ctLdI8V49Zqw2B0jX2EV+BDT/kNlgpodclG0OTybDkU8I9OPgzJ6ql1EQAiVqbQGmozpIrUNk+kDHKpGn2glocOigSmuNiMRtTs= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980282; c=relaxed/simple; bh=8s4OP1AvakA/kxF+4prl0Tvj4XO9cRh189UcPgu3oxk=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=ayU4uHWgiO8wrX3fgZo0nOc3ZjIXe3QW06Oc/ELzsd6e3JlSoFfBAKP6NU/p3ax0yTuhSAkJXudE0oPYrsdmwnm4WyWLdQ3ICLCxTyku4E9odVDpefg2IppzsfZ8F8puJbHQzePin1ZgtGZxxtEjMFXc489V9piLiSnfTLvFr/Q= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=g5laTG33; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="g5laTG33" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5E77BC116B1; Mon, 20 Oct 2025 17:11:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760980282; bh=8s4OP1AvakA/kxF+4prl0Tvj4XO9cRh189UcPgu3oxk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=g5laTG33MZnByhR4wffZQdgbPopMZuAIWkmH3vTJCU50Z3zLZymlE5i/xT7sQedms SAeCE+rhUkk1tPZJnC3UmI0qegJlSNc5OqfT7pImk46KudP4cNwiQFs8siFxeN5Grq w8XolDDnh7LBAY0bykr9RN47eKSIGLDqiOKf5WH5KNNJNlY2nTVD5VyZj+ZxEe9/Db Ve6EPnFzRXDkKGLVmFSpnaowpMV5/rJVYH1J2f2hOBDYmDyT7Z0KgXPVHwf1hG9ZSb KK0/e+O3PsHXpIhJu62d0n/RfsaWBScszNceMWibrsBzhNT7NTe7NElK0Yh6QcjRSU K/ssEO84Pdnlg== Received: by wens.tw (Postfix, from userid 1000) id 5CB135FEB2; Tue, 21 Oct 2025 01:11:18 +0800 (CST) From: Chen-Yu Tsai To: Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Mark Brown , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Vinod Koul Cc: Chen-Yu Tsai , linux-sunxi@lists.linux.dev, linux-sound@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 07/11] arm64: dts: allwinner: a523: Add DMA controller device nodes Date: Tue, 21 Oct 2025 01:10:53 +0800 Message-ID: <20251020171059.2786070-8-wens@kernel.org> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20251020171059.2786070-1-wens@kernel.org> References: <20251020171059.2786070-1-wens@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" From: Chen-Yu Tsai The A523 has two DMA controllers. Add device nodes for both. Also hook up DMA for existing devices. Signed-off-by: Chen-Yu Tsai Acked-by: Jernej Skrabec --- .../arm64/boot/dts/allwinner/sun55i-a523.dtsi | 56 +++++++++++++++++++ 1 file changed, 56 insertions(+) diff --git a/arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi b/arch/arm64/bo= ot/dts/allwinner/sun55i-a523.dtsi index a9e051a8bea3..8edbd3873199 100644 --- a/arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi +++ b/arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi @@ -241,6 +241,8 @@ uart0: serial@2500000 { reg-io-width =3D <4>; clocks =3D <&ccu CLK_BUS_UART0>; resets =3D <&ccu RST_BUS_UART0>; + dmas =3D <&dma 14>, <&dma 14>; + dma-names =3D "tx", "rx"; status =3D "disabled"; }; =20 @@ -252,6 +254,8 @@ uart1: serial@2500400 { reg-io-width =3D <4>; clocks =3D <&ccu CLK_BUS_UART1>; resets =3D <&ccu RST_BUS_UART1>; + dmas =3D <&dma 15>, <&dma 15>; + dma-names =3D "tx", "rx"; status =3D "disabled"; }; =20 @@ -263,6 +267,8 @@ uart2: serial@2500800 { reg-io-width =3D <4>; clocks =3D <&ccu CLK_BUS_UART2>; resets =3D <&ccu RST_BUS_UART2>; + dmas =3D <&dma 16>, <&dma 16>; + dma-names =3D "tx", "rx"; status =3D "disabled"; }; =20 @@ -274,6 +280,8 @@ uart3: serial@2500c00 { reg-io-width =3D <4>; clocks =3D <&ccu CLK_BUS_UART3>; resets =3D <&ccu RST_BUS_UART3>; + dmas =3D <&dma 17>, <&dma 17>; + dma-names =3D "tx", "rx"; status =3D "disabled"; }; =20 @@ -285,6 +293,8 @@ uart4: serial@2501000 { reg-io-width =3D <4>; clocks =3D <&ccu CLK_BUS_UART4>; resets =3D <&ccu RST_BUS_UART4>; + dmas =3D <&dma 18>, <&dma 18>; + dma-names =3D "tx", "rx"; status =3D "disabled"; }; =20 @@ -296,6 +306,8 @@ uart5: serial@2501400 { reg-io-width =3D <4>; clocks =3D <&ccu CLK_BUS_UART5>; resets =3D <&ccu RST_BUS_UART5>; + dmas =3D <&dma 19>, <&dma 19>; + dma-names =3D "tx", "rx"; status =3D "disabled"; }; =20 @@ -307,6 +319,8 @@ uart6: serial@2501800 { reg-io-width =3D <4>; clocks =3D <&ccu CLK_BUS_UART6>; resets =3D <&ccu RST_BUS_UART6>; + dmas =3D <&dma 20>, <&dma 20>; + dma-names =3D "tx", "rx"; status =3D "disabled"; }; =20 @@ -318,6 +332,8 @@ uart7: serial@2501c00 { reg-io-width =3D <4>; clocks =3D <&ccu CLK_BUS_UART7>; resets =3D <&ccu RST_BUS_UART7>; + dmas =3D <&dma 21>, <&dma 21>; + dma-names =3D "tx", "rx"; status =3D "disabled"; }; =20 @@ -329,6 +345,8 @@ i2c0: i2c@2502000 { interrupts =3D ; clocks =3D <&ccu CLK_BUS_I2C0>; resets =3D <&ccu RST_BUS_I2C0>; + dmas =3D <&dma 43>, <&dma 43>; + dma-names =3D "rx", "tx"; status =3D "disabled"; #address-cells =3D <1>; #size-cells =3D <0>; @@ -342,6 +360,8 @@ i2c1: i2c@2502400 { interrupts =3D ; clocks =3D <&ccu CLK_BUS_I2C1>; resets =3D <&ccu RST_BUS_I2C1>; + dmas =3D <&dma 44>, <&dma 44>; + dma-names =3D "rx", "tx"; status =3D "disabled"; #address-cells =3D <1>; #size-cells =3D <0>; @@ -355,6 +375,8 @@ i2c2: i2c@2502800 { interrupts =3D ; clocks =3D <&ccu CLK_BUS_I2C2>; resets =3D <&ccu RST_BUS_I2C2>; + dmas =3D <&dma 45>, <&dma 45>; + dma-names =3D "rx", "tx"; status =3D "disabled"; #address-cells =3D <1>; #size-cells =3D <0>; @@ -368,6 +390,8 @@ i2c3: i2c@2502c00 { interrupts =3D ; clocks =3D <&ccu CLK_BUS_I2C3>; resets =3D <&ccu RST_BUS_I2C3>; + dmas =3D <&dma 46>, <&dma 46>; + dma-names =3D "rx", "tx"; status =3D "disabled"; #address-cells =3D <1>; #size-cells =3D <0>; @@ -381,6 +405,8 @@ i2c4: i2c@2503000 { interrupts =3D ; clocks =3D <&ccu CLK_BUS_I2C4>; resets =3D <&ccu RST_BUS_I2C4>; + dmas =3D <&dma 47>, <&dma 47>; + dma-names =3D "rx", "tx"; status =3D "disabled"; #address-cells =3D <1>; #size-cells =3D <0>; @@ -394,6 +420,8 @@ i2c5: i2c@2503400 { interrupts =3D ; clocks =3D <&ccu CLK_BUS_I2C5>; resets =3D <&ccu RST_BUS_I2C5>; + dmas =3D <&dma 48>, <&dma 48>; + dma-names =3D "rx", "tx"; status =3D "disabled"; #address-cells =3D <1>; #size-cells =3D <0>; @@ -408,6 +436,19 @@ syscon: syscon@3000000 { ranges; }; =20 + dma: dma-controller@3002000 { + compatible =3D "allwinner,sun55i-a523-dma", + "allwinner,sun50i-a100-dma"; + reg =3D <0x03002000 0x1000>; + interrupts =3D ; + clocks =3D <&ccu CLK_BUS_DMA>, <&ccu CLK_MBUS_DMA>; + clock-names =3D "bus", "mbus"; + dma-channels =3D <16>; + dma-requests =3D <54>; + resets =3D <&ccu RST_BUS_DMA>; + #dma-cells =3D <1>; + }; + sid: efuse@3006000 { compatible =3D "allwinner,sun55i-a523-sid", "allwinner,sun50i-a64-sid"; @@ -729,6 +770,8 @@ r_i2c0: i2c@7081400 { reg =3D <0x07081400 0x400>; interrupts =3D ; clocks =3D <&r_ccu CLK_BUS_R_I2C0>; + dmas =3D <&dma 49>, <&dma 49>; + dma-names =3D "rx", "tx"; resets =3D <&r_ccu RST_BUS_R_I2C0>; pinctrl-names =3D "default"; pinctrl-0 =3D <&r_i2c_pins>; @@ -775,6 +818,19 @@ mcu_ccu: clock-controller@7102000 { #reset-cells =3D <1>; }; =20 + mcu_dma: dma-controller@7121000 { + compatible =3D "allwinner,sun55i-a523-mcu-dma", + "allwinner,sun50i-a100-dma"; + reg =3D <0x07121000 0x1000>; + interrupts =3D ; + clocks =3D <&mcu_ccu CLK_BUS_MCU_DMA>, <&mcu_ccu CLK_MCU_MBUS_DMA>; + clock-names =3D "bus", "mbus"; + dma-channels =3D <16>; + dma-requests =3D <15>; + resets =3D <&mcu_ccu RST_BUS_MCU_DMA>; + #dma-cells =3D <1>; + }; + npu: npu@7122000 { compatible =3D "vivante,gc"; reg =3D <0x07122000 0x1000>; --=20 2.47.3 From nobody Sun Feb 8 01:33:54 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1821A33342E; Mon, 20 Oct 2025 17:11:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980283; cv=none; b=upCGKA/uBNe+Hkv/mSOJakNv6+k6mqqNsDg6xZNKWe1C8qAU3W5AQsSRTb19pCWaPOgGIoaMpZAf4HwzWVTNL3+KyCSp7L6fvpc4mNxe1uUfxGD8mOomo2M++hWdKzCVlgyII+XZgdRnH8wODyepzBarQXQeToO/4/CnB+PcuCQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980283; c=relaxed/simple; bh=0ChEAhtAFbnQFbVJGkrrhKo/Uoy5YpaI4s6lIy/TvXM=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=nn3cHSfr+HtPN6pjM2R5W0Gp1h4gPkmL/ooKhpgNr6lbnd2JRSEC6VXy3iaZkxIi7IJh2/OPVryhaR2zIaj2YA7gVQy+Aj1eBcndmj/aQYYR2XjX70IJB/g4UfEpDhPwQRmSrAm6BB+eUU2j+n6R1wuXY9RYpEpvV0m30SmarB8= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=QFgPhNMI; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="QFgPhNMI" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 93322C4AF0F; Mon, 20 Oct 2025 17:11:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760980282; bh=0ChEAhtAFbnQFbVJGkrrhKo/Uoy5YpaI4s6lIy/TvXM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=QFgPhNMI2Jj90qwqd7mDU/ZGMu+ZjcHs5w0mLa+IsNtEgj0sgkZnwc4paZhm33RCU 1LptkaLyQRXZkSYB9tWLderYNPCpMIqHX/Ca4CEdsm33tL5utK7qMOZA+7gX5vHM9j 02O9+o9Olcw2OfJJsLClQ1mmOXwIdW//v02t0gaiaWWOu36vhXhPZfoAImpEDw2iKC k84LiAP8JBU9+ocen1vnga+nSR8ELeXrvBFsPLT30hR5/g+w/HhSSJyniNHy1rlEO9 F44qxeo4PQAcV9RGRUpNv9fG+TDjXiAZCaKNWMDQp6+Z5pcyUOa59afKNKQTTLsKY9 sRSdJjineEy7A== Received: by wens.tw (Postfix, from userid 1000) id 667A65FEEE; Tue, 21 Oct 2025 01:11:18 +0800 (CST) From: Chen-Yu Tsai To: Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Mark Brown , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Vinod Koul Cc: linux-sunxi@lists.linux.dev, linux-sound@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 08/11] arm64: dts: allwinner: a523: Add device node for SPDIF block Date: Tue, 21 Oct 2025 01:10:54 +0800 Message-ID: <20251020171059.2786070-9-wens@kernel.org> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20251020171059.2786070-1-wens@kernel.org> References: <20251020171059.2786070-1-wens@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The A523 has a SPDIF interface that is capable of both playback and capture. Add a node for it. Signed-off-by: Chen-Yu Tsai Acked-by: Jernej Skrabec --- arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi b/arch/arm64/bo= ot/dts/allwinner/sun55i-a523.dtsi index 8edbd3873199..33f991dbd00b 100644 --- a/arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi +++ b/arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi @@ -818,6 +818,21 @@ mcu_ccu: clock-controller@7102000 { #reset-cells =3D <1>; }; =20 + spdif: spdif@7116000 { + compatible =3D "allwinner,sun55i-a523-spdif"; + reg =3D <0x07116000 0x400>; + interrupts =3D ; + clocks =3D <&mcu_ccu CLK_BUS_MCU_SPDIF>, + <&mcu_ccu CLK_MCU_SPDIF_TX>, + <&mcu_ccu CLK_MCU_SPDIF_RX>; + clock-names =3D "apb", "tx", "rx"; + resets =3D <&mcu_ccu RST_BUS_MCU_SPDIF>; + dmas =3D <&mcu_dma 2>, <&mcu_dma 2>; + dma-names =3D "rx", "tx"; + #sound-dai-cells =3D <0>; + status =3D "disabled"; + }; + mcu_dma: dma-controller@7121000 { compatible =3D "allwinner,sun55i-a523-mcu-dma", "allwinner,sun50i-a100-dma"; --=20 2.47.3 From nobody Sun Feb 8 01:33:54 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 34553333434; Mon, 20 Oct 2025 17:11:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980283; cv=none; b=WsDRUfoHv/nO7ng7UiGTTIpqLo2KQOot0iGEcw66/2041+lmRDlEFbCQEauTqpYoUjR6tLMSB76m4xk0cgJqXxLt/POOGoNrpKp7oRC26LG5RlnXomWoBDS9UK6j6RwEBxxao7vpfOPi/vC162nyYDkz5I1Z3u9l9OHsh5zLh+0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980283; c=relaxed/simple; bh=DgO/6s23HKe1T0jTyCsYw+u/wOfS3lW2Y2hvszSMnJM=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=lt4QU4v4tXglBZXdZusJlyyrZMbIYB16eiDLATfS7BzQhMRVWJAuaWLft90soCIro7yG93DT3c2f3tFwPSpilAklSW6NfwJoucEg7qs1b10xzp1b8mp2o3OhkBmEMWv/auMbRO/4tyek1FmLOLPB6KqvEwYQo8L2mhktqX6cRVY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=QSEnPIoh; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="QSEnPIoh" Received: by smtp.kernel.org (Postfix) with ESMTPSA id AD3C4C2BC86; Mon, 20 Oct 2025 17:11:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760980282; bh=DgO/6s23HKe1T0jTyCsYw+u/wOfS3lW2Y2hvszSMnJM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=QSEnPIohF37wfJmmGhUvzPGg+MuBGgtVAEMgt9nAUiAoBxrLCPMejbRItaDmliCiA Q/7GkHNyA4K4CWwbFBBQYLDtY7jDfhUMI91zGcQTeDEMj0XA3B2L7+ul+lAcAVmw0i jHgL8FolkHsEemQu+GNtvQGRtpgd0Vciwh4CAKFjoSwowjYpRbII7fxZgOTEry6WGd ZX/qXI7nC/DUoU+oJjsHuCE1IRXAXZwQ+BlQF6W06Heny0x2fIqDuRojAOdlAXFNce pJjf6FSzv6sRTA0uwKLeWbvPgh7AbqGYkEgQMDzncjxuo+meIf9DrNxFN5FOR9FZkb 6/Zc/BO4VKzbA== Received: by wens.tw (Postfix, from userid 1000) id 7039A5FF03; Tue, 21 Oct 2025 01:11:18 +0800 (CST) From: Chen-Yu Tsai To: Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Mark Brown , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Vinod Koul Cc: linux-sunxi@lists.linux.dev, linux-sound@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 09/11] arm64: dts: allwinner: a523: Add device nodes for I2S controllers Date: Tue, 21 Oct 2025 01:10:55 +0800 Message-ID: <20251020171059.2786070-10-wens@kernel.org> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20251020171059.2786070-1-wens@kernel.org> References: <20251020171059.2786070-1-wens@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The A523 family of SoCs have four I2S controllers capable of both playback and capture. The user manual also implies that I2S2 also outputs to the eDP interface controller. Add device nodes for all of them. Signed-off-by: Chen-Yu Tsai Acked-by: Jernej Skrabec --- .../arm64/boot/dts/allwinner/sun55i-a523.dtsi | 56 +++++++++++++++++++ 1 file changed, 56 insertions(+) diff --git a/arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi b/arch/arm64/bo= ot/dts/allwinner/sun55i-a523.dtsi index 33f991dbd00b..eea9ce83783c 100644 --- a/arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi +++ b/arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi @@ -818,6 +818,62 @@ mcu_ccu: clock-controller@7102000 { #reset-cells =3D <1>; }; =20 + i2s0: i2s@7112000 { + compatible =3D "allwinner,sun55i-a523-i2s", + "allwinner,sun50i-r329-i2s"; + reg =3D <0x07112000 0x1000>; + interrupts =3D ; + clocks =3D <&mcu_ccu CLK_BUS_MCU_I2S0>, <&mcu_ccu CLK_MCU_I2S0>; + clock-names =3D "apb", "mod"; + resets =3D <&mcu_ccu RST_BUS_MCU_I2S0>; + dmas =3D <&mcu_dma 3>, <&mcu_dma 3>; + dma-names =3D "rx", "tx"; + #sound-dai-cells =3D <0>; + status =3D "disabled"; + }; + + i2s1: i2s@7113000 { + compatible =3D "allwinner,sun55i-a523-i2s", + "allwinner,sun50i-r329-i2s"; + reg =3D <0x07113000 0x1000>; + interrupts =3D ; + clocks =3D <&mcu_ccu CLK_BUS_MCU_I2S1>, <&mcu_ccu CLK_MCU_I2S1>; + clock-names =3D "apb", "mod"; + resets =3D <&mcu_ccu RST_BUS_MCU_I2S1>; + dmas =3D <&mcu_dma 4>, <&mcu_dma 4>; + dma-names =3D "rx", "tx"; + #sound-dai-cells =3D <0>; + status =3D "disabled"; + }; + + i2s2: i2s@7114000 { + compatible =3D "allwinner,sun55i-a523-i2s", + "allwinner,sun50i-r329-i2s"; + reg =3D <0x07114000 0x1000>; + interrupts =3D ; + clocks =3D <&mcu_ccu CLK_BUS_MCU_I2S2>, <&mcu_ccu CLK_MCU_I2S2>; + clock-names =3D "apb", "mod"; + resets =3D <&mcu_ccu RST_BUS_MCU_I2S2>; + dmas =3D <&mcu_dma 5>, <&mcu_dma 5>; + dma-names =3D "rx", "tx"; + #sound-dai-cells =3D <0>; + status =3D "disabled"; + }; + + i2s3: i2s@7115000 { + compatible =3D "allwinner,sun55i-a523-i2s", + "allwinner,sun50i-r329-i2s"; + reg =3D <0x07115000 0x1000>; + interrupts =3D ; + clocks =3D <&mcu_ccu CLK_BUS_MCU_I2S3>, <&mcu_ccu CLK_MCU_I2S3>; + clock-names =3D "apb", "mod"; + resets =3D <&mcu_ccu RST_BUS_MCU_I2S3>; + dmas =3D <&mcu_dma 6>, <&mcu_dma 6>; + dma-names =3D "rx", "tx"; + #sound-dai-cells =3D <0>; + status =3D "disabled"; + }; + spdif: spdif@7116000 { compatible =3D "allwinner,sun55i-a523-spdif"; reg =3D <0x07116000 0x400>; --=20 2.47.3 From nobody Sun Feb 8 01:33:54 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1814033342D; Mon, 20 Oct 2025 17:11:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980283; cv=none; b=DIdPmD10y+L32kMT1lFSlzmH9FYYmpFmcZbxr73QpqO6xUb9l5e03qxMzXPbEa/3/jiih4pWB2T0Ka0dqKdFcPdu5WJAD0/Ak4ECwZQKf46vwmPCSX48i5obGr627e/TZWjyEt4RbbmauDNgN9YLKgqRYD4hrmdwGAJVnBCTG9Q= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980283; c=relaxed/simple; bh=JAXFSTXHoi2lWkQbmUxgDURhf5LRyBjzq6/sRld0KGE=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=Wtb84kPl9jCOhDokoYyxoHAU6LxrCi2BNKOWY4bkochz3RHtH70hq105xsla7ru0h3I9edEPxFHY1WEZfrQh7hxfOvKOcaPsmHlPV241x6F36VryL1XL51XiSsINaLnMknT9FkR+Mq2pte41HyibxRv9ilXCy98sxC90xWhNBcc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=qhSYF2x1; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="qhSYF2x1" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9EF48C2BCB1; Mon, 20 Oct 2025 17:11:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760980282; bh=JAXFSTXHoi2lWkQbmUxgDURhf5LRyBjzq6/sRld0KGE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=qhSYF2x18gezxn8W9SgUF6hy6rUHBaXOg6ph2VjiEAx29wvX5U5Oa05T2lw7reI/n kn1ZTDIbFT7UvV0xitDjxSv1SiFcBxxt2I6sNK6SG1hil/wKHdXC5b8ZYPeeV6Wost cNvEU/VSA9UkcIsVT9MXgnSHiEhV6/+q3iExPXSj/YcNmzsO8CyXwxC+LJiJj+CnYh 24H2ACtsEv10HLPnZDIBB17J91hBsKeZwhaMdg5FwDgPXkvKZiIrSiu2RxVlLoMo2T dTamHu9JEDL6WzK7OshtVzyzAdA4KY/Gwa7pD7e8XbD3TC3vy/PqcSSFsGu6JBL9h5 6V+cb5GCVcHOQ== Received: by wens.tw (Postfix, from userid 1000) id 770105FEC6; Tue, 21 Oct 2025 01:11:18 +0800 (CST) From: Chen-Yu Tsai To: Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Mark Brown , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Vinod Koul Cc: linux-sunxi@lists.linux.dev, linux-sound@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 10/11] arm64: dts: allwinner: a523: Add I2S2 pins on PI pin group Date: Tue, 21 Oct 2025 01:10:56 +0800 Message-ID: <20251020171059.2786070-11-wens@kernel.org> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20251020171059.2786070-1-wens@kernel.org> References: <20251020171059.2786070-1-wens@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The Radxa Cubie A5E exposes I2S2 through the PI pin group on the 40-pin GPIO header. Add a pinmux setting for it so potential users can directly reference it. Signed-off-by: Chen-Yu Tsai Acked-by: Jernej Skrabec --- arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi b/arch/arm64/bo= ot/dts/allwinner/sun55i-a523.dtsi index eea9ce83783c..cebd8e16e845 100644 --- a/arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi +++ b/arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi @@ -145,6 +145,14 @@ pio: pinctrl@2000000 { interrupt-controller; #interrupt-cells =3D <3>; =20 + /omit-if-no-ref/ + i2s2_pi_pins: i2s2-pi-pins { + pins =3D "PI2", "PI3", "PI4", "PI5"; + allwinner,pinmux =3D <5>; + function =3D "i2s2"; + bias-disable; + }; + mmc0_pins: mmc0-pins { pins =3D "PF0" ,"PF1", "PF2", "PF3", "PF4", "PF5"; allwinner,pinmux =3D <2>; --=20 2.47.3 From nobody Sun Feb 8 01:33:54 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 344C93321A3; Mon, 20 Oct 2025 17:11:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980283; cv=none; b=DJZS4jICjWXofzbQMHadpaPSpsgcm7bNvwvzdOlLiVwN/IB6MPyQ46NaOpSqNPX/lPPVzTBhryJ70cYpjy/t6SI1VE9o4q321454LKJRr9wLtOdMU+F7+kXeK/qUk4pOSqhBP8TuGe4p6T9UPZUADVohX0tbYo8S+AErOnYBpV8= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760980283; c=relaxed/simple; bh=7WylpHCfl5v2xSL09jxwrG9Ik/L6u+sN2kDjKM+sdbI=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=O4N186eKhWzJDqTvjLwZlVGQoGTEMaEe1uI+tX+Y3caD4djuDHty+gq3SrbaCRjP6W0TqvNOUYtMdjS1QMoVsv9K+yCNXvKMVyfpNQiD/a2MCNu7KbwopegSy7bPB4Ct32OCHLJdlNuhG9MpJtv9ZI8/6/9D7xtMGXQhGBiT0b0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=PJrLsn+g; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="PJrLsn+g" Received: by smtp.kernel.org (Postfix) with ESMTPSA id B2964C16AAE; Mon, 20 Oct 2025 17:11:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760980282; bh=7WylpHCfl5v2xSL09jxwrG9Ik/L6u+sN2kDjKM+sdbI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=PJrLsn+galda3bYPgMdWQJEffSywb41/LmjAd3z8v3a1YlYtdfLc559jdDWnv+Wig V9XGVO7dvkaKETtdhrtDbwL1y9p4bGq0oaIm1VZnnsL3gxWWMGyB4BYIpznNMbhv9/ iE3GnEpXGzgF5rKyQepzeFz28YxLcHMSmpunD2BzmOPrZr9ODGzvMSautCJ+vgyBvn 5dFRNlAsNBy9vXs69lt1bt7xpy3CRUCo5IOxKaFLISOyUIW2HQwXFGsqjT3Zr4l5l7 hPMWkX+bX1Vqa+cvLZ/wNKrCZeWN06GAe3D4bkHjNCajAywnufCgqFk8G/JKeMnkvB Bf6MvlnlxwuVw== Received: by wens.tw (Postfix, from userid 1000) id 811E45FF56; Tue, 21 Oct 2025 01:11:18 +0800 (CST) From: Chen-Yu Tsai To: Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Mark Brown , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Vinod Koul Cc: linux-sunxi@lists.linux.dev, linux-sound@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 11/11] [EXAMPLE] arm64: dts: allwinner: a527-cubie-a5e: Enable I2S and SPDIF output Date: Tue, 21 Oct 2025 01:10:57 +0800 Message-ID: <20251020171059.2786070-12-wens@kernel.org> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20251020171059.2786070-1-wens@kernel.org> References: <20251020171059.2786070-1-wens@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" This is an example change. The Radxa Cubie A5E exposes I2S2 and SPDIF on the 40-pin header. Enable both. In this example, I2S2 is connected to adafruit speaker bonnet, which sports a pair of MAX98357A for speaker amplication. SPDIF is connected to a SPDIF interface card for PCs, which has both coaxial and optical outputs. The output was connected via optical cable to a dumb SPDIF to analog audio converter. Signed-off-by: Chen-Yu Tsai --- .../dts/allwinner/sun55i-a527-cubie-a5e.dts | 52 +++++++++++++++++++ 1 file changed, 52 insertions(+) diff --git a/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts b/arch= /arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts index bfdf1728cd14..828d101d28e8 100644 --- a/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts +++ b/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts @@ -64,6 +64,46 @@ reg_usb_vbus: vbus { gpio =3D <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */ enable-active-high; }; + + codec: audio-codec { + compatible =3D "maxim,max98360a"; + #sound-dai-cells =3D <0>; + }; + + sound-i2s { + compatible =3D "simple-audio-card"; + simple-audio-card,name =3D "I2S"; + simple-audio-card,format =3D "left_j"; + simple-audio-card,bitclock-master =3D <&dailink_cpu>; + simple-audio-card,frame-master =3D <&dailink_cpu>; + simple-audio-card,mclk-fs =3D <128>; + + dailink_cpu: simple-audio-card,cpu { + sound-dai =3D <&i2s2>; + }; + + dailink0_master: simple-audio-card,codec { + sound-dai =3D <&codec>; + }; + }; + + sound-spdif { + compatible =3D "simple-audio-card"; + simple-audio-card,name =3D "spdif-out"; + + simple-audio-card,cpu { + sound-dai =3D <&spdif>; + }; + + simple-audio-card,codec { + sound-dai =3D <&spdif_out>; + }; + }; + + spdif_out: spdif-out { + #sound-dai-cells =3D <0>; + compatible =3D "linux,spdif-dit"; + }; }; =20 &ehci0 { @@ -101,6 +141,12 @@ &gpu { status =3D "okay"; }; =20 +&i2s2 { + pinctrl-names =3D "default"; + pinctrl-0 =3D <&i2s2_pi_pins>; + status =3D "okay"; +}; + &mdio0 { ext_rgmii0_phy: ethernet-phy@1 { compatible =3D "ethernet-phy-ieee802.3-c22"; @@ -344,6 +390,12 @@ &r_pio { vcc-pm-supply =3D <®_aldo3>; }; =20 +&spdif { + pinctrl-names =3D "default"; + pinctrl-0 =3D <&spdif_out_pi_pin>; + status =3D "okay"; +}; + &uart0 { pinctrl-names =3D "default"; pinctrl-0 =3D <&uart0_pb_pins>; --=20 2.47.3