Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp3279020yba; Tue, 23 Apr 2019 00:32:53 -0700 (PDT) X-Google-Smtp-Source: APXvYqxTfF4OqLQeiY4dq6jnmIAsbow0zJ31HyeihdpE+AWwMitUYg7dEwDj1nQAQCzs95OIBP/1 X-Received: by 2002:a63:d607:: with SMTP id q7mr13899460pgg.213.1556004773436; Tue, 23 Apr 2019 00:32:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1556004773; cv=none; d=google.com; s=arc-20160816; b=cWC5+pNyikhBoBQsWTZpYT6emehR6udwtUfSlMe7mAvNwio+ts29cf4uu2M2IW3cek 24udEQiDSWSQBO7rzXddsSShbT4I25rJfJo7S4PJBTJw2UiXr89gif79HpWsiQBxk6+N e7Gzmvh+2bd6Oac594Xj4ld2dGaWhDReRfKlU+B5Sl6lhtamjayQQGyyW02agsTJIyk5 faH6ozEDGKkvk64/siLQo2sqoXIJ/mMu8b8dlkA1gCfE1KMF5DSxLW2uiG+KST1M/RmE mu2Z4a+898qkjjFHM5zeQP9ohfqHJSJH2L3ufUWLoWxeFmqiiaF327abtrW1QKwTP/r7 wkig== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=jpxX4GIxqEPxo0pvJY5t/xcCi1g7qm7nLA07aIRFAzA=; b=jMNmqz8AZfGwK996obLL4SUeHqyuNUDHB3rxrTjkz7u1/K99xZnrctviI7FMGPcmNX g/+IloLLJ7IQ1xOxAQkBMkB+USpzc0ThToQNZL/09nLP9atTtJ+KMgIwpzXbEQhInqiY 1TLXo3x4gUgaLirAiVt/BllgYszt3RryjfcO3gcYsTApf881b2+/R9CBig4Iw6o3u0Wz jwRF1FG46yp9JD0JlGJgZHcfE2m1SoC40ZdiTtaXxU/fryBvqnmoSQSl3iIdEmeOqESo jeIhtkQRURImK+JfghhyVPLim98mkBx9FhmwcTlqPyJs8F+HltyKMSYYEvgTh/gxJeKU s9Lw== 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 d5si13786241pgh.516.2019.04.23.00.32.37; Tue, 23 Apr 2019 00:32:53 -0700 (PDT) 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 S1726426AbfDWHbl (ORCPT + 99 others); Tue, 23 Apr 2019 03:31:41 -0400 Received: from metis.ext.pengutronix.de ([85.220.165.71]:40553 "EHLO metis.ext.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726155AbfDWHbk (ORCPT ); Tue, 23 Apr 2019 03:31:40 -0400 Received: from pty.hi.pengutronix.de ([2001:67c:670:100:1d::c5]) by metis.ext.pengutronix.de with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hIptx-0006tY-37; Tue, 23 Apr 2019 09:31:37 +0200 Received: from mfe by pty.hi.pengutronix.de with local (Exim 4.89) (envelope-from ) id 1hIptl-0007Uk-Ag; Tue, 23 Apr 2019 09:31:25 +0200 Date: Tue, 23 Apr 2019 09:31:25 +0200 From: Marco Felsch To: Daniel Baluta Cc: Daniel Baluta , "shawnguo@kernel.org" , "mark.rutland@arm.com" , Aisheng Dong , Peng Fan , Anson Huang , "devicetree@vger.kernel.org" , "s.hauer@pengutronix.de" , "linux-kernel@vger.kernel.org" , "robh+dt@kernel.org" , dl-linux-imx , "kernel@pengutronix.de" , "festevam@gmail.com" , "S.j. Wang" , "linux-arm-kernel@lists.infradead.org" Subject: Re: [PATCH v2 2/2] arm64: dts: imx8mm-evk: Enable audio codec wm8524 Message-ID: <20190423073125.hd76umcjnfheohgb@pengutronix.de> References: <20190422193542.2853-1-daniel.baluta@nxp.com> <20190422193542.2853-3-daniel.baluta@nxp.com> <20190423051738.tmyto7nvm4w5zt4r@pengutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Sent-From: Pengutronix Hildesheim X-URL: http://www.pengutronix.de/ X-IRC: #ptxdist @freenode X-Accept-Language: de,en X-Accept-Content-Type: text/plain X-Uptime: 09:26:24 up 94 days, 12:08, 74 users, load average: 0.12, 0.09, 0.02 User-Agent: NeoMutt/20170113 (1.7.2) X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::c5 X-SA-Exim-Mail-From: mfe@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Daniel, On 19-04-23 09:22, Daniel Baluta wrote: > Hi Marco, > > On Tue, Apr 23, 2019 at 8:19 AM Marco Felsch wrote: > > > > Hi Daniel, > > > > On 19-04-22 19:36, Daniel Baluta wrote: > > > i.MX8MM has one wm8524 audio codec connected with > > > SAI3 digital audio interface. > > > > > > This patch uses simple-card machine driver in order > > > to enable wm8524 codec. > > > > > > We need to set: > > > * SAI3 pinctrl configuration > > > * clock hierarchy > > > * codec node > > > * simple-card configuration > > > > > > Signed-off-by: Daniel Baluta > > > --- > > > arch/arm64/boot/dts/freescale/imx8mm-evk.dts | 48 ++++++++++++++++++++ > > > 1 file changed, 48 insertions(+) > > > > > > diff --git a/arch/arm64/boot/dts/freescale/imx8mm-evk.dts b/arch/arm64/boot/dts/freescale/imx8mm-evk.dts > > > index 2d5d89475b76..207b13266a96 100644 > > > --- a/arch/arm64/boot/dts/freescale/imx8mm-evk.dts > > > +++ b/arch/arm64/boot/dts/freescale/imx8mm-evk.dts > > > @@ -37,6 +37,35 @@ > > > gpio = <&gpio2 19 GPIO_ACTIVE_HIGH>; > > > enable-active-high; > > > }; > > > + > > > + wm8524: audio-codec { > > > + #sound-dai-cells = <0>; > > > + compatible = "wlf,wm8524"; > > > + wlf,mute-gpios = <&gpio5 21 GPIO_ACTIVE_LOW>; > > > > I would mux the gpio where I use them. > > I'm not sure I understand this. Can you provide an example. Just adding a princtrl-0 and pinctrl-names entry to mux the gpio here rather than within the sai node. > > > > > + }; > > > + > > > + sound-wm8524 { > > > + compatible = "simple-audio-card"; > > > + simple-audio-card,name = "wm8524-audio"; > > > + simple-audio-card,format = "i2s"; > > > + simple-audio-card,frame-master = <&cpudai>; > > > + simple-audio-card,bitclock-master = <&cpudai>; > > > + simple-audio-card,widgets = > > > + "Line", "Left Line Out Jack", > > > + "Line", "Right Line Out Jack"; > > > + simple-audio-card,routing = > > > + "Left Line Out Jack", "LINEVOUTL", > > > + "Right Line Out Jack", "LINEVOUTR"; > > > + > > > + cpudai: simple-audio-card,cpu { > > > + sound-dai = <&sai3>; > > > + }; > > > + > > > + link_codec: simple-audio-card,codec { > > > > Can you drop that phandle? > > I see your point here. But for symmetry and consistency with > imx8mm-evk I would prefer > to keep it like that. > > https://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux.git/tree/arch/arm64/boot/dts/freescale/imx8mq-evk.dts?h=for-next#n59 > Got your point but I think that the evk dts will be used as base for future dts. Instead of keep them here I would send a patch to drop the phandle in the imx8mq-evk.dts since it isn't necessary. Regards, Marco