From patchwork Sun Jun 18 12:40:49 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Rezvanov X-Patchwork-Id: 9794803 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 4630B6032B for ; Sun, 18 Jun 2017 12:42:41 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3278F2843F for ; Sun, 18 Jun 2017 12:42:41 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 146CC28498; Sun, 18 Jun 2017 12:42:41 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,FREEMAIL_FROM autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 585032843F for ; Sun, 18 Jun 2017 12:42:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: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=Jm6CqWNrajxNyPzmHmj9u/bv9En+Sb7VO+SZ/sDEHQE=; b=Rz8ucx6MS33WVmnb1QwO8EvDXj YfU7MRGWYFREFdCZERQih+D4UqXTHNulgPZpwZCnfE/uJx+PKKFNyxAuyyP9/AFe5HyZO0s97pT3X +2pCxmMqvMQJHSe+MN5itw7P1i6Lj4iU86akFqdFyvwIRimgcvxtbUBDtvCvIdm9az61B51+sI6HI yoHIxCqSiN1++ZzM0CLCw/er1vQjlAtIXdx0xBtGiikrpFqojMjwBwK8ojMycHO5xYHjxg8OGLuxU Sac05L9Tl1VTNjvSmz/pKKrI31BEL30mHRYZbj/iWIxkaOFKBPme9WzQWni1GvihTImrDDstrcTdA 9tg/rwtw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1dMZXH-0005o6-52; Sun, 18 Jun 2017 12:42:35 +0000 Received: from forward14j.cmail.yandex.net ([2a02:6b8:0:1630::b4]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1dMZWq-0005mg-Sv for linux-arm-kernel@lists.infradead.org; Sun, 18 Jun 2017 12:42:11 +0000 Received: from smtp3m.mail.yandex.net (smtp3m.mail.yandex.net [IPv6:2a02:6b8:0:2519::125]) by forward14j.cmail.yandex.net (Yandex) with ESMTP id C1B2B21ABB; Sun, 18 Jun 2017 15:41:37 +0300 (MSK) Received: from smtp3m.mail.yandex.net (localhost.localdomain [127.0.0.1]) by smtp3m.mail.yandex.net (Yandex) with ESMTP id 2B9AD2840E15; Sun, 18 Jun 2017 15:41:35 +0300 (MSK) Received: by smtp3m.mail.yandex.net (nwsmtp/Yandex) with ESMTPSA id LKdVzI1CgF-fY20f8DY; Sun, 18 Jun 2017 15:41:34 +0300 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client certificate not present) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1497789694; bh=Lwjwt3pCggXKFtnqza/EVwCpM/9m9fBs0xlHW7sNAtM=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References; b=Sz/2IpzQ0KCCx5/56cUse6Cf3CmLAHS2qLPeAmfKTDKkC76yPXxs2pV0uaZWdpaZB 0Li3AnF89isAxlZulmK7nWmnAj4c0HUmNtCtC0MjIQaIZvZtWxyS5w3mMaZewCuEU8 ckVe5yhcVNIC7Vl/JIOr7BFfvK9mLv3tnZMLJ2KI= Authentication-Results: smtp3m.mail.yandex.net; dkim=pass header.i=@yandex.ru X-Yandex-ForeignMX: FR X-Yandex-Suid-Status: 1 0,1 0,1 705703002 From: Dmitry Rezvanov To: linux-arm-kernel@lists.infradead.org Subject: [PATCH] ARM: at91: dts: add AC97 support for AT91SAM9G45 Date: Sun, 18 Jun 2017 21:40:49 +0900 Message-Id: <20170618124049.6663-1-dmitry.rezvanov@yandex.ru> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170612194314.19289-1-dmitry.rezvanov@yandex.ru> References: <20170612194314.19289-1-dmitry.rezvanov@yandex.ru> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170618_054209_281927_793DC0FC X-CRM114-Status: UNSURE ( 9.94 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Dmitry Rezvanov , alexandre.belloni@free-electrons.com MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Hi, Thanks for the comments, I'm still a newbie and this is my first patch. I have made corrections in accordance with your recommendations. P.S. Regarding compatible string - since there are no other changes in the driver, I changed it to "atmel, at91sam9263-ac97c". But in my opinion, it's a bit ... weird. --- AT91SAM9G45 has an AC97 controller, but it is not described in the dts file. This patch adds AC97 node in device tree. Signed-off-by: Dmitry Rezvanov --- arch/arm/boot/dts/at91sam9g45.dtsi | 21 +++++++++++++++++++++ arch/arm/boot/dts/at91sam9m10g45ek.dts | 4 ++++ 2 files changed, 25 insertions(+) diff --git a/arch/arm/boot/dts/at91sam9g45.dtsi b/arch/arm/boot/dts/at91sam9g45.dtsi index e567d5fd3f9d..b14fd3a43027 100644 --- a/arch/arm/boot/dts/at91sam9g45.dtsi +++ b/arch/arm/boot/dts/at91sam9g45.dtsi @@ -445,6 +445,16 @@ >; /* shared pinctrl settings */ + ac97 { + pinctrl_ac97: ac97-0 { + atmel,pins = + ; /* PD9 periph A AC97CK pin */ + }; + }; + adc0 { pinctrl_adc0_adtrg: adc0_adtrg { atmel,pins = ; @@ -1029,6 +1039,17 @@ status = "disabled"; }; + ac97: sound@fffac000 { + compatible = "atmel,at91sam9263-ac97c"; + reg = <0xfffac000 0x4000>; + interrupts = <24 IRQ_TYPE_LEVEL_HIGH 4>; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_ac97>; + clocks = <&ac97_clk>; + clock-names = "ac97_clk"; + status = "disabled"; + }; + adc0: adc@fffb0000 { #address-cells = <1>; #size-cells = <0>; diff --git a/arch/arm/boot/dts/at91sam9m10g45ek.dts b/arch/arm/boot/dts/at91sam9m10g45ek.dts index 2400c99134f7..7ea6225c63ad 100644 --- a/arch/arm/boot/dts/at91sam9m10g45ek.dts +++ b/arch/arm/boot/dts/at91sam9m10g45ek.dts @@ -166,6 +166,10 @@ status = "okay"; }; + ac97: sound@fffac000 { + status = "okay"; + }; + adc0: adc@fffb0000 { pinctrl-names = "default"; pinctrl-0 = <