From patchwork Wed Dec 4 03:57:07 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alex Elder X-Patchwork-Id: 3280751 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 85EE69F373 for ; Wed, 4 Dec 2013 03:58:16 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 6655520495 for ; Wed, 4 Dec 2013 03:58:15 +0000 (UTC) Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 7938720462 for ; Wed, 4 Dec 2013 03:58:13 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1Vo3aq-0002Ks-FE; Wed, 04 Dec 2013 03:57:44 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1Vo3ai-0001Rx-9P; Wed, 04 Dec 2013 03:57:36 +0000 Received: from mail-ie0-f180.google.com ([209.85.223.180]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1Vo3ac-0001Q3-Jn for linux-arm-kernel@lists.infradead.org; Wed, 04 Dec 2013 03:57:33 +0000 Received: by mail-ie0-f180.google.com with SMTP id tp5so25625250ieb.11 for ; Tue, 03 Dec 2013 19:57:09 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:date:from:user-agent:mime-version:to :cc:subject:references:in-reply-to:content-type :content-transfer-encoding; bh=FaBzxFKiYjaGIk5ty5Jj/59Nk9fWUwNcgUsPgHKGl+k=; b=fPUVTEi/SNQWCxL+DxIeL0kl6GqJuatwmv7+ko/g4vWOIW373aKTzI6LQpYvzXvHuI ZYwjdBGw+ihVWHo2OEny2vzE1OYnPx2LjDhkz71nbqCkPfAwsggdktx/g6+B2byRSlnR j1dojd3VFKXw9TQcOGs65Fdc7Rc6E9/x438uZVSlIClHQdX5yripnD9Q/vhnAoD0HlxV ysy9Su2SunUmc7XcXNlwTyypfAWtlDhr2kDmwgYsf2ktCJsLU00Ou3DIUKi5opOlKt+i FJ9AO+wYzZE1zKmDSceJ3ZHM5bdkq1hRj2aVLgKcJtz4qklfQvgny0YBX2iIynuGY6bk mD7g== X-Gm-Message-State: ALoCoQkT6Ubv7AOyJPjrM7patJRbe1jwgrbMAHJ6AFiMetKbS3+Dx27VfccHYckN1NYd+vFYU9ID X-Received: by 10.50.29.43 with SMTP id g11mr5884241igh.25.1386129429418; Tue, 03 Dec 2013 19:57:09 -0800 (PST) Received: from [172.22.22.4] (c-71-195-31-37.hsd1.mn.comcast.net. [71.195.31.37]) by mx.google.com with ESMTPSA id w4sm2159818igb.5.2013.12.03.19.57.07 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 03 Dec 2013 19:57:08 -0800 (PST) Message-ID: <529EA813.2070208@linaro.org> Date: Tue, 03 Dec 2013 21:57:07 -0600 From: Alex Elder User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.1.1 MIME-Version: 1.0 To: Christian Daudt , Ian Campbell , Mark Rutland , Pawel Moll , Rob Herring , Rob Landley , Russell King , Stephen Warren , Mike Turquette Subject: [PATCH 3/3] ARM: dts: bcm281xx: define real clocks References: <529EA78E.7060904@linaro.org> In-Reply-To: <529EA78E.7060904@linaro.org> X-Enigmail-Version: 1.5.2 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20131203_225730_792692_4DCDDA62 X-CRM114-Status: GOOD ( 12.89 ) X-Spam-Score: -2.6 (--) Cc: devicetree@vger.kernel.org, bcm-kernel-feedback-list@broadcom.com, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-doc@vger.kernel.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Replace the "fake" clocks defined in the "bcm11351.dtsi" device tree file with real definitions backed by the new BCM281xx clock driver.. Signed-off-by: Alex Elder Reviewed-by: Matt Porter Reviewed-by: Tim Kryger --- arch/arm/boot/dts/bcm11351.dtsi | 222 ++++++++++++++++++++++++++++----------- 1 file changed, 161 insertions(+), 61 deletions(-) -- 1.7.9.5 diff --git a/arch/arm/boot/dts/bcm11351.dtsi b/arch/arm/boot/dts/bcm11351.dtsi index 1246885..b3a0535 100644 --- a/arch/arm/boot/dts/bcm11351.dtsi +++ b/arch/arm/boot/dts/bcm11351.dtsi @@ -14,6 +14,8 @@ #include #include +#include "dt-bindings/clock/bcm281xx.h" + #include "skeleton.dtsi" / { @@ -43,7 +45,7 @@ compatible = "brcm,bcm11351-dw-apb-uart", "snps,dw-apb-uart"; status = "disabled"; reg = <0x3e000000 0x1000>; - clocks = <&uartb_clk>; + clocks = <&slave_ccu BCM281XX_SLAVE_CCU_UARTB>; interrupts = ; reg-shift = <2>; reg-io-width = <4>; @@ -53,7 +55,7 @@ compatible = "brcm,bcm11351-dw-apb-uart", "snps,dw-apb-uart"; status = "disabled"; reg = <0x3e001000 0x1000>; - clocks = <&uartb2_clk>; + clocks = <&slave_ccu BCM281XX_SLAVE_CCU_UARTB2>; interrupts = ; reg-shift = <2>; reg-io-width = <4>; @@ -63,7 +65,7 @@ compatible = "brcm,bcm11351-dw-apb-uart", "snps,dw-apb-uart"; status = "disabled"; reg = <0x3e002000 0x1000>; - clocks = <&uartb3_clk>; + clocks = <&slave_ccu BCM281XX_SLAVE_CCU_UARTB3>; interrupts = ; reg-shift = <2>; reg-io-width = <4>; @@ -73,7 +75,7 @@ compatible = "brcm,bcm11351-dw-apb-uart", "snps,dw-apb-uart"; status = "disabled"; reg = <0x3e003000 0x1000>; - clocks = <&uartb4_clk>; + clocks = <&slave_ccu BCM281XX_SLAVE_CCU_UARTB4>; interrupts = ; reg-shift = <2>; reg-io-width = <4>; @@ -95,7 +97,7 @@ compatible = "brcm,kona-timer"; reg = <0x35006000 0x1000>; interrupts = ; - clocks = <&hub_timer_clk>; + clocks = <&aon_ccu BCM281XX_AON_CCU_HUB_TIMER>; }; gpio: gpio@35003000 { @@ -118,7 +120,7 @@ compatible = "brcm,kona-sdhci"; reg = <0x3f180000 0x10000>; interrupts = ; - clocks = <&sdio1_clk>; + clocks = <&master_ccu BCM281XX_MASTER_CCU_SDIO1>; status = "disabled"; }; @@ -126,7 +128,7 @@ compatible = "brcm,kona-sdhci"; reg = <0x3f190000 0x10000>; interrupts = ; - clocks = <&sdio2_clk>; + clocks = <&master_ccu BCM281XX_MASTER_CCU_SDIO2>; status = "disabled"; }; @@ -134,7 +136,7 @@ compatible = "brcm,kona-sdhci"; reg = <0x3f1a0000 0x10000>; interrupts = ; - clocks = <&sdio3_clk>; + clocks = <&master_ccu BCM281XX_MASTER_CCU_SDIO3>; status = "disabled"; }; @@ -142,99 +144,137 @@ compatible = "brcm,kona-sdhci"; reg = <0x3f1b0000 0x10000>; interrupts = ; - clocks = <&sdio4_clk>; + clocks = <&master_ccu BCM281XX_MASTER_CCU_SDIO4>; status = "disabled"; }; clocks { - bsc1_clk: bsc1 { - compatible = "fixed-clock"; - clock-frequency = <13000000>; - #clock-cells = <0>; - }; - - bsc2_clk: bsc2 { - compatible = "fixed-clock"; - clock-frequency = <13000000>; - #clock-cells = <0>; - }; + #address-cells = <1>; + #size-cells = <1>; + ranges; - bsc3_clk: bsc3 { - compatible = "fixed-clock"; - clock-frequency = <13000000>; - #clock-cells = <0>; + root_ccu: root_ccu { + compatible = "brcm,bcm11351-root-ccu"; + reg = <0x35001000 0x0f00>; + #clock-cells = <1>; + clock-output-names = "frac_1m"; }; - pmu_bsc_clk: pmu_bsc { - compatible = "fixed-clock"; - clock-frequency = <13000000>; - #clock-cells = <0>; + hub_ccu: hub_ccu { + compatible = "brcm,bcm11351-hub-ccu"; + reg = <0x34000000 0x0f00>; + #clock-cells = <1>; + clock-output-names = "tmon_1m"; }; - hub_timer_clk: hub_timer { - compatible = "fixed-clock"; - clock-frequency = <32768>; - #clock-cells = <0>; + aon_ccu: aon_ccu { + compatible = "brcm,bcm11351-aon-ccu"; + reg = <0x35002000 0x0f00>; + #clock-cells = <1>; + clock-output-names = "hub_timer", + "pmu_bsc", + "pmu_bsc_var"; }; - pwm_clk: pwm { - compatible = "fixed-clock"; - clock-frequency = <26000000>; - #clock-cells = <0>; + master_ccu: master_ccu { + compatible = "brcm,bcm11351-master-ccu"; + reg = <0x3f001000 0x0f00>; + #clock-cells = <1>; + clock-output-names = "sdio1", + "sdio2", + "sdio3", + "sdio4", + "usb_ic", + "hsic2_48m", + "hsic2_12m"; }; - sdio1_clk: sdio1 { - compatible = "fixed-clock"; - clock-frequency = <48000000>; - #clock-cells = <0>; + slave_ccu: slave_ccu { + compatible = "brcm,bcm11351-slave-ccu"; + reg = <0x3e011000 0x0f00>; + #clock-cells = <1>; + clock-output-names = "uartb", + "uartb2", + "uartb3", + "uartb4", + "ssp0", + "ssp2", + "bsc1", + "bsc2", + "bsc3", + "pwm"; }; - sdio2_clk: sdio2 { - compatible = "fixed-clock"; - clock-frequency = <48000000>; + /* + * This is a place-holder clock for peripheral + * clocks that set their parent clock to an + * out-of-range value to explicitly select + * "no clock" as a parent. + */ + not_selected_clk: not_selected { #clock-cells = <0>; - }; - - sdio3_clk: sdio3 { compatible = "fixed-clock"; - clock-frequency = <48000000>; - #clock-cells = <0>; + clock-frequency = <0>; }; - sdio4_clk: sdio4 { - compatible = "fixed-clock"; - clock-frequency = <48000000>; + ref_1m_clk: ref_1m { #clock-cells = <0>; - }; - - tmon_1m_clk: tmon_1m { compatible = "fixed-clock"; clock-frequency = <1000000>; + }; + + ref_32k_clk: ref_32k { #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <32768>; }; - uartb_clk: uartb { + bbl_32k_clk: bbl_32k { + #clock-cells = <0>; compatible = "fixed-clock"; - clock-frequency = <13000000>; + clock-frequency = <32768>; + }; + + ref_13m_clk: ref_13m { #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <13000000>; }; - uartb2_clk: uartb2 { + var_13m_clk: var_13m { + #clock-cells = <0>; compatible = "fixed-clock"; clock-frequency = <13000000>; + }; + + dft_19_5m_clk: dft_19_5m { #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <19500000>; }; - uartb3_clk: uartb3 { + ref_crystal_clk: ref_crystal { + #clock-cells = <0>; compatible = "fixed-clock"; - clock-frequency = <13000000>; + clock-frequency = <26000000>; + }; + + ref_cx40_clk: ref_cx40 { #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <40000000>; }; - uartb4_clk: uartb4 { + ref_52m_clk: ref_52m { + #clock-cells = <0>; compatible = "fixed-clock"; - clock-frequency = <13000000>; + clock-frequency = <52000000>; + }; + + var_52m_clk: var_52m { #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <52000000>; }; usb_otg_ahb_clk: usb_otg_ahb { @@ -242,5 +282,65 @@ clock-frequency = <52000000>; #clock-cells = <0>; }; + + ref_96m_clk: ref_96m { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <96000000>; + }; + + var_96m_clk: var_96m { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <96000000>; + }; + + ref_104m_clk: ref_104m { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <104000000>; + }; + + var_104m_clk: var_104m { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <104000000>; + }; + + ref_156m_clk: ref_156m { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <156000000>; + }; + + var_156m_clk: var_156m { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <156000000>; + }; + + ref_208m_clk: ref_208m { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <208000000>; + }; + + var_208m_clk: var_208m { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <208000000>; + }; + + ref_312m_clk: ref_312m { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <312000000>; + }; + + var_312m_clk: var_312m { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <312000000>; + }; }; };