From patchwork Thu Oct 9 22:44:27 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Scott Branden X-Patchwork-Id: 38537 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f69.google.com (mail-la0-f69.google.com [209.85.215.69]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id CA93B202E7 for ; Thu, 9 Oct 2014 22:45:50 +0000 (UTC) Received: by mail-la0-f69.google.com with SMTP id q1sf1381333lam.4 for ; Thu, 09 Oct 2014 15:45:49 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe:content-type; bh=DWaIPaVtUl7xaxXVI0nt1k/o6Sz4VunoJJ0R1Guv6Sg=; b=fSt+RGPt1DDErA7h9R56LAClYAkUevnIxQMZ8GfvpX4WPlDbvA5e9fyTebliYTlpXC PKC+NdotrVkrlP11LGg6NuU7nGNpFqTN98l84D90otcIh9LWf5A5GivNPo5cFwhY+P3r AFAj8jeqd3/5N7AisR1MhGAACqL6oAJlkCyVw6J8ly2GGM8J+kIvbZsHIk48WmVbn5jz YK6NyNNz2NkSdh8PxerHMQ56XrunISEPITBUcaKGGKokr3axC5kWjHt2elVLFzbZvT9c 9lIFPE6SbOGXSvAR/CcNtFjsaXeops9Ahk0ZpdVQ3jzyHvFxLzeahba5SWH1B+iyWCSh nojw== X-Gm-Message-State: ALoCoQlL23IhcLllLe0wkmOA1mZozDDDjLOMv0490clKL+ucdZ4Li0UsZyvxcweKeh0Nl9U5xqWF X-Received: by 10.112.132.37 with SMTP id or5mr114992lbb.2.1412894749233; Thu, 09 Oct 2014 15:45:49 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.21.135 with SMTP id v7ls216763lae.40.gmail; Thu, 09 Oct 2014 15:45:49 -0700 (PDT) X-Received: by 10.152.163.66 with SMTP id yg2mr681271lab.38.1412894749052; Thu, 09 Oct 2014 15:45:49 -0700 (PDT) Received: from mail-la0-f52.google.com (mail-la0-f52.google.com [209.85.215.52]) by mx.google.com with ESMTPS id t10si6377815lat.82.2014.10.09.15.45.48 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 09 Oct 2014 15:45:48 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.52 as permitted sender) client-ip=209.85.215.52; Received: by mail-la0-f52.google.com with SMTP id hz20so2123287lab.39 for ; Thu, 09 Oct 2014 15:45:48 -0700 (PDT) X-Received: by 10.112.54.130 with SMTP id j2mr365621lbp.41.1412894748623; Thu, 09 Oct 2014 15:45:48 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.84.229 with SMTP id c5csp327694lbz; Thu, 9 Oct 2014 15:45:47 -0700 (PDT) X-Received: by 10.68.135.97 with SMTP id pr1mr873401pbb.113.1412894746974; Thu, 09 Oct 2014 15:45:46 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h2si1898229pdk.90.2014.10.09.15.45.45 for ; Thu, 09 Oct 2014 15:45:46 -0700 (PDT) Received-SPF: none (google.com: linux-kernel-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751684AbaJIWpX (ORCPT + 27 others); Thu, 9 Oct 2014 18:45:23 -0400 Received: from mail-gw1-out.broadcom.com ([216.31.210.62]:20216 "EHLO mail-gw1-out.broadcom.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751262AbaJIWpK (ORCPT ); Thu, 9 Oct 2014 18:45:10 -0400 X-IronPort-AV: E=Sophos;i="5.04,688,1406617200"; d="scan'208";a="48093637" Received: from irvexchcas08.broadcom.com (HELO IRVEXCHCAS08.corp.ad.broadcom.com) ([10.9.208.57]) by mail-gw1-out.broadcom.com with ESMTP; 09 Oct 2014 17:01:26 -0700 Received: from IRVEXCHSMTP3.corp.ad.broadcom.com (10.9.207.53) by IRVEXCHCAS08.corp.ad.broadcom.com (10.9.208.57) with Microsoft SMTP Server (TLS) id 14.3.174.1; Thu, 9 Oct 2014 15:44:59 -0700 Received: from mail-irva-13.broadcom.com (10.10.10.20) by IRVEXCHSMTP3.corp.ad.broadcom.com (10.9.207.53) with Microsoft SMTP Server id 14.3.174.1; Thu, 9 Oct 2014 15:44:59 -0700 Received: from mail.broadcom.com (lbrmn-lnxub113.ric.broadcom.com [10.136.13.65]) by mail-irva-13.broadcom.com (Postfix) with ESMTP id 365A040FE8; Thu, 9 Oct 2014 15:44:41 -0700 (PDT) From: Scott Branden To: Christian Daudt , Matt Porter , Russell King , , Mike Turquette , Alex Elder , Rob Herring , Pawel Moll , Mark Rutland , Ian Campbell , "Kumar Gala" , Andrew Morton , "David S. Miller" , Greg Kroah-Hartman , Joe Perches , "Mauro Carvalho Chehab" , Antti Palosaari CC: JD Zheng , Ray Jui , , , , Jonathan Richardson , Scott Branden Subject: [PATCH V4 3/7] dt-bindings: Document Broadcom Cygnus SoC and clock driver Date: Thu, 9 Oct 2014 15:44:27 -0700 Message-ID: <1412894671-5921-4-git-send-email-sbranden@broadcom.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1412894671-5921-1-git-send-email-sbranden@broadcom.com> References: <1412894671-5921-1-git-send-email-sbranden@broadcom.com> MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: sbranden@broadcom.com X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.52 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , From: Jonathan Richardson Reviewed-by: Arun Parameswaran Tested-by: Jonathan Richardson Reviewed-by: JD (Jiandong) Zheng Signed-off-by: Scott Branden --- .../devicetree/bindings/arm/bcm/cygnus.txt | 31 +++++ .../devicetree/bindings/clock/clk-cygnus.txt | 121 ++++++++++++++++++++ .../devicetree/bindings/clock/clk-iproc.txt | 48 ++++++++ 3 files changed, 200 insertions(+) create mode 100644 Documentation/devicetree/bindings/arm/bcm/cygnus.txt create mode 100644 Documentation/devicetree/bindings/clock/clk-cygnus.txt create mode 100644 Documentation/devicetree/bindings/clock/clk-iproc.txt diff --git a/Documentation/devicetree/bindings/arm/bcm/cygnus.txt b/Documentation/devicetree/bindings/arm/bcm/cygnus.txt new file mode 100644 index 0000000..4c77169 --- /dev/null +++ b/Documentation/devicetree/bindings/arm/bcm/cygnus.txt @@ -0,0 +1,31 @@ +Broadcom Cygnus device tree bindings +------------------------------------ + + +Boards with Cygnus SoCs shall have the following properties: + +Required root node property: + +BCM11300 +compatible = "brcm,bcm11300", "brcm,cygnus"; + +BCM11320 +compatible = "brcm,bcm11320", "brcm,cygnus"; + +BCM11350 +compatible = "brcm,bcm11350", "brcm,cygnus"; + +BCM11360 +compatible = "brcm,bcm11360", "brcm,cygnus"; + +BCM58300 +compatible = "brcm,bcm58300", "brcm,cygnus"; + +BCM58302 +compatible = "brcm,bcm58302", "brcm,cygnus"; + +BCM58303 +compatible = "brcm,bcm58303", "brcm,cygnus"; + +BCM58305 +compatible = "brcm,bcm58305", "brcm,cygnus"; diff --git a/Documentation/devicetree/bindings/clock/clk-cygnus.txt b/Documentation/devicetree/bindings/clock/clk-cygnus.txt new file mode 100644 index 0000000..7e03837 --- /dev/null +++ b/Documentation/devicetree/bindings/clock/clk-cygnus.txt @@ -0,0 +1,121 @@ +Broadcom Cygnus Clock Controller + +This binding uses the common clock binding: +Documentation/devicetree/bindings/clock/clock-bindings.txt + +The Cygnus clock controller manages several PLL's and their channels, found only +on the Cygnus chip. Clocks that are common to iProc can be found in the iProc +clock controller. The controllers are split into a parent-child relationship +where the parent is the PLL and the child controls the PLL's channels. + +All PLL's are derived from a 25MHz oscillator. The PLL's controlled are the +GENPLL, LCPLL, the MIPI PLL. In addition, there are two clocks derived from +GENPLL channel 0, and three that are derived directly from the oscillator. + +Required properties: +- compatible: Must be one of the following: + "brcm,cygnus-lcpll-clk" - Controls LCPLL. + "brcm,cygnus-lcpll-ch" - Controls LCPLL (parent) channels + "brcm,cygnus-genpll-clk" - Controls parent GENPLL + "brcm,cygnus-genpll-ch" - Controls GENPLL (parent) channels + "brcm,cygnus-mipipll-clk" - Controls MIPI PLL + "brcm,cygnus-mipipll-ch" - Controls parent MIPI PLL (parent) channels + "brcm,cygnus-osc-derived" - Controls oscillator (parent) derived channels + not controlled by any PLL. + "brcm,cygnus-pll-derived" - Controls clocks derived from GENPLL channel 0. + These clocks have hard wired internal dividers and their clock rates + scale according to the GENPLL channel. + +- reg: First register is the base address of the PLL. Register 2 and 3 are + required by some clocks. They are the top clock gating control used to + enable/disable clocks (ch 1), and the CRMU PLL AON CONTROL register which + powers on PLL/LDO's (ch 2). + +- clocks: The input parent clock phandle for the clock. This is either a PLL, + oscillator, or GENPLL channel 0. + +- channel: The PLL channel that the clock belongs to. This is used for + "brcm,cygnus-lcpll-ch", "brcm,cygnus-genpll-ch", "brcm,cygnus-mipipll-ch", + "brcm,cygnus-osc-derived" only. + +- div: Used by "brcm,cygnus-pll-derived" to define the hard coded internal + divider value. Used by "brcm,cygnus-osc-derived" to specify the programmable + divider. + +- #clock-cells: From common clock binding; shall be set to 0. + +Examples: + + osc: oscillator { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <25000000>; + }; + + lcpll: lcpll@0301d02c { + #clock-cells = <0>; + compatible = "brcm,cygnus-lcpll-clk"; + reg = <0x0301d02c 0x1c>; + clocks = <&osc>; + }; + + genpll: genpll@0301d000 { + #clock-cells = <0>; + compatible = "brcm,cygnus-genpll-clk"; + reg = <0x0301d000 0x2c>, + <0x180AA024 0x4>, + <0x0301C020 0x4>; + clocks = <&osc>; + }; + + axi21_clk: genpll_ch0@0301d000 { + #clock-cells = <0>; + compatible = "brcm,cygnus-genpll-ch"; + reg = <0x0301d000 0x2c>; + clocks = <&genpll>; + channel = <0>; + }; + + pcie_clk: lcpll_ch0@0301d02c { + compatible = "brcm,cygnus-lcpll-ch"; + reg = <0x0301d02c 0x1c>; + #clock-cells = <0>; + clocks = <&lcpll>; + channel = <0>; + }; + + axi41_clk: axi41_clk { + reg = <0x0301d000 0x2c>; + #clock-cells = <0>; + compatible = "brcm,cygnus-pll-derived"; + clocks = <&axi21_clk>; + div = <2>; + }; + + keypad_clk: keypad_clk@0301D048 { + compatible = "brcm,cygnus-osc-derived"; + reg = <0x0301D048 0x4>, + <0x180AA024 0x4>; + #clock-cells = <0>; + clocks = <&osc>; + channel = <0>; + div = <392>; + }; + + mipipll: mipipll@180a9800 { + #clock-cells = <0>; + compatible = "brcm,cygnus-mipipll-clk"; + reg = <0x180a9800 0x2c>, + top_clk_gating_ctrl: <0x180AA024 0x4>, + crmu_pll_aon_ctrl: <0x0301C020 0x4>; + clocks = <&osc>; + }; + + lcd_clk: mipipll_ch1@180a9800 { + #clock-cells = <0>; + compatible = "brcm,cygnus-mipipll-ch"; + reg = <0x180a9800 0x2c>, + <0x180AA024 0x4>; + clocks = <&mipipll>; + channel = <1>; + }; diff --git a/Documentation/devicetree/bindings/clock/clk-iproc.txt b/Documentation/devicetree/bindings/clock/clk-iproc.txt new file mode 100644 index 0000000..b5d4f08 --- /dev/null +++ b/Documentation/devicetree/bindings/clock/clk-iproc.txt @@ -0,0 +1,48 @@ +Broadcom iProc Clock Controller + +This binding uses the common clock binding: +Documentation/devicetree/bindings/clock/clock-bindings.txt + +The iProc clock controller manages clocks that are common to iProc chips. +The controllers are split into a parent-child relationship where the parent is +the PLL and the child controls the PLL's channels. + +The only PLL controlled is the ARM PLL which is derived from a 25MHz crystal. + +Required properties: +- compatible: Must be one of the following: + "brcm,iproc-arm-a9pll" - Controls ARM PLL. + "brcm,iproc-arm-ch" - Controls ARM PLL (parent) channels + +- reg: The base address of the PLL. + +- clocks: The input parent clock phandle for the clock. This is either a PLL, + or oscillator. + +- channel: The PLL channel that the clock belongs to. This is used for + "brcm,iproc-arm-ch" only. + +- #clock-cells: From common clock binding; shall be set to 0. + +Example: + + osc: oscillator { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <25000000>; + }; + + a9pll: arm_clk@19000000 { + compatible = "brcm,iproc-arm-a9pll"; + reg = <0x19000000 0x1000>; + #clock-cells = <0>; + clocks = <&osc>; + }; + + periph_clk: periph_clk@19000000 { + compatible = "brcm,iproc-arm-ch"; + reg = <0x19000000 0x1000>; + #clock-cells = <0>; + clocks = <&a9pll>; + channel = <3>; + };