From patchwork Mon Aug 14 22:06:50 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lori Hikichi X-Patchwork-Id: 801353 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=devicetree-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=broadcom.com header.i=@broadcom.com header.b="c+tUm9ry"; dkim-atps=neutral Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 3xWV9f4klQz9s65 for ; Tue, 15 Aug 2017 08:08:22 +1000 (AEST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752734AbdHNWGU (ORCPT ); Mon, 14 Aug 2017 18:06:20 -0400 Received: from mail-qt0-f176.google.com ([209.85.216.176]:38407 "EHLO mail-qt0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752715AbdHNWGS (ORCPT ); Mon, 14 Aug 2017 18:06:18 -0400 Received: by mail-qt0-f176.google.com with SMTP id t37so59071752qtg.5 for ; Mon, 14 Aug 2017 15:06:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=samD0U/aWboayIcrWwNFMhQcNtR37NW28a9N40pXrOE=; b=c+tUm9ryQg+RvHG7FTa9nVUmCn3TY8wHx7+j+lKQ8yCGYineWQaaS8QMW8o25z0t9Z O8iw4Damth9QPM+VGfrou44Q2doT3bl4zgQbtNOu/JqDifk1sPx1C5rXJlUUod2fCe72 TjSOgUnpU6+zJ+d+tiRYw1K19nthZiaPxuN7M= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=samD0U/aWboayIcrWwNFMhQcNtR37NW28a9N40pXrOE=; b=PV86ZXNaykxw8HahU0JfUyUn0VKihqciXxDDwKe4mf49QOZr54MGPD8nHFGYdzj0iU Ag8ffC3EP4jTsNo6XIKgFOeEqOJx3sWrUobplcCGYtXedcDGDdyS+/JLmEIK6Nb+Iezb ivNxkomMJH+dawvDgD3ZaVtC/k9KC8cVwP2cveh5qV2fU//kTjFaqwLqUHFULHbizITp U3navV3cIMXjHEL1T4/tg903yCpqsTeDuextCx5KJWdh9qODGnoNV0A5zhcWFKLMKJYu YU6uF3cYImuKWzh0kzA5HOtBVn5w2h12ANkNGkusvO151HGedZhE6v7s03xysXWkNgEF ODwA== X-Gm-Message-State: AHYfb5if/1Ej/os7dXDS+3uuAyqUXxkMRwZ3xXnqGKseKYtguimIxc0g Scq28N9ArShq0OSP X-Received: by 10.237.63.246 with SMTP id w51mr34384867qth.308.1502748377422; Mon, 14 Aug 2017 15:06:17 -0700 (PDT) Received: from lbrmn-ubu57.dhcp.broadcom.net ([192.19.224.250]) by smtp.gmail.com with ESMTPSA id v50sm5735105qtb.10.2017.08.14.15.06.12 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 14 Aug 2017 15:06:17 -0700 (PDT) From: Lori Hikichi To: Liam Girdwood , Mark Brown , Rob Herring , Mark Rutland , Ray Jui , Scott Branden , Jon Mason , bcm-kernel-feedback-list@broadcom.com, Jaroslav Kysela , Takashi Iwai Cc: alsa-devel@alsa-project.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Lori Hikichi Subject: [PATCH 2/9] ASoC: cygnus: Update bindings for audio clock changes Date: Mon, 14 Aug 2017 15:06:50 -0700 Message-Id: <1502748417-26417-3-git-send-email-lori.hikichi@broadcom.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1502748417-26417-1-git-send-email-lori.hikichi@broadcom.com> References: <1502748417-26417-1-git-send-email-lori.hikichi@broadcom.com> Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Allow each audio port to select which clock (if any) it wants to use. Signed-off-by: Lori Hikichi --- .../bindings/sound/brcm,cygnus-audio.txt | 70 ++++++++++++++-------- 1 file changed, 45 insertions(+), 25 deletions(-) diff --git a/Documentation/devicetree/bindings/sound/brcm,cygnus-audio.txt b/Documentation/devicetree/bindings/sound/brcm,cygnus-audio.txt index b139e66..2ef2f2c 100644 --- a/Documentation/devicetree/bindings/sound/brcm,cygnus-audio.txt +++ b/Documentation/devicetree/bindings/sound/brcm,cygnus-audio.txt @@ -9,19 +9,28 @@ Required properties: Valid names are "aud" and "i2s_in". "aud" contains a set of DMA, I2S_OUT and SPDIF registers. "i2s_in" contains a set of I2S_IN registers. - - clocks: PLL and leaf clocks used by audio ports - - assigned-clocks: PLL and leaf clocks - - assigned-clock-parents: parent clocks of the assigned clocks - (usually the PLL) - - assigned-clock-rates: List of clock frequencies of the - assigned clocks - - clock-names: names of 3 leaf clocks used by audio ports - Valid names are "ch0_audio", "ch1_audio", "ch2_audio" - interrupts: audio DMA interrupt number +Optional properties: + - assigned-clocks: only valid choice is audiopll + - assigned-clock-rates: clock frequency for audiopll +If none of the ports need an internal master clock then there no need to +initialize the pll clock. + + SSP Subnode properties: -- reg: The index of ssp port interface to use - Valid value are 0, 1, 2, or 3 (for spdif) +Required: + - reg: The index of ssp port interface to use + Valid value are 0, 1, 2, or 3 (for spdif) +Optional: + - clocks: clock used by audio port + one of the audiopll outputs (see brcm,iproc-clocks.txt). + - clock-names: Must be "ssp_clk" + - brcm,ssp-clk-mux = Needed if a clock is named and used. This value is + used to program the mux within the audio driver which selects + the incoming clock. Here is the mapping. + audio_pll output 0 = 0, output 1 = 1, and output 2 = 2 + Example: cygnus_audio: audio@180ae000 { @@ -30,38 +39,49 @@ Example: #size-cells = <0>; reg = <0x180ae000 0xafd>, <0x180aec00 0x1f8>; reg-names = "aud", "i2s_in"; - clocks = <&audiopll BCM_CYGNUS_AUDIOPLL_CH0>, - <&audiopll BCM_CYGNUS_AUDIOPLL_CH1>, - <&audiopll BCM_CYGNUS_AUDIOPLL_CH2>; - assigned-clocks = <&audiopll BCM_CYGNUS_AUDIOPLL>, - <&audiopll BCM_CYGNUS_AUDIOPLL_CH0>, - <&audiopll BCM_CYGNUS_AUDIOPLL_CH1>, - <&audiopll BCM_CYGNUS_AUDIOPLL_CH2>; - assigned-clock-parents = <&audiopll BCM_CYGNUS_AUDIOPLL>; - assigned-clock-rates = <1769470191>, - <0>, - <0>, - <0>; - clock-names = "ch0_audio", "ch1_audio", "ch2_audio"; + + assigned-clocks = <&audiopll BCM_CYGNUS_AUDIOPLL>; + assigned-clock-rates = <1376255989>; + interrupts = ; ssp0: ssp_port@0 { reg = <0>; + + clocks = <&audiopll BCM_CYGNUS_AUDIOPLL_CH0>; + clock-names = "ssp_clk"; + brcm,ssp-clk-mux = <0>; + status = "okay"; }; ssp1: ssp_port@1 { reg = <1>; - status = "disabled"; + + clocks = <&audiopll BCM_CYGNUS_AUDIOPLL_CH1>; + clock-names = "ssp_clk"; + brcm,ssp-clk-mux = <1>; + + status = "okay"; }; ssp2: ssp_port@2 { reg = <2>; - status = "disabled"; + + clocks = <&audiopll BCM_CYGNUS_AUDIOPLL_CH2>; + clock-names = "ssp_clk"; + brcm,ssp-clk-mux = <2>; + + status = "okay"; }; spdif: spdif_port@3 { reg = <3>; + + clocks = <&audiopll BCM_CYGNUS_AUDIOPLL_CH2>; + clock-names = "ssp_clk"; + brcm,ssp-clk-mux = <2>; + status = "disabled"; }; };