Received: by 10.223.176.5 with SMTP id f5csp1284941wra; Fri, 2 Feb 2018 14:42:37 -0800 (PST) X-Google-Smtp-Source: AH8x227WVFE/T44HRBYdtqKk7XwwMn2We6XGysyp4Voh9EiQvqKrlfxoLTvTWzr6MJAzIJUJ6wpU X-Received: by 10.98.7.207 with SMTP id 76mr40673674pfh.130.1517611357584; Fri, 02 Feb 2018 14:42:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517611357; cv=none; d=google.com; s=arc-20160816; b=cb/nf4ZRT2OSjIZMxKNJ6bQYmVIIDVhwwrWTpQuwRywqr17b0lNOf5/iJr3VCtt1qF FpaJjMv/E9rWuT+Bz8C1bZa8UhlVXE6/yut/CBfkJxo8T/uEZyes2B0necGyFkhFWLvR 41+KquO3jxYrDmLDxLGInEviEP7KB2hskdLuF4WyrS73/jCI8ijdKQFhOhgAf3sjIciF 50t3BMP/OcgKDi1UAKflzYjGsKF+9x6a23X4lIOzizFhuaUM81PQpDhewPDiy/wp2ut+ duYBrSnVSejoZtT0bwF5ezBHByqmyhHRXxFvZWRpdK8s5BIzqbtww2xj79n09zBqx3Fa RNCA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=Yc813P2diSpFYiSHPi89GpKc1ayQ+Paj8ptMBNap04M=; b=nyIaHTnYGhKTJ5AoCuoId+OqDBb5860rPBacJBkR9CJAusA0zNiR3zJ710QsGG8kzY QZGd4WZlCDwuet/bNrZCbbtB0bVLMgpNEnAF2zVvMK0q1726RbvbevANWPQB7fKZH+ZZ TU0g3F3X8LepUzgir3Ldo04wnFTR1Cp1gqCSM3ofPNNcwXvxApyumiBwcS/25TCC0nTe 4Wq+I2OloFS6yF/73dGBXaILzyRWXAA0gPSOOYIzUATMmsb/8rA/iBzuoZlXKHszr2fW kU9CDsx9WVUXWjaFXnJzYaP2hY77YFXvCPzRCC7NJnu+cRQkMQJ8A4YV4VEgOTVRd1Pc tgIQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f4-v6si2573322plb.482.2018.02.02.14.42.21; Fri, 02 Feb 2018 14:42:37 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752336AbeBBWA5 (ORCPT + 99 others); Fri, 2 Feb 2018 17:00:57 -0500 Received: from gloria.sntech.de ([95.129.55.99]:52212 "EHLO gloria.sntech.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751809AbeBBWAw (ORCPT ); Fri, 2 Feb 2018 17:00:52 -0500 Received: from [185.46.212.50] (helo=phil.localnet) by gloria.sntech.de with esmtpsa (TLS1.1:DHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.80) (envelope-from ) id 1ehjNz-00082c-Kj; Fri, 02 Feb 2018 23:00:43 +0100 From: Heiko Stuebner To: Klaus Goger Cc: linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] arm64: dts: rockchip: enable I2S codec on rk3399-puma-haikou Date: Fri, 02 Feb 2018 23:00:37 +0100 Message-ID: <1896849.q5MJicbXVp@phil> In-Reply-To: <20180130101531.41411-1-klaus.goger@theobroma-systems.com> References: <20180130101531.41411-1-klaus.goger@theobroma-systems.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Klaus, Am Dienstag, 30. Januar 2018, 11:15:31 CET schrieb Klaus Goger: > Enable the NXP SGTL5000 audio codec on the RK3399-Q7 EVK baseboard > Haikou. > > The i2s0_2ch_bus definition is only done in the SoM dtsi as it is > missing the LRCK_RX pin (that is used otherwise) and therefore not > generic enough for the SoC dtsi. > > Signed-off-by: Klaus Goger I did fix up the small ordering issues already but then found the i2s pinctrl issue below, which will need a slightly bigger change and thus a respin please. > .../arm64/boot/dts/rockchip/rk3399-puma-haikou.dts | 49 ++++++++++++++++++++++ > arch/arm64/boot/dts/rockchip/rk3399-puma.dtsi | 18 ++++++++ > 2 files changed, 67 insertions(+) > > diff --git a/arch/arm64/boot/dts/rockchip/rk3399-puma-haikou.dts b/arch/arm64/boot/dts/rockchip/rk3399-puma-haikou.dts > index 9a7486058455..060c6be7d7e3 100644 > --- a/arch/arm64/boot/dts/rockchip/rk3399-puma-haikou.dts > +++ b/arch/arm64/boot/dts/rockchip/rk3399-puma-haikou.dts > @@ -61,6 +61,22 @@ > }; > }; > > + i2s0_sound { > + compatible = "simple-audio-card"; > + simple-audio-card,format = "i2s"; > + simple-audio-card,name = "Haikou,I2S-codec"; > + simple-audio-card,mclk-fs = <512>; > + simple-audio-card,cpu { > + sound-dai = <&i2s0>; > + frame-master; > + bitclock-master; > + }; > + simple-audio-card,codec { > + sound-dai = <&sgtl5000>; > + clocks = <&sgtl5000_clk>; > + }; > + }; > + odering and a bit of spacing: + i2s0_sound { + compatible = "simple-audio-card"; + simple-audio-card,format = "i2s"; + simple-audio-card,name = "Haikou,I2S-codec"; + simple-audio-card,mclk-fs = <512>; + + simple-audio-card,codec { + clocks = <&sgtl5000_clk>; + sound-dai = <&sgtl5000>; + }; + + simple-audio-card,cpu { + bitclock-master; + frame-master; + sound-dai = <&i2s0>; + }; + }; > dc_12v: dc-12v { > compatible = "regulator-fixed"; > regulator-name = "dc_12v"; > @@ -110,6 +148,17 @@ > &i2c4 { > status = "okay"; > clock-frequency = <400000>; > + > + sgtl5000: codec@0a { > + #sound-dai-cells = <0>; > + compatible = "fsl,sgtl5000"; > + reg = <0x0a>; > + VDDA-supply = <&vdda_codec>; > + VDDIO-supply = <&vdda_codec>; > + VDDD-supply = <&vddd_codec>; > + clocks = <&sgtl5000_clk>; > + status = "okay"; > + }; ordering again + sgtl5000: codec@0a { + compatible = "fsl,sgtl5000"; + reg = <0x0a>; + clocks = <&sgtl5000_clk>; + #sound-dai-cells = <0>; + VDDA-supply = <&vdda_codec>; + VDDIO-supply = <&vdda_codec>; + VDDD-supply = <&vddd_codec>; + status = "okay"; + }; > }; > > &i2c6 { > diff --git a/arch/arm64/boot/dts/rockchip/rk3399-puma.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-puma.dtsi > index 1fc5060d7027..a3fcb803ff69 100644 > --- a/arch/arm64/boot/dts/rockchip/rk3399-puma.dtsi > +++ b/arch/arm64/boot/dts/rockchip/rk3399-puma.dtsi > @@ -435,6 +435,14 @@ > }; > }; > > +&i2s0 { > + #sound-dai-cells = <0>; > + status = "okay"; > + pinctrl-0 = <&i2s0_2ch_bus>; > + rockchip,playback-channels = <2>; > + rockchip,capture-channels = <2>; > +}; ordering +&i2s0 { + pinctrl-0 = <&i2s0_2ch_bus>; + rockchip,playback-channels = <2>; + rockchip,capture-channels = <2>; + #sound-dai-cells = <0>; + status = "okay"; +}; > @@ -461,6 +469,16 @@ > }; > }; > > + i2s0 { > + i2s0_2ch_bus: i2s0_2ch_bus { node names should use dashes, so i2s0_2ch_bus: i2s0-2ch-bus But also, could you define the generic i2s0-2ch-bus (incl the phandle) in rk3399.dtsi in a first patch and just override it here to not use that LRCK_RX pin please? Thanks Heiko